Try Git
try.github.io
try.github.io
I'm pretty sure I've mentioned this to John Britton at one of GitHub meetups. He played some part in making that from the GitHub side, as he does education stuff with them.
That was about 3 years ago. Since then I've got a nice software engineering job in San Francisco, and I've been trying to make as many open source contributions in my free time as I can:
1,737 total in year of contributions (not counting private) hehe.
Learning to use git was an eventual step of the journey, but your work certainly played a part in enabling all that, so thank you. :)
1) I don't think providing the message (-m) on the command line is a good habit for beginners.
2) https://try.github.io/levels/1/challenges/7 is a wild card operation followed by a `commit -m`. Prior to the commit there should be another `status` or interactive commit (no -m), see (1) above.
1) That's true. Although sending beginners into a less/vi commit interface that is even more bewildering than the basic shell is not a good way to concisely introduce people to a new tool. The hardest part of teaching is what you chose not to teach. 2) We purposefully used the GUI file browser (My Octocat Repository) at the bottom to avoid having to systematically do `git status` in order to check the state of the repo.
Adding this artificial element furthers concisely introducing people to a new tool? If you are going to teach a CLI then stay in the command line.
Also, you didn't solve the problem as the GUI file browser doesn't show the status of the files either.
Why? I started that way and still do it today. Is it considered a bad practice?
A commit message should be formatted like an email to your past self, or your future collaborators. It should have a very descriptive and concise title (the first line of the message) written in the present tense and after a line break you should (when necessary) write an email style explanation of the reasoning behind the commit.
If you fixed something, is there context that should be useful for someone discovering this commit in a vacuum. Are there any related commits? If you added something, why? There is so much useful information that can be encoded in a commit message and discovered when someone does a `git blame` for example.
Caleb Thompson wrote a nice concise post on this: http://robots.thoughtbot.com/5-useful-tips-for-a-better-comm...
git commit -m "fixed the widget factory" -m "It seems like we keep getting wooden shoes stuck in the machine, so I added a ShoeClearingDaemon process to check periodically and restart the machine if necessary."- "1.2 The repository is a hidden directory where Git operates." OK
- "1.3 I created a file called octocat.txt in the octobox repository" WAT
- GUI labeled "My Octobox Repository" HMM
Unfortunately, there is no tab autocompletion, which makes it really a hassle to enter "git add [specific file]" and similar commands.
I also like the idea of simulating the timing, such that the commands don't always return immediately.
However, I'm a bit surprised about the exact timing values. For example, "git init" took quite some time while "git status" was really quick. In reality, it is the other way around.
`git add .` worked as well and clicking the command autoenters it at the prompt.
$ mkdir baz
$ cd baz
$ time git init
Initialized empty Git repository in ~/src/tmp/baz/.git/
real 0m0.015s
user 0m0.002s
sys 0m0.008s
$ time git status
# On branch master
#
# Initial commit
#
nothing to commit (create/copy files and use "git add" to track)
real 0m0.012s
user 0m0.002s
sys 0m0.003sIf you don't know the git data model (DAG) and learn it by using commands, you have to explicitly learn the 'advanced' stuff.
If you learn the git data model and fully understand how everything is simply a DAG, there is nothing advanced about it. However, grokking the git data model may take sometime.
For those that do not want to type, you can click the command and it will writes it into the console for you.
Interesting analogies they use in the tutorial.
> Since we love octocat more than octodog, we'll turn his frown around by removing octodog.txt.
to
> Since we love octocat more than we love octodog, we'll turn his frown around by removing octodog.txt.