OSA: Only try to copy file if if exists
When the file sync is executed against stable branches the file in the files_to_sync may not exist. This patch ensures that the file exists before trying to copy it. Change-Id: I31e195b0df4cf13dd449d48b41ae26a21a4bb1b6
This commit is contained in:
parent
8b7ec79d01
commit
a9a3e862e1
@ -41,6 +41,12 @@ check_and_ignore() {
|
||||
}
|
||||
|
||||
for x in ${files_to_sync[@]}; do
|
||||
# If the source repo does not have the file to copy
|
||||
# then skip to the next file. This covers the situation
|
||||
# where this script runs against old branches which
|
||||
# do not have the same set of files.
|
||||
[[ ! -e ${x} ]] && continue
|
||||
|
||||
# If the target repo does not have such a file already
|
||||
# then it's probably best to leave it alone.
|
||||
[[ ! -e ${OSA_PROJECT}/${x} ]] && continue
|
||||
|
Loading…
x
Reference in New Issue
Block a user