Skip to content

Commit 170bd64

Browse files
author
olshek
committed
improved regular expression in v-backup-user file
The regular expression now uses exact match of a folder/file name. With the previous version, some files were ignored during the backup process(for example .gitconfig, because it contains "conf").
1 parent 5e861eb commit 170bd64

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bin/v-backup-user

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,7 @@ if [ "$USER" != '*' ]; then
479479
set -f
480480
i=0
481481

482-
for udir in $(ls -a |egrep -v "conf|web|dns|mail|^\.\.$|^\.$"); do
482+
for udir in $(ls -a |egrep -v "^conf$|^web$|^dns$|^mail$|^\.\.$|^\.$"); do
483483
exclusion=$(echo "$USER" |tr ',' '\n' |grep "^$udir$")
484484
if [ -z "$exclusion" ]; then
485485
((i ++))

0 commit comments

Comments
 (0)