Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I found this script http://dotfiles.org/~jacqui/.bashrc.. Basically this is a shortcut for cd-ing my file system..

I can type "save nm" where "nm" is any short name for the directory, like "blog" or "blg" Then whenever I want to go to nm I'll just use 'cd nm'

But it is not working out for me, I get this error every time I enter save:

bash: save: command not found
bash: parse_git_branch: command not found

So How can I make this command work?

share|improve this question

1 Answer 1

That means the function isn't being created or there is an error in your ~/.bashrc file like a missing or extra quote or curly brace.

Did you start a new shell or source ~/.bashrc from the current one so the changes take effect?

Try type -a save to see if it outputs a function definition.

Try grep -C 4 save ~/.bashrc to make sure there is something in that file that looks reasonable.

Load ~/.bashrc in an editor that does syntax highlighting and check very carefully to make sure that all quotes, brackets, braces and parentheses are balanced and that nothing is missing or doesn't belong.

If you still can't find the problem, post your file as an edit to your question or on a paste bin site and we can take a look at it.

share|improve this answer
    
I copy paste the file from the url to my ~/.bashrc file.. Don't know why it doesn't work.. –  Raymond Go Ho Feb 19 '11 at 3:24
    
everytime i hit save, I get this error: -bash: =/home/ec2-user: No such file or directory -bash: =/var/www/html/helloZend: No such file or directory -bash: =/home/ec2-user: No such file or directory -bash: =/home/ec2-user: No such file or directory -bash: =/home/ec2-user: No such file or directory –  Raymond Go Ho Feb 19 '11 at 3:26
    
@RaymondGoHo: There's no reference in that file to "/home/ec2-user". How exactly did you "copy paste"? What is in your ~/.dirs file? What happens when you try each of the steps I outlined in my answer? –  Dennis Williamson Feb 19 '11 at 4:58

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.