-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
>Whoa! Git is very weird in some respects.
Trust me, it is not. Let me see if i can clarify things :)
>
>Why must I clone a repo, giving me the master, then do a git branch
> just to get to some branch?
Forget SVN. You are not cloning a branch. You are cloning a whole repo,
including all its branches amd the full history.
You can now check out any branch, any commit, diff anything you like without a
network connecrion..Superfast, because there is no slow server that does stuff
for you.
While this seems like a waste of space, you will be amazed (I was, too) that a
*full* checkout of a git repo (including access to all history) does take just
as much space as a single checked out svn branch without history. Git is so
much better at compressing.
>When I clone a repo, the file list (as viewed with a file manager)
>shows
>one thing (the master). Then when I git branch to change to some
>branch,
> suddenly the file list shows something completely different (now the
> branch instead of master).
Uhm, well, I might be the guilty here (as well as below.)
GitHub displays nice things if the README is in the main directory ./, not
under ./muse2/
So on the master branch, i moved these README files and committed.
I assume that these files, as well as COPYING are the only files that have
changed location. This is intended.
If you merge branch into your branch again, this will of course be applied to
your branch, as well.
>
>Seems very odd, goes against all normalities of computing - to have
>the
> list of files suddenly change like that.
>
>Why can't I just directly clone some branch I'm looking for?
Because you are not cloning a branch, but a repo. And you can display one
branch at a time.
>For that matter, why can't I clone all branches at once like with SVN?
Git is not SVN, and this one has annoyed me for some time. Until i found a tool
called "git-new-workdir". It allows you to create multiple checked out branches
of the *same clone*; so no need for multiply cloning, and you still can have
all branches you like.
Will write more about git-new-workdir tomorrow (smartphone).
>I like to have all branches on my system at once for reference or
>working
> on several at the same time.
With this tool, thats possible :)
>
>Seems to me novice users (like me, he he) would have a hard time
> figuring out exactly how to get the branch they're looking for.
Actually, learning git without prior SVN knowledge is much easier than if you
have used SVN before.
git is not SVN, and don't conpare them. They're not brothers or children, like
CVS/SVN were. The're more like dolphins (which are not fish) and sharks. Both
are large, both can do the same ("swim"), but that's all. The're different.
I'll try to help you to get around with git ;)
>There are no instructions for doing so on the host pages.
actually, there are pretty good hwotos. Have you tried the github bootcamp? Or
the git learning site... ummm... "learn git"? "try git"? "git school"? it
offers you a prompt with a step by step howto. will searxh the link tomorrow
(phone)
>
>---------
>Also, Flo I followed your instructions for transferring the origin,
> as applied to my midi_engine_fixes branch, and now I suspect its
> git config file is not correct:
i never dealt with git config files, i strongly doubt that youve a problem with
the *config file*.
>I pushed some small changes, and while the github repo did change
>correctly, I got a denial error saying I was also trying to change
>master.
This is because you probably were trying. "git push" by default pushes all
branches, not jusz the branch that is checked out (thats configurable, thouhj
not the solution of your prpblem)
What i think:
in the clone you dedicated for the branch (tip: use git-new-workdir instead of
havong multiple clones), you have (possibly accidentially) conmitted stuff to
*master*.
git push tried to push that, but failed, because "origin/master is 1 commit
ahead of your local master". That is, someone else (me!) pushed earlier than
you. Git requires you to merge the changes first, just as svn did require you
to "svn update", before committing.
I mentioned above that i committed the move of the readmes. This is causing the
error message.
If you have relevant changes on master, do this:
git checkout master (git-new-workdir would be fine, too)
git pull
this probably works automatically, and might prompt you for a "merge commit".
that's fine.
if it fails, then you have merge conflicts you must resolve (git is much better
at auto-resolving than svn, though!)
follow the instructions on the screen in this case.
then retry the git push.
if there was only an accidential commit *that was never publicized anywhere*,
you can remove it (danger: one of the few things than can and will cause data
loss!) using
git checkout master
git reset master^ (deletes the last commit) or read-the-manpage for deleting
more. again: caution!
as a beginner, checking that github is fully up to date, then deleting your
local clones and re-cloning always helps :)
Hope this helps :)
cheers,
flo
(sorry for the typos, smartphone)
-----BEGIN PGP SIGNATURE-----
Version: APG v1.0.8
iQFCBAEBCAAsBQJSMPm/JRxGbG9yaWFuIEp1bmcgPGZsb3JpYW4uYS5qdW5nQGdt
eC5kZT4ACgkQc931Ar+c+qWjuwgAh6pMYtq5csmX4J0PNSRPFNdGne+5Wr7F/yEO
AT7SR5V2C1riCUbQUhBgT5k8PU90pA12hV4D+3V/DfKuxM+R+Flo3pe2WzOBCZ8Y
2d7s5VecYAteXdVk0JuuScwzsf5+G911d3unliQRYa3dRfTrtewemtIfQGAHla4L
Bj5NTaMohhJhAmadH16uToKXk3INAykdpGSNliCfYqHEzmX9Z3RHIrLBOWSR6w9o
qHS7FRfUBQr4742Znu/xDm9pN7MtfzncTVlS1wELDmQm53Yjk1pTTcUOfi+aNqkj
3OqAB0lxavjAqgcd9taQFq9DQAyGm+eSLJZ0f5fGVB12te25IA==
=IBXf
-----END PGP SIGNATURE-----
------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. Consolidate legacy IT systems to a single system of record for IT
2. Standardize and globalize service processes across IT
3. Implement zero-touch automation to replace manual, redundant tasks
http://pubads.g.doubleclick.net/gampad/clk?id=51271111&iu=/4140/ostg.clktrk
_______________________________________________
Lmuse-developer mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/lmuse-developer