duplicity-talk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Duplicity-talk] The awk command that strips the --exclude and --inc


From: edgar . soldin
Subject: Re: [Duplicity-talk] The awk command that strips the --exclude and --include parameters from DUPL_PARAMS fails to remove a one byte parameter value.
Date: Sun, 3 Jun 2018 18:17:41 +0200
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0

hey Rob,

would you mind testing
  http://duply.net/wiki/index.php/Duply-code#Latest_Development_Snapshot
with an improved xclude stripping routine?

thanks ..ede/duply.net

On 4/19/2018 21:39, Rob Adair 'Profitable Business Systems' via Duplicity-talk 
wrote:
> original:
> 
> function duplicity_params_conf {
>   # reuse cmd var from main loop
>   ## in/exclude parameters are currently not supported on restores
>   if [ "$cmd" = "fetch" ] || [ "$cmd" = "restore" ] || [ "$cmd" = "status" ]; 
> then
>     # filter exclude params from fetch/restore
>                                                                               
>  vvv
>     echo "$DUPL_PARAMS" | awk '{gsub(/--(ex|in)clude[a-z-]*(([ \t]+|=)[^-][^ 
> \t]+)?/,"");print}'
>     return
>   fi
>   
>   echo "$DUPL_PARAMS"
> }
> 
> 
> function duplicity_params_conf {
>   # reuse cmd var from main loop
>   ## in/exclude parameters are currently not supported on restores
>   if [ "$cmd" = "fetch" ] || [ "$cmd" = "restore" ] || [ "$cmd" = "status" ]; 
> then
>     # filter exclude params from fetch/restore
>                                                                               
>  vvv
>     echo "$DUPL_PARAMS" | awk '{gsub(/--(ex|in)clude[a-z-]*(([ \t]+|=)[^-][^ 
> \t]*)?/,"");print}'
>     return
>   fi
>   
>   echo "$DUPL_PARAMS"
> }
> 
> 
> DUPL_PARAMS="$DUPL_PARAMS --include /etc --include /home --include 
> /opt/zimbra/backup --exclude /"
> 
> duply failed to remove the / after --exclude.
> 
> 
> 
> 
> 
> _______________________________________________
> Duplicity-talk mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/duplicity-talk
> 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]