]> xenbits.xensource.com Git - people/gdunlap/xsatool.git/commitdiff
Use staging rather than master as the default base for `master` commits
authorGeorge Dunlap <george.dunlap@citrix.com>
Wed, 27 Sep 2017 13:48:54 +0000 (14:48 +0100)
committerGeorge Dunlap <george.dunlap@citrix.com>
Wed, 27 Sep 2017 13:48:54 +0000 (14:48 +0100)
The 'master' versions are meant to be applied to staging, and aren't
generally expected to be used directly by downstreams.  If there's a
difference between master and staging, having it apply to staging is
more useful.

Signed-off-by: George Dunlap <george.dunlap@citrix.com>
git.go
repo.go
xen.go

diff --git a/git.go b/git.go
index 321d96fd3e97e6034c93e1200c2c6c7730ae99d8..1554bc60e2fc3930cff49861d160c24733d507b5 100644 (file)
--- a/git.go
+++ b/git.go
@@ -289,7 +289,7 @@ func (r Repo) AmClean(amglob string) (out []byte, err error) {
        out, err = r.gitCmd(append([]string{"am", "--reject"}, files...)...)
 
        if err != nil {
-               fmt.Printf("am failed, cleaning up tree")
+               fmt.Printf("am failed, cleaning up tree\n")
                r.gitCmd("am", "--abort")
                r.gitCmd("checkout", "-f")
                r.gitCmd("clean", "-ffdx")
diff --git a/repo.go b/repo.go
index de147ce69ebdeda0bec96839adf680ae0a45807b..5cb36d25a91969abc27971729168cab0db5ca524 100644 (file)
--- a/repo.go
+++ b/repo.go
@@ -164,6 +164,10 @@ func MainRepoUpdate(unused *XSAMeta, args []string) (ret int) {
 
                branches = append([]string{"master"}, branches...)
 
+               if tree == TreeXen || tree == TreeQemuU {
+                       branches = append([]string{"staging"}, branches...)
+               }
+
                for _, branch := range branches {
                        if _, err = xr.MergeDefault(branch); err != nil {
                                err = fmt.Errorf("Merging branch %s on tree %v: %v\n",
diff --git a/xen.go b/xen.go
index 5bdbeeb802496e6ba125c779dff1d488c434cafc..e14694970151e95276ddc233c405ff7e3c63fcaa 100644 (file)
--- a/xen.go
+++ b/xen.go
@@ -226,7 +226,7 @@ func (xr *XenRepo) releaseTagPrefix() (s string) {
 
 func XenStableBranch(v XenVersion) string {
        if v == XenVersionMaster {
-               return "master"
+               return "staging"
        } else {
                return "stable-" + v.String()
        }