.bashrc is the Bash shell configuration file for a user's terminal login session.

learn more… | top users | synonyms

1
vote
1answer
415 views

I can't run any command in Terminal

I tried to enter the command nano ~/.bashrc in order to include some path into the .bashrc file in home directory but I'm not able to run any command and I get always the following error: ...
8
votes
3answers
7k views

How to restore .bashrc file?

The terminal shows this when it opens: bash: /home/atlas/.bashrc: line 73: syntax error near unexpected token `[' bash: /home/atlas/.bashrc: line 73: `if [ -x /usr/bin/dircolors ] ; then ' I've ...
4
votes
1answer
577 views

changes to /etc/bash.bashrc not permanent

After a recent upgrade to 12.04, auto tab completion was disable in /etc/bash.bashrc. I uncommented the following lines: if [ -f /etc/bash_completion ] && ! shopt -oq posix; then . ...
0
votes
2answers
622 views

Screwed up terminal after modifying bashrc

I ended up screwing up my terminal, while setting up Sbt for the Coursera Scala course. I can't summon gedit (or anything else) anymore. I got the following error: Command 'gedit' is available in ...
0
votes
2answers
1k views

adding executable file to path and launching from terminal directly

i just downloaded sublime text for my ubuntu, and its working fine. i have the executable file in my ~/sublime folder. now i would like to invoke this app from the terminal by just typing ...
5
votes
1answer
291 views

My bash function runs only once per terminal opened

When I try to run my bash function, defined in .bashrc, for a second time in the same terminal, it doesn't work. The code is the following: function nos (){ local option while getopts cs ...
0
votes
2answers
834 views

Running gedit in background

So I've got this working in a 10.04 ubuntu OS in bash where I can run: $ gedit app/file.rb bash opens that file with gedit but it is tied up. How can I make my earlier command equivalent to $ ...
1
vote
1answer
2k views

How do I source a shell script for Node Version Manager?

Hi and thanks for looking! I am new to Linux/Ubuntu, but I have set up an Ubuntu box on which to run Node.js. I have had moderate success, but now I need to be able to easily upgrade my version of ...
3
votes
1answer
176 views

.bashrc not responding

I'm having an odd problem with the .bashrc file. I've added the following line so git could show me the current branch on prompt (I saw this tip here) #Show branch in status line PS1='[\W$(__git_ps1 ...
1
vote
3answers
2k views

PATH variable resets with reboot

Just as the title indicates my PATH variable resets after every reboot. I read that I have to edit my bashrc file's PATH variable, but I don't have anything there that suggests anything related to the ...
2
votes
1answer
295 views

How to stop bash prompt colours from escaping

I'm trying to configure bash to display the current git branch, based off the example here, but I can't figure out how to get bash to stop escaping the colour strings. Everything I try results in the ...
2
votes
3answers
302 views

What do I do if I want to execute ls command everytime I do a cd to any directory?

Most of the time when I do a cd command I also do a ls to see what other files or folder are in that directory. So I want to execute ls everytime I change the directory. I know I can do cd foo ...
11
votes
2answers
16k views

.bashrc not executed when opening new terminal

The code in .bashrc does not execute when I open a new terminal window in Ubuntu 12.04. I noticed this when creating a .bash_aliases file. The aliases did not show up when I opened a new terminal. ...
1
vote
2answers
3k views

Gnome terminal is not running source .bashrc?

I have a clean installation of Ubuntu 12 and I installed bashmarks, a utility to have favorites folders on the terminal. One of the steps is to include source ~/.local/bin/bashmarks.sh at the end of ...
2
votes
2answers
3k views

~/.bashrc return can only 'return' from a function or sourced script

I am trying to setup a OpenStack box to have a look at OpenStack Object Storage (Swift). Looking through the web I found this link; http://swift.openstack.org/development_saio.html#loopback-section ...
10
votes
3answers
20k views

Specify JDK for tomcat7

I have installed tomcat7 (using apt-get install) and whenever I want to start tomcat7 it says : * no JDK found - please set JAVA_HOME I have set JAVA_HOME in my bash.bashrc and also in ~/.bashrc ...
10
votes
6answers
11k views

How to add an alias to a command in terminal?

