powershell_git

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
powershell_git [2022/01/01 13:43] mguptonpowershell_git [2022/01/01 18:48] (current) mgupton
Line 17: Line 17:
 === Command Aliases === === Command Aliases ===
 <code powershell>  <code powershell> 
 +
 +function git-init {
 +    if (-not(Test-Path -Path ".\.git")) {
 +        git init
 +    
 +        git config --global core.excludesFile ~/.gitignore
 +        git config --global user.name "John Doe"
 +        git config --global user.email jd@infostar.me
 +        git commit --allow-empty -m "Empty commit for initializing the repo"
 +        git checkout -b working
 +    }
 +}
 +
 function git-save { function git-save {
     git add .; git commit     git add .; git commit
Line 31: Line 44:
    
 # #
-# List files that were part if the specified commit.+# List files that were part of the specified commit.
 # #
 function git-ls($commit) { function git-ls($commit) {
  • powershell_git.1641044623.txt.gz
  • Last modified: 2022/01/01 13:43
  • by mgupton