Unified · Split
| @@ -1,3 +1,27 @@ | ||
| 1 | 1 | #!/bin/sh |
| 2 | 2 | |
| 3 | −git pull --no-rebase --log --stat --commit --no-edit https://github.com/michaelni/FFmpeg.git sourceplugin-libpostproc | |
| 3 | +#If a version is set then we only try merging a source plugin with matching version as a generic one could change the ABI to master HEAD | |
| 4 | +merge_internal(){ # $1=repository, $2=refspec | |
| 5 | + [ -n "$version" ] && git pull --no-rebase --log --stat --commit --no-edit $1 sourceplugin-$2-$version | |
| 6 | + [ -z "$version" ] && git pull --no-rebase --log --stat --commit --no-edit $1 sourceplugin-$2 | |
| 7 | +} | |
| 8 | + | |
| 9 | +unset suceeded failed version | |
| 10 | + | |
| 11 | +merge(){ # $1=repository, $2=refspec | |
| 12 | + merge_internal "$1" "$2" || { | |
| 13 | + git reset --hard | |
| 14 | + echo merge of $1 $2 failed, continuing with other plugins | |
| 15 | + failed="$failed $2" | |
| 16 | + return 0 | |
| 17 | + } | |
| 18 | + suceeded="$suceeded $2" | |
| 19 | +} | |
| 20 | + | |
| 21 | +#version="12.34" | |
| 22 | + | |
| 23 | +merge "https://github.com/michaelni/FFmpeg.git" "libpostproc" | |
| 24 | + | |
| 25 | +[ -n "$version" ] && echo version: $version | |
| 26 | +[ -n "$suceeded" ] && echo Succeeded merging: $suceeded | |
| 27 | +[ -n "$failed" ] && echo Failed merging: $failed | |