Explorar o código

Create a function to cd to a git repo root

DricomDragon %!s(int64=5) %!d(string=hai) anos
pai
achega
cb02b3c5b2
Modificáronse 1 ficheiros con 5 adicións e 0 borrados
  1. 5 0
      Install/Templates/fish/functions/cdg.fish

+ 5 - 0
Install/Templates/fish/functions/cdg.fish

@@ -0,0 +1,5 @@
+function cdg --description 'Go to root folder of the current Git repository'
+    if set -l GIT_ROOT (git rev-parse --show-toplevel)
+		cd $GIT_ROOT
+	end
+end