Your company here ā€” click to reach over 10,000 unique daily visitors

hub-init - Man Page

Initialize a git repository and add a remote pointing to GitHub.

Examples (TL;DR)


hub init -g



After initializing the repository locally, add the "origin" remote pointing to "USER/REPO" repository on GitHub.

USER is your GitHub username, while REPO is the name of the current working directory.


$ hub init -g
> git init
> git remote add origin git@github.com:USER/REPO.git

See Also

hub-create(1), hub(1), git-init(1)

Referenced By

hub(1), hub-create(1), hub-delete(1).

11 Feb 2024 hub version 2.14.2 hub manual