Skip to content

Instantly share code, notes, and snippets.

@cajones
Created February 3, 2012 10:07
Show Gist options
  • Save cajones/1729479 to your computer and use it in GitHub Desktop.
Save cajones/1729479 to your computer and use it in GitHub Desktop.
GitHub: Init local repo
function Git-Init($project, $username = 'your-username-here') {
md $project
cd $project
git init
ni -t f readme.md
git add .
git commit -m "first commit"
git remote add origin git@github.com:$username/$project.git
git push -u origin master
Write-Host "$project has been created and pushed to github."
start "https://github.com/$username/$project"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment