[Jifty-commit] jifty branch, master, updated. 1.10214-8-g8c74a88
Jifty commits
jifty-commit at lists.jifty.org
Wed Feb 23 14:39:52 EST 2011
The branch, master has been updated
via 8c74a883c58f85d87049ed12ed6e4a249c7e9b72 (commit)
via ee12a21e8c888bdf9921a4e0e7812ab39864777b (commit)
from 1a7f86f5903c32225de773de84809c0af72ddbed (commit)
Summary of changes:
lib/Jifty/Script/Adopt.pm | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
- Log -----------------------------------------------------------------
commit ee12a21e8c888bdf9921a4e0e7812ab39864777b
Author: Thomas Sibley <trs at bestpractical.com>
Date: Wed Feb 23 14:37:54 2011 -0500
jifty adopt: Keep the overwrite prompt on one line
diff --git a/lib/Jifty/Script/Adopt.pm b/lib/Jifty/Script/Adopt.pm
index 26f321c..9b6102d 100644
--- a/lib/Jifty/Script/Adopt.pm
+++ b/lib/Jifty/Script/Adopt.pm
@@ -139,7 +139,7 @@ sub run {
}
if(-e $dest) {
- print "$dest exists, overwrite? [n]\n";
+ print "$dest exists, overwrite? [n] ";
chomp(my $ans = <STDIN>); $ans ||= 'n';
exit 1 unless(lc($ans) eq 'y');
}
commit 8c74a883c58f85d87049ed12ed6e4a249c7e9b72
Author: Thomas Sibley <trs at bestpractical.com>
Date: Wed Feb 23 14:38:56 2011 -0500
There's no need to fork here and it causes problems with vim
Just do the system call and when it comes back fall through to the end.
Additionally, use two-arg system to avoid shell escaping issues.
diff --git a/lib/Jifty/Script/Adopt.pm b/lib/Jifty/Script/Adopt.pm
index 9b6102d..5012a0f 100644
--- a/lib/Jifty/Script/Adopt.pm
+++ b/lib/Jifty/Script/Adopt.pm
@@ -148,8 +148,7 @@ sub run {
# TODO put an option on that?
if($ENV{EDITOR}) {
- fork and exit;
- exec("$ENV{EDITOR} $dest");
+ system($ENV{EDITOR}, $dest);
}
} # end run
-----------------------------------------------------------------------
More information about the Jifty-commit
mailing list