-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdebcommit
executable file
·27 lines (23 loc) · 1.07 KB
/
debcommit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
name=`cat debian/changelog | head -1 | grep -o ^[^\ ]*`
br=`git rev-parse --abbrev-ref HEAD`
if [ -z "${is_parent}" ]; then
if [ "${br}" != "master" ] && [ "${br}" != "main" ]; then
name=${name}-${br}
fi
fi
#"patch: **** Can't rename file ... to .pc/... : Too many levels of symbolic links" for .pc,debian/patches symbolic links
#"the patch has fuzz which is not allowed" for .pc/X,debian/patches/X symbolic links
~/test/debinithelper ${name} && \
#when testing only the row above and below, don't forget to "restore .pc/.*" files, normal files are ok, more hidden files to restore? no, tested it, more inside hidden files are ok
dpkg-source --commit --include-removal || \
# --include-binaries #for ocompiler .expected tests binaries , but will upload nothing
#EDITOR=/bin/true dpkg-source -q --commit --include-removal . patchsetname
# kill -s 9 `ps aux | grep dpkg-source | head -1 | tr -s ' ' | cut -d ' ' -f2`
{
exitcod=$?
echo dpkg-source exit ${exitcod}
~/test/debinithelper ${name} 0
exit ${exitcod}
}
#sync
~/test/debinithelper ${name} x