axiom-developer
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Axiom-developer] Silver


From: C Y
Subject: Re: [Axiom-developer] Silver
Date: Sun, 20 May 2007 12:36:49 -0700 (PDT)

--- address@hidden wrote:

> HOW?
> 
> 1) get the code
>   git-clone ssh://address@hidden/home/git/silver silver
> 
>   the clone is a full, independent git repository. people can clone
>   your whole repository, pull changes from your repository, or push
>   changes to your repository. thus you are the center of the world.

Works.
 
> 2) branch the code
>   git-branch mybranch
> 
>   if you work on a single problem (eg an algebra bug) in a single
>   branch you will naturally accumulate a changeset. since git will
>   not copy files the branch is only a few bytes big. you can have
>   as many branches as you wish so each branch can be a single idea
>   or problem.

OK, that command appears to succeed.
 
> 3) list the branches
>   git-branch
> 
>   you can see all of the branches you have created

Works:

$ git-branch
* master
  mybranch

> 4) change to the new branch
>   git-checkout mybranch
> 
>   if mybranch is related to one single change then you can work
>   on that change locally independent of all other work.

$ git-checkout mybranch
Switched to branch "mybranch"
$ git-branch 
  master
* mybranch

> 5) change something
>   echo "it works" >>FAQ
>
>  here we modify the FAQ file

Done:

...
developer mailing lists. 
it works

> 6) remember the change
>  git-add test
>
>  NOTE: git does not know about files, it knows about changes.
>  If you change something you need to tell git you want to add that
>  change to the set of changes to keep. So "git-add" means ADD THE
>  CHANGE, NOT ADD THE FILE. git only cares about content. it does
>  not track files. This is different from other source code control.

This is where I run into trouble:  
$ git-add test
fatal: pathspec 'test' did not match any files

> 8) change to the master branch
>  git-checkout master
>
>  Now that we've made our glorious change in isolation it is time to
>  merge it back onto the main tree. So first we switch to the master
>  tree (or whatever tree we want)
>
>8) merge the branch
>  git-merge mybranch
>
>  And we merge the master and mybranch trees

Two questions - since the FAQ file is modified, switching back to the
master branch doesn't expose a view of the FAQ change without the "it
works" line added, at least when I tried it.  If I have multiple
branches going at once, and I want to check how one builds vs. another,
wouldn't this be a problem?  Also, since a build test might produce
files that cleanup wouldn't get rid of, wouldn't those build files get
sucked into the changeset?

Also, would deleting an un-merged branch that made changes to the files
result in "rolling back" the changes in the tree?  When I tried this
the change to FAQ survived the delete of the branch, despite never
adding the change successfully.

Sorry if these are silly questions.

CY


       
____________________________________________________________________________________Yahoo!
 oneSearch: Finally, mobile search 
that gives answers, not web links. 
http://mobile.yahoo.com/mobileweb/onesearch?refer=1ONXIC




reply via email to

[Prev in Thread] Current Thread [Next in Thread]