Skip to content
This repository has been archived by the owner on May 9, 2020. It is now read-only.

fix Copy Over "cannot stat" error #38

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Commits on Jan 19, 2019

  1. fix Copy Over "cannot stat" error

    Force destination dir to be absolute, so as to avoid problems with wildcards in COPYMASKS
    Use a consistent method for escaping wildcard and filename substitution in COPYMASKS
    
    This fixes three issues:
    
     - wildcards in COPYMASKS are expanded correctly when testing for existence, but are not expanded at all in the copy command. Result: 'cannot stat' error message and nothing gets copied.
     - the copy command is executed for all items in COPYMASKS, even if they do not exist. Result: false 'cannot stat' error message.
    - in COPYMASKS you use a backslash escape for "*" wildcard, but no escape for "[" filename substitution.
    
    Example of error output, when there exists a directory called Covers, which fails to be copied, and there is nothing matching '*.log' but we still try to copy it - and fail.
    
    "
    Copying files:
       +> Covers
    cp: cannot stat 'MyDir/[Cc]overs': No such file or directory
    cp: cannot stat 'MyDir/*.log': No such file or directory
    "
    kaributena committed Jan 19, 2019
    Configuration menu
    Copy the full SHA
    ce18d97 View commit details
    Browse the repository at this point in the history