By typing a manually specified command in terminal i want to do some. How could add an alias to a command? Can i do that with the help of the terminal or should i edit some kind of file?
9
votes
5answers
11k views

difference between bash.bashrc and /etc/environment file

Till data I was used to set my environment variables in the bash.bashrc file. Recently I told to use the /etc/environment file. Well, both work fine. So, what is the difference between them? I ...
0
votes
1answer
941 views

pactl module-loopback loaded every time computer is turned on

The pactl module module-loopback is loaded every time I turn on my computer. I'm not sure why, but I always have to use pactl unload-module 20 (for some reason the module is always id 20). Is there ...
18
votes
2answers
14k views

How can I shorten my command line (bash) prompt?

Currently it is: michael@Castle2012-Ubuntu-laptop01:~/Dropnot/webs/rails_v3/linker/spec/controllers$ Outside of renaming my machine and directory structure... How could I make it be something ...
4
votes
5answers
884 views

How can I uniqely record every new command I use, and possibly timestamp it?

I've been on Linux for more than 6 months now but never went too much into the CLI (command-line interface or terminal or shell) Now as I ask questions here, get answers, or help from other sites, I ...
5
votes
1answer
447 views

Synchronize profiles across servers (.vimrc and .bashrc)

I'm on a few different servers on any given day. I'm starting to really tweak two files in my bash profile: .vimrc and alias.sh. Would anyone have a recommended way to save and sync these two files. ...
12
votes
2answers
13k views

Configure gnome-terminal to start bash as a login shell, doesn't read .bashrc

I'm trying to integrate RVM with gnome-terminal. Per default, gnome-terminal does not start bash as a login shell. I enabled run command as a login shell as suggested in this answer about the same ...
2
votes
1answer
2k views

~/.bashrc changes have no effect?

