From 0109b7e44fa8fa949b6a33b2a30c3c8dbc8f6616 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 27 May 2009 23:12:54 +0000 Subject: [PATCH] * Sort the module list; otherwise the output will be sensitive to the order in which files are stored in the file system of whoever runs the script (and will therefore fluctuate a lot). svn path=/nixos/branches/modular-nixos/; revision=15753 --- maintainers/scripts/gen-module-list.sh | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/maintainers/scripts/gen-module-list.sh b/maintainers/scripts/gen-module-list.sh index 8a1d298480f..5f40ee66bcf 100755 --- a/maintainers/scripts/gen-module-list.sh +++ b/maintainers/scripts/gen-module-list.sh @@ -6,7 +6,8 @@ usage(){ echo 1>&2 " $prog module-dir -This script generate the index file inside the module directory. +This script generates the `module-list.nix' index file inside the +module directory. " exit 1 } @@ -34,7 +35,7 @@ generate_index(){ cd "$path" echo -n "$path: " 1>&2 { echo "[ # This file have been generated by $(basename $prog)"; - for file in : $(find ./ -wholename '*.impl[./]*' -or -wholename './module-list.nix' -or -type f -name '*.nix' -print); do + for file in : $(find ./ -wholename '*.impl[./]*' -or -wholename './module-list.nix' -or -type f -name '*.nix' -print | sort); do [ "$file" = ':' ] && continue; echo -n . 1>&2 if test "$(is_module "$file" 2> /dev/null)" = "Bool(True)"; then