Commit d80eb870 authored by Chris Bills's avatar Chris Bills

Organize README more better

parent 09da6fde
##### Note; Replace gitlab.cels.anl.gov with xgitlab.cels.anl.gov if you are accessing or working with xgitlab.cels.anl.gov.
### Getting Started with GitLab
1. Generate an SSH keypair for GitLab (optional)
* `ssh-keygen -t rsa -b 2048 -f ~/.ssh/gitlab.cels.anl.gov`
1. Add your SSH public key to your account on GitLab:
1. Browse to: https://gitlab.cels.anl.gov/profile/keys
1. Click Add SSH Key (top-right)
1. Set the title to something meaningful
1. Copy your public key and paste it into the Key field
1. Click Add Key
1. Add an entry for GitLab in your ~/.ssh/config file (Optional but very convenient)
* This will allow you to type something like `git clone gitlab:namespace/project.git` without needing to pass a username, fqdn, or ssh identity to git
```
Host gitlab
User git
Hostname gitlab.cels.anl.gov
IdentityFile ~/.ssh/gitlab.cels.anl.gov
```
#### **NOTE** - Replace gitlab.cels.anl.gov with xgitlab.cels.anl.gov in the examples if you are working with xgitlab.cels.anl.gov.
### bash-functions
......@@ -56,6 +34,28 @@ A collection of useful git aliases. These can be placed in `~/.gitconfig` (recom
* `squash` - Does an interactive rebase of the previous # commits; useful for squashing commits
* `stashed` - Display information about stashes
### Getting Started with GitLab
1. Generate an SSH keypair for GitLab (optional)
* `ssh-keygen -t rsa -b 2048 -f ~/.ssh/gitlab.cels.anl.gov`
1. Add your SSH public key to your account on GitLab:
1. Browse to: https://gitlab.cels.anl.gov/profile/keys
1. Click Add SSH Key (top-right)
1. Set the title to something meaningful
1. Copy your public key and paste it into the Key field
1. Click Add Key
1. Add an entry for GitLab in your ~/.ssh/config file (Optional but very convenient)
* This will allow you to type something like `git clone gitlab:namespace/project.git` without needing to pass a username, fqdn, or ssh identity to git
```
Host gitlab
User git
Hostname gitlab.cels.anl.gov
IdentityFile ~/.ssh/gitlab.cels.anl.gov
```
### Cloning a Repository
Once you've set up SSH, cloning a repository hosted on GitLab is pretty simple and straightforward. The structure of a repository's URI is: <host>:<namespace>/<project>.git (example: gitlab:systems/git-tips.git). Determine where you want to clone the repository; a directory like ~/projects/ works pretty well, but it really doesn't matter; wherever you are most comfortable working.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment