nix run: Flush the progress bar before starting the command

This commit is contained in:
Eelco Dolstra 2017-08-29 15:13:30 +02:00
parent 05d68a6e23
commit c8235c5313
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE
5 changed files with 28 additions and 19 deletions

View file

@ -2,6 +2,7 @@
#include "shared.hh"
#include "eval.hh"
#include "attr-path.hh"
#include "progress-bar.hh"
#include <unistd.h>
@ -65,6 +66,8 @@ struct CmdEdit : InstallablesCommand
args.push_back(filename);
stopProgressBar();
execvp(editor.c_str(), stringsToCharPtrs(args).data());
throw SysError("cannot run editor '%s'", editor);