blob: bc79d5a68486b9d9821cd08554839131663192ef [file] [log] [blame]
Wes Garner30f46352010-08-18 12:47:27 -05001#!/bin/sh
2#
3# Gerrit tool for easiness of submitting changes to CM repos
4# Wes Garner
Wes Garner75c82dd2010-08-18 15:04:53 -05005# Usage: cmgerrit <CM Gerrit username> <repo> <for/changes> <branch/change-id>
6# Note: for = new submissions, changes = new patch set for current submission
Wes Garner30f46352010-08-18 12:47:27 -05007#
8
Wes Garner75c82dd2010-08-18 15:04:53 -05009user=$1
10repo=$2
11mode=$3
12target=$4
13
14if [ -z $user ]
15then
16 echo "Type your CyanogenMod Gerrit username: "
17 read user
18 echo "What is the repository you are submitting to? (ex. android_vendor_cyanogen) "
19 read repo
20 echo "Is this a new change or a new patchset to a current change? (for = new, changes = patch set) "
21 read mode
22 echo "What is the branch (for a new change) OR change-id (for a current change) you are working with? "
23 read target
24fi
25
26git push ssh://$user@review.cyanogenmod.com:29418/CyanogenMod/$repo HEAD:refs/$mode/$target
27