]> pd.if.org Git - zpackage/commitdiff
use lstat for all zpm-add operations
authorNathan Wagner <nw@hydaspes.if.org>
Fri, 2 Nov 2018 13:09:01 +0000 (13:09 +0000)
committerNathan Wagner <nw@hydaspes.if.org>
Sat, 3 Nov 2018 12:39:53 +0000 (12:39 +0000)
zpm-add

diff --git a/zpm-add b/zpm-add
index 6dc08b7d1dc09bce85dd4241bbe4eb56f55648e1..09adaac941102f50b2c10f854fd128e32e19c483 100755 (executable)
--- a/zpm-add
+++ b/zpm-add
@@ -127,10 +127,10 @@ for path in $*; do
        #echo adding $path
 
        # only stat the file for items not set on the command line
-       mode=${clmode:-$(zpm stat -f '%a' $path)}
-       username=${cluser:-$(zpm stat -f '%U' $path)}
-       groupname=${clgroup:-$(zpm stat -f '%G' $path)}
-       mtime=${clmtime:-$(zpm stat -f '%y' $path)}
+       mode=${clmode:-$(zpm stat -l -f '%a' $path)}
+       username=${cluser:-$(zpm stat -l -f '%U' $path)}
+       groupname=${clgroup:-$(zpm stat -l -f '%G' $path)}
+       mtime=${clmtime:-$(zpm stat -l -f '%y' $path)}
        filetype=${cltype:-$(zpm stat -l -f '%t' "$path")}
 
        rpath="$path"