I am researching switching from starteam to Git.
Currently, in starteam, we use "floating views" with special names. These floating views basically work like aliases. Therefore, we can specify a specific alias to checkout from and we'll get the branch that we're currently model testing.
How would this be done in Git? This is basically how our branches are organized:
These are all branches
master (stable view)
| - Branch 2012.05.01
| | - Project 1
| | - Project 2
| | - model [floating view / alias to Branch 2012.05.01]
|
| - Branch 2012.07.11 (these would also have various child views for projects)
| - Branch 2012.10.17
(Branch 2012.05.01
would be merged to master
when model testing is complete.)
In our automated scripts (ant), to run our model deployment, we just checkout from our branch called model
. This way we never have to change our scripts as we change which branch we are model testing, and finding out which view we're model testing is as easy as figuring out which branch the model
branch references.
Is there any such way to do something similar in Git?
To clarify:
- I want an alias of a branch. A branch, not a commit.
Branch 2012.05.01
means the branch intended to be shipped on 2012.05.01, it doesn't mean a 2012.05.01 moment in time.- I want an alias to
Branch 2012.05.01
.Branch 2012.05.01
is an integration branch, it's constantly modified. But I don't want to reference it asBranch 2012.05.01
, I want to reference it asmodel
. This way, I can change my the alias toBranch 2012.07.11
and it will get the most recent code from that branch without changing any of the checkout code script.
git symbolic-ref refs/heads/master refs/heads/main
-- if your repository hasmain
but your habits are oldschool :) – Exoergic