Ticket #2029: urar.in.diff
File urar.in.diff, 704 bytes (added by storchaka, 15 years ago) |
---|
-
urar.in
old new 31 31 $UNRAR v -c- "$1" | @AWK@ -v uid=`id -u` -v gid=`id -g` ' 32 32 BEGIN { flag=0 } 33 33 /^-------/ { flag++; if (flag > 1) exit 0; next } 34 { 35 if (flag == 0) next 36 if ( !/ [0-9][0-9]:[0-9][0-9] /) str = $0 # there is no time spec in this line 37 else { 38 if (str ~ /^\^/) 39 str=substr(str, 2) 34 flag==1 { 35 str = substr($0, 2) 36 getline 40 37 split($4, a, "-") 41 38 if (index($6, "D") != 0) 42 39 $6="drwxr-xr-x" … … 44 41 if (index($6, ".") != 0) 45 42 $6="-rw-r--r--" 46 43 printf "%s 1 %s %s %d %02d/%02d/%02d %s %s\n", $6, uid, gid, $1, a[2], a[1], a[3], $5, str 47 }48 44 }' 49 45 } 50 46