π»π§°π§ #gocd: Little #Bash command to change working directory, as traditional #cd command, but with a NAME instead a directory, from a list of association NAME: DIRECTORY.
https://bitbucket.org/OPiMedia/gocd-bash/
By example, if configuration file contents this line: git ~/data/git
$ gocd git
is equivalent to run
$ cd ~/data/git; ls
$ gocd git archives/library/assertopencl/
is equivalent to run
$ cd ~/data/git/archives/library/assertopencl/; ls
Both arguments are autocompleted.
I added -n and -q options.
-n just print target directory, without change working directory.
-q quiet, don't run ls at the end.
Examples:
$ gocd -nq ParSigmaOdd progs/
just print (even if this path doesn't exist) $HOME/data/git/current/parallel-sigma_odd-problem/progs/
$ cat $(gocd -nq ParSigmaOdd README.md)
is equivalent to run
$ cat $HOME/data/git/current/parallel-sigma_odd-problem/README.md
New version of #gocd π§π§°, a #cd alternative that takes first a shortcut:
https://bitbucket.org/OPiMedia/gocd-bash/
Two workarounds to run it in #sh, #ksh, #zshβ¦
#gocdBash #Bash #shell