Skip to content

Commit

Permalink
envsetup: add back a few more commands that we were missing
Browse files Browse the repository at this point in the history
Change-Id: I28bad16406dc604779d0c0fa985104ae909b3e9d
  • Loading branch information
willdeberry authored and KhasMek committed Mar 17, 2015
1 parent 9d0d9ae commit d1b6573
Showing 1 changed file with 54 additions and 0 deletions.
54 changes: 54 additions & 0 deletions envsetup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,9 @@ Invoke ". build/envsetup.sh" from your shell to add the following functions to y
- installrecovery: Installs a recovery.img to the connected device.
- sdkgen: Create and add a custom sdk platform to your sdk directory from this source tree
- pyrrit: Helper subprogram to interact with AOKP gerrit
- mbot: Builds for all devices using the psuedo buildbot
- taco: Builds for a single device using the pseudo buildbot
- addaokp: Add git remote for the AOKP gerrit repository
Look at the source to view more functions. The complete list is:
EOF
Expand Down Expand Up @@ -1543,6 +1546,12 @@ function godir () {
\cd $T/$pathname
}

function mbot() {
unset LUNCH_MENU_CHOICES
croot
./vendor/aokp/bot/deploy.sh
}

function pspush_host() {
echo ""
echo "Host aokp_gerrit"
Expand Down Expand Up @@ -1596,6 +1605,51 @@ function pspush() {
fi
}
function taco() {
for sauce in "$@"
do
breakfast $sauce
if [ $? -eq 0 ]; then
croot
./vendor/aokp/bot/build_device.sh aokp_$sauce-userdebug $sauce
else
echo "No such item in brunch menu. Try 'breakfast'"
fi
done
}
function addaokp() {
git remote rm gerrit 2> /dev/null
if [ ! -d .git ]
then
echo "Not a git repository."
exit -1
fi
REPO=$(cat .git/config | grep git://github.com/AOKP/ | awk '{ print $NF }' | sed s#git://github.com/##g)
if [ -z "$REPO" ]
then
REPO=$(cat .git/config | grep https://github.com/AOKP/ | awk '{ print $NF }' | sed s#https://github.com/##g)
if [ -z "$REPO" ]
then
echo Unable to set up the git remote, are you in the root of the repo?
return 0
fi
fi
AOKPUSER=`git config --get review.gerrit.aokp.co.username`
if [ -z "$AOKPUSER" ]
then
git remote add gerrit ssh://gerrit.aokp.co:29418/$REPO
else
git remote add gerrit ssh://$AOKPUSER@gerrit.aokp.co:29418/$REPO
fi
if ( git remote -v | grep -qv gerrit ) then
echo "AOKP gerrit $REPO remote created"
else
echo "Error creating remote"
exit -1
fi
}
function cmremote()
{
git remote rm cmremote 2> /dev/null
Expand Down

0 comments on commit d1b6573

Please sign in to comment.