I am trying to have a simple file which changes the directory where the user currently is. If I run the file using . ./Genesis then the source files works fine. But I want to just use ./Genesis and have the cd command work.
I am in my root/Scripts folder: kyle@computer:~/Scripts
How can I modify the code to do this?
I have a file called Genesis which calls a source file
#!/bin/bash
#Genesis
. ./Genesis.sh
The Genesis.sh file has the following code:
jhome() {
cd ~/Scripts/dungeon
}
jhome