mirror of
https://gitlab.redox-os.org/redox-os/redox.git
synced 2026-06-24 05:44:17 +08:00
Add difftool subcommands
This commit is contained in:
parent
d029991234
commit
5d1d2c58c1
31
cook.sh
31
cook.sh
@ -25,6 +25,9 @@ function usage {
|
||||
echo " diff" >&2
|
||||
echo " diff_origin" >&2
|
||||
echo " diff_upstream" >&2
|
||||
echo " difftool" >&2
|
||||
echo " difftool_origin" >&2
|
||||
echo " difftool_upstream" >&2
|
||||
echo " fetch" >&2
|
||||
echo " unfetch" >&2
|
||||
echo " prepare" >&2
|
||||
@ -176,6 +179,34 @@ function op {
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
difftool)
|
||||
if [ -n "$GIT" ]
|
||||
then
|
||||
git -C source difftool -d
|
||||
fi
|
||||
;;
|
||||
difftool_origin)
|
||||
if [ -n "$GIT" ]
|
||||
then
|
||||
if [ -n "$BRANCH" ]
|
||||
then
|
||||
git -C source difftool -d "origin/$BRANCH"
|
||||
else
|
||||
git -C source difftool -d "origin/master"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
difftool_upstream)
|
||||
if [ -n "$GIT_UPSTREAM" ]
|
||||
then
|
||||
if [ -n "$BRANCH" ]
|
||||
then
|
||||
git -C source difftool -d "upstream/$BRANCH"
|
||||
else
|
||||
git -C source difftool -d "upstream/master"
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
update)
|
||||
pushd source > /dev/null
|
||||
skip=0
|
||||
|
||||
Loading…
Reference in New Issue
Block a user