You are not logged in.
I'm trying to color and reformat my console but for some reason I continue to get this error when I log in to my box:
-bash: /etc/bash.bashrc: line 27: syntax error near unexpected token ')'
'bash: /etc/bash.bashrc: line 27: '27 xterm|rxvt|Eterm|aterm|kterm|gnome)So anyways, I'm just using a standard bash.bashrc template that was posted on here: https://wiki.archlinux.org/index.php/Co … ep_by_step and I am using the main bash prompt and I'm not running any gui. I'm not really sure what the problem is and I have tried a few different things but it always seems to hang on that error.
I was hoping I could get a little help with this, as I would greatly appreciate any and all help.
Thanks.
Last edited by kevinae91 (2013-09-25 19:52:22)
Just keep it simple.
Offline
A guess: remove the '27' from the beginning of the line. There should be no line numbers in your .bashrc.
If it doesn't work, post your /etc/bash.bashrc.
Offline
Are you sure is it an exact copy of what is on the wiki? That seems OK to me, but that error is seeming to indicate that it's not picking up the 'case' section properly. Hard to tell really.
RAID !=backup
Offline
Thanks for the quick replies guys, very much appreciated. I'm leaving for class right now so I can't paste anything but as soon as I get there I will try some things and if I can't get them to work I will post my bash file here.
However, karol, your post has made me realize something. I copied this bash file from a different site that had line numbers as per the "BBCode" of that forum software. I think I may have copied all of the line numbers in to my bash file lol. I think that's causing the issue. Now I just feel stupid...
Last edited by kevinae91 (2013-09-25 20:15:19)
Just keep it simple.
Offline
If you haven't done any modifications, simply use https://wiki.archlinux.org/index.php/Co … stallation
I noticed that the case statement you have looks a bit different - no '*' like in 'xterm*' etc. so there may be other tiny differences in the file you have v. the one in the wiki.
Offline
No see what I meant was, I copied the same config file from a different site, but that config file was copied over directly from the Arch page that I linked to in my first post, and that you just linked to in your most recent post. However, what caused the issue I believe, is that on this site they had number lines for each line of code. It was in a layout sortof like pastebin with the number line, and then the text.
In my hastiness, I just copied everything over, including the number lines which are not actually part of the config file lol. And when I was reviewing the errors I was getting back, I didn't even think about the number lines at all. I wasn't really paying attention.
So anyways, I haven't had time to test it out yet, but I'm almost 100% sure that is the problem, considering all of those numbers weren't even commented out. The shell was reading those numbers and was probably freaking out lol. It just gave me an error for essentially every line; and that right there should have been the first dead giveaway lol, 130 "command not founds".
Last edited by kevinae91 (2013-09-25 21:52:02)
Just keep it simple.
Offline
I get it, but instead of figuring out how to get rid of these numbers, you can simply start anew - if you haven't made any modifications, just copy the contents of the file again, this time w/o the line numbers.
Offline
Alright, I deleted the old bash file and the old dir_color file, and replaced them both with the templates from the Arch Wiki page, and now I get these errors here:
-bash: $'\r' : command not found
.
.
.
: invalid shell option name
.
.
.
-bash: /etc/bash.bashrc: line 26: syntax error near unexpected token `$'in\r''
'bash: /etc/bash.bashrc: line 26: `case ${TERM} inAnd now I honestly have no idea what's wrong with it. I don't even have a typical console format anymore either... my prompt now looks like this, and I have lost some various programs/functions/controls of the system:
-bash-4.2#Pretty sure I done broke something this time.. ![]()
Just keep it simple.
Offline
Why are you working on /etc/bash.bashrc? You should be using ~/.bashrc. And don't edit those files on a Windows box, it will break them.
Offline
Okay, it makes sense now, thanks for that clarification and I will try what you said, but just as an FYI, the Wiki page, under "Installation", says to remove the ~/.bashrc file and then modify /etc/bash.bash.rc with the one provided below.
I was just following what it said...
Just keep it simple.
Offline
FYI, the Wiki page, under "Installation", says to remove the ~/.bashrc file and then modify /etc/bash.bash.rc with the one provided below.
Can you provide a link please?
#edit: nevermind, I found it: and am changing it.
Offline
Glad you found it.
So anyways, what you said did the trick. No errors anymore, which is quite awesome!
Now I just need to figure out why nothing has changed after I reboot the system with the new ~/.bashrc file... ![]()
Just keep it simple.
Offline
Yeah, modifying and then deleting and then adding a new bashrc file and doing it multiple times whilst trying to figure out what was wrong, really did a number on my system. I did a new bash install from pacman but things are still pretty out of whack and now something weird happened with my wireless as well.
Just going to do a fresh install and then go no where near /etc/bash.bashrc haha. Eh, you live and you learn. No big deal.
Just keep it simple.
Offline