From 97a0cc52812c6cc075ec7da849dd496f0e6cf5a4 Mon Sep 17 00:00:00 2001 From: Richard Levitte Date: Wed, 11 Mar 2015 10:22:50 +0100 Subject: [PATCH] Move Configurations* out of the way and rename them. Configure would load the glob "Configurations*". The problem with this is that it also loads all kinds of backups of those configurations that some editors do, like emacs' classic 'Configurations~'. The solution is to give them an extension, such as '.conf', and make sure to end the glob with that. Also, because 'Configurations.conf' makes for a silly name, and because a possibly large number of configurations will become clutter, move them to a subdirectory 'Configurations/', and rename them to something more expressive, as well as something that sets up some form of sorting order. Thus: Configurations -> Configurations/10-main.conf Configurations.team -> Configurations/90-team.conf Finally, make sure that Configure sorts the list of files that 'glob' produces, and adapt Makefile.org. Reviewed-by: Rich Salz --- Configurations => Configurations/10-main.conf | 0 Configurations.team => Configurations/90-team.conf | 0 Configure | 4 ++-- Makefile.org | 2 +- 4 files changed, 3 insertions(+), 3 deletions(-) rename Configurations => Configurations/10-main.conf (100%) rename Configurations.team => Configurations/90-team.conf (100%) diff --git a/Configurations b/Configurations/10-main.conf similarity index 100% rename from Configurations rename to Configurations/10-main.conf diff --git a/Configurations.team b/Configurations/90-team.conf similarity index 100% rename from Configurations.team rename to Configurations/90-team.conf diff --git a/Configure b/Configure index 5dbfa6cccf..4094c08d4c 100755 --- a/Configure +++ b/Configure @@ -184,8 +184,8 @@ sub read_config { } my ($vol, $dir, $dummy) = File::Spec->splitpath($0); -my $pattern = File::Spec->catpath($vol, $dir, "Configurations*"); -foreach ( glob($pattern) ) { +my $pattern = File::Spec->catpath($vol, $dir, "Configurations/*.conf"); +foreach (sort glob($pattern) ) { &read_config($_); } diff --git a/Makefile.org b/Makefile.org index 4f5bff96e8..0d09ad4209 100644 --- a/Makefile.org +++ b/Makefile.org @@ -500,7 +500,7 @@ crypto/bn/bn_prime.h: crypto/bn/bn_prime.pl $(PERL) crypto/bn/bn_prime.pl >crypto/bn/bn_prime.h -TABLE: Configure Configurations Configurations.team +TABLE: Configure Configurations/*.conf (echo 'Output of `Configure TABLE'"':"; \ $(PERL) Configure TABLE) > TABLE -- 2.25.1