summaryrefslogtreecommitdiffstats
path: root/gnu
diff options
context:
space:
mode:
authorjoerg <joerg@FreeBSD.org>1996-04-28 12:32:43 +0000
committerjoerg <joerg@FreeBSD.org>1996-04-28 12:32:43 +0000
commit8c5c90668ac7ed7fd165d0b8d3ea9c54d67abc13 (patch)
tree276a9bc854d2febe9d40eefea3c84e3431aff94c /gnu
parentdabc13d18f6b2998a0c7def87f6635929ee98b3c (diff)
downloadFreeBSD-src-8c5c90668ac7ed7fd165d0b8d3ea9c54d67abc13.zip
FreeBSD-src-8c5c90668ac7ed7fd165d0b8d3ea9c54d67abc13.tar.gz
Fix a bogon that prevented easy-import from inserting the new module
name in alphabetical order (broken by my previous commit). Pointed out by: asami
Diffstat (limited to 'gnu')
-rw-r--r--gnu/usr.bin/cvs/contrib/easy-import.pl19
1 files changed, 9 insertions, 10 deletions
diff --git a/gnu/usr.bin/cvs/contrib/easy-import.pl b/gnu/usr.bin/cvs/contrib/easy-import.pl
index c12ad3f..68d7027 100644
--- a/gnu/usr.bin/cvs/contrib/easy-import.pl
+++ b/gnu/usr.bin/cvs/contrib/easy-import.pl
@@ -8,7 +8,7 @@
#
# Written by Jörg Wunsch, 95/03/07, and placed in the public domain.
#
-# $Id: easy-import.pl,v 1.5 1996/01/02 07:39:03 joerg Exp $
+# $Id: easy-import.pl,v 1.6 1996/04/07 10:22:37 joerg Exp $
require "complete.pl";
require "getopts.pl";
@@ -22,7 +22,7 @@ sub scan_opts
$dont_do_it = "-n" if $opt_n;
if($opt_v) {
- print STDERR '$Source: /home/ncvs/src/gnu/usr.bin/cvs/contrib/easy-import.pl,v $ $Revision: 1.5 $' . "\n"; # 'emacs kludge
+ print STDERR '$Source: /home/ncvs/src/gnu/usr.bin/cvs/contrib/easy-import.pl,v $ $Revision: 1.6 $' . "\n"; # 'emacs kludge
exit 0;
}
die "usage: $0 [-v] [-n] [moduledir]\n" .
@@ -343,15 +343,14 @@ print "${so}This is your last chance to interrupt, " .
$| = 0;
<>;
-$mod = "";
-foreach $tmp (@cvsmods) {
- if($tmp gt $modname) {
- $mod = $tmp;
- last;
- }
-}
-
if (!$branchimport) {
+ $mod = "";
+ foreach $tmp (sort(keys(%cvsmods))) {
+ if($tmp gt $modname) {
+ $mod = $tmp;
+ last;
+ }
+ }
if($mod eq "") {
# we are going to append our module
$cmd = "\$\na\n";
OpenPOWER on IntegriCloud