diff options
| author | srdusr <[email protected]> | 2022-11-28 21:27:45 +0200 |
|---|---|---|
| committer | srdusr <[email protected]> | 2022-11-28 21:27:45 +0200 |
| commit | f7aec23756541cacadf8341e5d2e696005e0732f (patch) | |
| tree | 0269361b9d55d43f069b2a4a2fa4d326eb7cdcbb /tools/git.md | |
| parent | 55e0ec19b1255aeebf3653c8bc703168038967b2 (diff) | |
| download | notes-f7aec23756541cacadf8341e5d2e696005e0732f.tar.gz notes-f7aec23756541cacadf8341e5d2e696005e0732f.zip | |
Add git basics
Diffstat (limited to 'tools/git.md')
| -rw-r--r-- | tools/git.md | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/tools/git.md b/tools/git.md index 6b9b6f1..e71abec 100644 --- a/tools/git.md +++ b/tools/git.md @@ -1,4 +1,4 @@ -## Dotfiles +### Dotfiles - Intialize git and create a folder named ~/.cfg ```bash git init --bare $HOME/.cfg @@ -27,3 +27,27 @@ config push config submodule add https://github.com/user/repo.git .path/to/repo config submodule update --remote --merge + +- - - + +### Basic commands +Intialize a git repository in the root of the folder. +```bash +git init +``` +See which files git knows exist. +```bash +git status +``` +Add a new file to the repo. +```bash +git add <file> +``` +Create a commit with a message about the commit. +```bash +git commit -m <file> +``` +Push the changes/commits to our repo. +```bash +git push -u main +``` |