hamza
Posts: 76
Joined: Fri Apr 03, 2015 7:16 pm

bashrc: shopt:

Tue Apr 28, 2015 10:30 pm

hi

I have the following errors :

/home/pi/.bashrc: 13: /home/pi/.bashrc: shopt: not found
/home/pi/.bashrc: 21: /home/pi/.bashrc: shopt: not found
/home/pi/.bashrc: 55: /home/pi/.bashrc: Syntax error: Bad fd number

what is the meaning of this error and how to fix it??

User avatar
DougieLawson
Posts: 38883
Joined: Sun Jun 16, 2013 11:19 pm
Location: A small cave in deepest darkest Basingstoke, UK
Contact: Website Twitter

Re: bashrc: shopt:

Wed Apr 29, 2015 12:12 am

shopt is a built-in command in /bin/bash. It's missing from /bin/sh. Are you trying to run your .bashrc with the wrong shell?
Note: Any requirement to use a crystal ball or mind reading will result in me ignoring your question.

Criticising any questions is banned on this forum.

Any DMs sent on Twitter will be answered next month.
All non-medical doctors are on my foes list.

hamza
Posts: 76
Joined: Fri Apr 03, 2015 7:16 pm

Re: bashrc: shopt:

Wed Apr 29, 2015 2:09 pm

I find out this problem when I was trying to make autostart video with rpi2 , but the autostart is not working because i have these errors.

also I made bashsc restore but still same problem.

how can I solve that??
thanx for your support.

User avatar
PeterO
Posts: 5829
Joined: Sun Jul 22, 2012 4:14 pm

Re: bashrc: shopt:

Wed Apr 29, 2015 2:16 pm

hamza wrote:hi
I have the following errors :
/home/pi/.bashrc: 13: /home/pi/.bashrc: shopt: not found
/home/pi/.bashrc: 21: /home/pi/.bashrc: shopt: not found
/home/pi/.bashrc: 55: /home/pi/.bashrc: Syntax error: Bad fd number
what is the meaning of this error and how to fix it??
My crystal ball is broken so you'll have to post your script here.....

PeterO
Discoverer of the PI2 XENON DEATH FLASH!
Interests: C,Python,PIC,Electronics,Ham Radio (G0DZB),1960s British Computers.
"The primary requirement (as we've always seen in your examples) is that the code is readable. " Dougie Lawson

Return to “Beginners”