Antoine Beaupré wrote:
> 
> Do you think you could provide a patch that would fix this for you or a
> way to reproduce the issue?
> 

Works-for-me quality patch is below.

To reproduce:
* Generate locale data for et_EE.UTF-8 (needed only once).
* Set the environment variable LC_COLLATE to et_EE.UTF-8 (ISO encodings like
  ISO-8895-15, ISO-8895-4 or something similar will give same error).
* Execute any etckeeper command (I suggest 'etckeeper unclean' as it should
  perform only reads) and observe the bug.


Best regards,

        Kristjan


--- /usr/bin/etckeeper.orig  2015-11-05 14:03:15.642317316 +0200
+++ /usr/bin/etckeeper    2015-11-05 14:04:14.630314191 +0200
@@ -75,7 +75,7 @@
        command=pre-install
 fi

-if echo "$command" | egrep -q '[^-a-z_]'; then
+if echo "$command" | egrep -q '[^-[:lower:]_]'; then
        echo "etckeeper: invalid command $command" >&2
        exit 1
 fi
@@ -120,7 +120,7 @@
        perl -e '
                $dir=shift;
                print join "\n", grep { ! -d $_ && -x $_ }
-                       grep /^\Q$dir\/\E[-a-zA-Z0-9]+$/,
+                       grep /^\Q$dir\/\E[-[:alnum:]]+$/,
                        glob "$dir/*";
        ' "$1"
 }

Reply via email to