if I'm in a very deep directory a/b/c/d/e/f/g/h/i/j and want to come back a/b/c, I have to use ../../../../../../../.
Is there command I can pass through a number, e.g. cd up 7, to speed this operation up?
|
|
|
Creating an alias would work as a temporary solution, however if you want something more permanent that doesn't confine you to your presets I suggest writing a function to do this and including it in your .bashrc file.
|
|||||
|
|
You can create aliases to do the work.
And then you can just type |
|||
|
|
|
If you are toggling between 2 directories, you can use If you want to bookmark a few directories, that you would probably cd to often, use Or, if you know you have to cd to 7th grand parent very often, you could create an alias, like
|
|||||
|
|
You could write a function like this:
Put that in your |
|||
|
|
|
Be concise.
|
|||
|
|