Skip to content

Commit 00bc7de

Browse files
committed
Added git snippets
1 parent 65a6ec5 commit 00bc7de

File tree

4 files changed

+16
-0
lines changed

4 files changed

+16
-0
lines changed

git/add-submodule.ps1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Add new submodule
2+
git submodule add git://github.com/jquery/jquery.git externals/jquery
3+
git submodule update --init --recursive

git/git-snippets.ps1

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# create a new Git branch based on a specific commit SHA
2+
git checkout -b BRANCH_NAME COMMIT_SHA

git/specify-user.ps1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
## Specify user
2+
git config user.name "AuthorExample"
3+
git config user.email "ae@duck.com"

git/worktree.ps1

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
# list all worktrees
2+
git worktree list
3+
4+
# add a worktree to folder _branch using branch 'issues/templates_enabled_flag'
5+
git worktree add _branch issues/templates_enabled_flag
6+
7+
# remove a worktree from folder _branch
8+
git worktree remove _branch

0 commit comments

Comments
 (0)