I have been trying to set some custom colors on the user@hostname:~$ on the terminal. I edited both ~/.bashrc and /etc/bash.bashrc Where it said: debian_chroot:+($debian_chroot... I just changed ...
1
vote
0answers
735 views

what to do about .ssh-agent pop up at login screen? [closed]

I was setting up git with a ssh key passphrase on Ubuntu 12.04 via the terminal with the assistance of Help.GitHub: "You can run ssh-agent automatically when you open bash by adding the following to ...
23
votes
6answers
143k views

Where is .bashrc?

I feel stupid asking, but I can't seem to find the answer to this anywhere. I'm trying to follow these instructions to edit my bash prompt, but there is no .bashrc in either my user directory ...
15
votes
2answers
8k views

Changing colors for user, host, directory information in terminal command prompt

Is it possible to change the colors in the command prompt for the user@computer, as well as the the current directory and command parts of the prompt display? I've already seen something like this ...
47
votes
4answers
60k views

Why ~/.bash_profile is not getting sourced when opening a terminal?

Problem I have an Ubuntu 11.04 Virtual Machine and I wanted to set up my Java development environment. I did as follows sudo apt-get install openjdk-6-jdk Added the following entries to ...
2
votes
1answer
635 views

Change default binaries for texlive

Ubuntu ships with texlive 2009, which installs the tex binaries into /usr/bin/latex I've installed the current version of texlive with its installer, which installs its binaries into ...
2
votes
1answer
556 views

Is it possible to have .bashrc outside home directory?

I want to put a .bashrc file in a directory where my application is located, to set up path variables accordingly independent of the location of the directory at the moment. At the same time, I want ...
1
vote
1answer
411 views

Error message when open terminal

This appears when I open the terminal: bash: export: `=': not valid name bash: export: `/home/(my account ...
7
votes
2answers
8k views

Root's .bashrc not executing on sudo -i

On one of my Ubuntu 11.10 servers, when I use sudo -i to become the root user, root's .bashrc is not being executed. On all other servers, whose relevant configurations are identical as far as I know, ...
0
votes
1answer
108 views

Crontab file is garbled! HELP!

I accidentally deleted my .bashrc file in Ubuntu 11.10. I think I restored it but I have two major issues now: Everything that I type has a red squiggly line under it in this field and the ...
11
votes
2answers
952 views

Can I create a separate bash history file for each terminal profile?

I use a bash script to start gnome-terminal with multiple tabs, each tab using a different profile, working directory, and in some cases executing a command within the tab. In this situation, I'd ...
2
votes
1answer
2k views

How can I set HISTSIZE for all users?

How can I set HISTSIZE for all users on Ubuntu 10.04? I've tried adding the following lines to both /etc/profile and /etc/bash.bashrc. I'm not sure I understand the difference between the two files ...
0
votes
1answer
244 views

Line gets overwritten instead of continuing on same line

I have a problem with the bash prompt. When I type a command that exceeds the length of the width of the screen it continues on the same line and overwrites what I have written, and then continues on ...
1
vote
1answer
401 views

My terminal prompt PS1 mixed up

By the way I'm on a Mac OS X but I'm connected to an Ubuntu Server. Yesterday I installed a module for node.js(after a hour I deleted it) which asked me to add something to the .bashrc file and now ...
19
votes
5answers
1k views

How do I teach bash in Ubuntu some curse words?

When bash encounters an unknown command(word?) it does this : The program 'hello' can be found in the following packages: * hello * hello-debhelper Try: sudo apt-get install <selected ...
2
votes
5answers
15k views

How to modify “/etc/bash.bashrc”? It is read only?

Trying to modify /etc/bash.bashrc I get an error: $ echo "my edit" >> /etc/bash.bashrc bash: /etc/bash.bashrc: Permission denied ls -ll /etc/bash.bashrc shows: -rw-r--r-- 1 root root 1975 ...
3
votes
2answers
2k views

Where to put custom .bashrc stuff, in .bash_local?

Just upgraded to 11.10, and prompted me to wondering where is now the preferred way to put customised .bashrc bits? I have some aliases, some env variables, and a python virtualenvwrapper script, for ...
15
votes
4answers
1k views

How (and where) can one change 'user@host $:' pattern in gnome-terminal?

When I start terminal in Ubuntu, I see: ilya@HOST:~$ I need to add a timestamp to this, something like: 2011-10-09T09:32:00 ilya@HOST:~$ How can I configure this?
7
votes
4answers
11k views

Can not successfully source .bashrc from a shell script

Normally we can source ~/.bashrc file using this command source ~/.bashrc but if I write this in a shell script and execute it, nothing happen. Why? Is there any way to do this? my shell code: ...
34
votes
3answers
14k views

Bash history search, partial + up-arrow

I have searched, but not found anything on this. I am looking for a functionality in bash, using a terminal. Way back when, I had a user on a debian system, and a friend set me up with a convenient ...
5
votes
1answer
705 views

Source/Dot operator error on login. Possibly caused by bad byobu uninstall

I am getting an error message every time I ssh into my box or run sudo -i. It looks like this for login: login as: person chands@ubuntu-server's password: -bash: .: filename argument required .: ...
4
votes
2answers
690 views

Store frequently used terminal commands in a file

Okay, so I want add a command to my Desktop (Or any convenient location), and whenever I run it I want it to clone the HTML5 boilerplate. $ git clone git://github.com/paulirish/html5-boilerplate.git ...
2
votes
3answers
3k views

I accidentally overwrite /etc/bash.bashrc file. Please give the default content

I accidentally overwrote the /etc/bash.bashrc file. Please give me the default content in that file to restore, or the file itself.
3
votes
1answer
3k views

I think I accidently deleted the PATH variable

Whatever I try to run, I get the error: The command could not be located because '/usr/bin' is not included in the PATH environment variable. I had some modification in my .bashrc file but then ...
0
votes
1answer
947 views

Screwed up my .bashrc file

I was trying to add the source command at the end so that I dont have to enter it in the command line each session, the addition I made was, in the end of the file, # Load Root Files source ...
0
votes
1answer
1k views

Setting gnome-terminal window size from within ~/.bashrc

It know that it is possible to pass the --geometry=WxH arguments when using launcher, but how to set this option with the ~/.bashrc file.
6
votes
1answer
5k views

How is ~/bin added to my path?

I have not added ~/bin to any of my .bash* files. However, $PATH does list that directory. The reason I am asking this in the Ubuntu specific StackExchange is because, well, I have exactly the same ...