{"action":"created","issue":{"url":"https://api.github.com/repos/swcarpentry/workshop-template/issues/111","labels_url":"https://api.github.com/repos/swcarpentry/workshop-template/issues/111/labels{/name}","comments_url":"https://api.github.com/repos/swcarpentry/workshop-template/issues/111/comments","events_url":"https://api.github.com/repos/swcarpentry/workshop-template/issues/111/events","html_url":"https://github.com/swcarpentry/workshop-template/pull/111","id":53090218,"number":111,"title":"Command file to add alias for scm git to profile","user":{"login":"drlabratory","id":2355087,"avatar_url":"https://avatars.githubusercontent.com/u/2355087?v=3","gravatar_id":"","url":"https://api.github.com/users/drlabratory","html_url":"https://github.com/drlabratory","followers_url":"https://api.github.com/users/drlabratory/followers","following_url":"https://api.github.com/users/drlabratory/following{/other_user}","gists_url":"https://api.github.com/users/drlabratory/gists{/gist_id}","starred_url":"https://api.github.com/users/drlabratory/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drlabratory/subscriptions","organizations_url":"https://api.github.com/users/drlabratory/orgs","repos_url":"https://api.github.com/users/drlabratory/repos","events_url":"https://api.github.com/users/drlabratory/events{/privacy}","received_events_url":"https://api.github.com/users/drlabratory/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2014-12-30T03:15:38Z","updated_at":"2015-01-05T21:57:00Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/swcarpentry/workshop-template/pulls/111","html_url":"https://github.com/swcarpentry/workshop-template/pull/111","diff_url":"https://github.com/swcarpentry/workshop-template/pull/111.diff","patch_url":"https://github.com/swcarpentry/workshop-template/pull/111.patch"},"body":"Newer versions of Mac OS X actually come with git, kind of. A binary in `/usr/bin/git` exists by default, but trying to run it will trigger a prompt to install the Xcode command line tools. Even after installing SCM git, `/usr/bin/git` is still ahead of `/usr/local/git/bin/git`in the `$PATH`. This is what leads to the infamous situation of people installing SCM git like they are supposed to, but still getting that damn pop-up on the first morning of the workshop.\r\n\r\nThis script attempts to rectify that by adding an alias for `git` to the user's `.bashrc` or `.bash_profile`. I think this is better than trying to mess with users' `$PATH` in a reliable way. It is a `.command` file, which means users can just double click it to run it in the Terminal. It tries to be a unobtrusive as possible.\r\n\r\nThe alternative would be to have users just install the Xcode command line tools instead of SCM git, but I'm not sure how big it is.\r\n\r\nComments/changes welcome."},"comment":{"url":"https://api.github.com/repos/swcarpentry/workshop-template/issues/comments/68789249","html_url":"https://github.com/swcarpentry/workshop-template/pull/111#issuecomment-68789249","issue_url":"https://api.github.com/repos/swcarpentry/workshop-template/issues/111","id":68789249,"user":{"login":"gdevenyi","id":3001850,"avatar_url":"https://avatars.githubusercontent.com/u/3001850?v=3","gravatar_id":"","url":"https://api.github.com/users/gdevenyi","html_url":"https://github.com/gdevenyi","followers_url":"https://api.github.com/users/gdevenyi/followers","following_url":"https://api.github.com/users/gdevenyi/following{/other_user}","gists_url":"https://api.github.com/users/gdevenyi/gists{/gist_id}","starred_url":"https://api.github.com/users/gdevenyi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gdevenyi/subscriptions","organizations_url":"https://api.github.com/users/gdevenyi/orgs","repos_url":"https://api.github.com/users/gdevenyi/repos","events_url":"https://api.github.com/users/gdevenyi/events{/privacy}","received_events_url":"https://api.github.com/users/gdevenyi/received_events","type":"User","site_admin":false},"created_at":"2015-01-05T21:57:00Z","updated_at":"2015-01-05T21:57:00Z","body":"Editing a $PATH is pretty reliable, we could just do\r\n\r\nPATH = \"/usr/local/git/bin/:$PATH\"\r\n\r\nThis would prepend the other git install and fix the issue."}}