Shell hell: Three or four unix shell programs are distributed with Mac OS X. These are tcsh, bash and zsh; ksh joins the family with 10.4.x. Each has its own syntax, but tcsh is fundamentally different from the others. Here are a couple of simple but essential examples of how the syntax differs. I am trying to edit an entry to PATH, as I did something wrong. I am using Mac OS X 10.10.3 But the file editor opens with nothing inside. I am trying to install ANDROIDHOME to my PATH I.
Bash completion for Mac app aliases Nov 2 nd, 2013; Bash and Dash May 10 th, 2014; Making my tmux life easier May 11 th, 2014; up: fuzzy navigation up a directory tree May 14 th, 2014; tmux even easier: tm with fuzzy completion May 15 th, 2014 (Potentially) funny random filenames for Bash scripts Jun 7 th, 2014; Making cd in bash a little. Step 5: Force the.bashprofile to execute. This loads the values immediately without having to reboot. In your Terminal window, run the following command. Source /.bashrc // or source /.bashprofile source /.profile source /etc/profile. Now you know how to edit the PATH on your Mac OS X computer system.
Yes and no.
They both have bash, however, not all commands are the same between OS X and Linux, and when the commands are the same, not all the options are the same. But for the most part command options available on OS X will be a subset of the richer set of options on Linux. There will only be a few commands on Linux that do not accept options available on OS X.
Also OS X's bash is version 3.2.57(1), where as Linux is going to have a bash with a 4.something version. 98% of bash behavior will be the same, but there are going to be a few edge conditions where they may behave differently.
NOTE: Commands are separate from bash. Each is their own program and are not tied to each other in anyway.
I live in an OS X, Linux, Solaris, AIX Unix world, and for the most part I can write scripts on one platform and run them on any of the others. Where I have difficulties, I add code along the lines of
UNAME=$(uname)
if [[ $UNAME = 'Linux' ]]; then
... Linux specific
elif [[ $UNAME = Darwin ]]; then
... OS X specific
elif [[ $UNAME = AIX ]]; then
... AIX specific
else
... generic ...
Mac Os Download
fi
The reason OS X has an older version of bash, and why OS X does not include the Linux commands with all the extra options is that many of those programs have a GPL V3 license that explicitly excludes commercial Unix vendors from including them in their operating system distributions, so the commercial Unix companies are stuck with either GPL V2 licensed code, or code they got from BSD distributions, such as FreeBSD (a lot of OS X command are originally from FreeBSD).
However, if there is an open source command that you really want on your system, you are allowed to install it yourself. I actually build and install my own current version of bash on my OS X systems. The GPL V3 license does not restrict you, only Apple.
There are several package managers that make adding open source commands fairly easy. Homebrew, MacPorts, Fink.
Dec 3, 2015 8:24 PM
Hi smo9988,
It sounds like your computer is not getting past the loading screen so you cannot log in at all. I would try booting to Safe Mode as outlined in the following article:
Follow these steps to start up into safe mode.
- Start or restart your Mac.
- Immediately after you hear the startup sound, press and hold the Shift key.
- Release the Shift key when you see the Apple logo appear on the screen.
After the Apple logo appears, it might take longer than usual to reach the login screen or your desktop. This is because your Mac performs a directory check of your startup disk as part of safe mode.
To leave safe mode, restart your computer without pressing any keys during startup.
If you don't hear a startup chime after pressing the power key, see what to do if your Mac won't turn on.
If your Mac restarts or shuts down in safe mode
Mac Os Versions
If your Mac automatically restarts in safe mode, OS X might have found an issue that it's trying to fix.
Shell hell: Three or four unix shell programs are distributed with Mac OS X. These are tcsh, bash and zsh; ksh joins the family with 10.4.x. Each has its own syntax, but tcsh is fundamentally different from the others. Here are a couple of simple but essential examples of how the syntax differs. I am trying to edit an entry to PATH, as I did something wrong. I am using Mac OS X 10.10.3 But the file editor opens with nothing inside. I am trying to install ANDROIDHOME to my PATH I.
Bash completion for Mac app aliases Nov 2 nd, 2013; Bash and Dash May 10 th, 2014; Making my tmux life easier May 11 th, 2014; up: fuzzy navigation up a directory tree May 14 th, 2014; tmux even easier: tm with fuzzy completion May 15 th, 2014 (Potentially) funny random filenames for Bash scripts Jun 7 th, 2014; Making cd in bash a little. Step 5: Force the.bashprofile to execute. This loads the values immediately without having to reboot. In your Terminal window, run the following command. Source /.bashrc // or source /.bashprofile source /.profile source /etc/profile. Now you know how to edit the PATH on your Mac OS X computer system.
Yes and no.
They both have bash, however, not all commands are the same between OS X and Linux, and when the commands are the same, not all the options are the same. But for the most part command options available on OS X will be a subset of the richer set of options on Linux. There will only be a few commands on Linux that do not accept options available on OS X.
Also OS X's bash is version 3.2.57(1), where as Linux is going to have a bash with a 4.something version. 98% of bash behavior will be the same, but there are going to be a few edge conditions where they may behave differently.
NOTE: Commands are separate from bash. Each is their own program and are not tied to each other in anyway.
I live in an OS X, Linux, Solaris, AIX Unix world, and for the most part I can write scripts on one platform and run them on any of the others. Where I have difficulties, I add code along the lines of
UNAME=$(uname)
if [[ $UNAME = 'Linux' ]]; then
... Linux specific
elif [[ $UNAME = Darwin ]]; then
... OS X specific
elif [[ $UNAME = AIX ]]; then
... AIX specific
else
... generic ...
Mac Os Download
fi
The reason OS X has an older version of bash, and why OS X does not include the Linux commands with all the extra options is that many of those programs have a GPL V3 license that explicitly excludes commercial Unix vendors from including them in their operating system distributions, so the commercial Unix companies are stuck with either GPL V2 licensed code, or code they got from BSD distributions, such as FreeBSD (a lot of OS X command are originally from FreeBSD).
However, if there is an open source command that you really want on your system, you are allowed to install it yourself. I actually build and install my own current version of bash on my OS X systems. The GPL V3 license does not restrict you, only Apple.
There are several package managers that make adding open source commands fairly easy. Homebrew, MacPorts, Fink.
Dec 3, 2015 8:24 PM
Hi smo9988,
It sounds like your computer is not getting past the loading screen so you cannot log in at all. I would try booting to Safe Mode as outlined in the following article:
Follow these steps to start up into safe mode.
- Start or restart your Mac.
- Immediately after you hear the startup sound, press and hold the Shift key.
- Release the Shift key when you see the Apple logo appear on the screen.
After the Apple logo appears, it might take longer than usual to reach the login screen or your desktop. This is because your Mac performs a directory check of your startup disk as part of safe mode.
To leave safe mode, restart your computer without pressing any keys during startup.
If you don't hear a startup chime after pressing the power key, see what to do if your Mac won't turn on.
If your Mac restarts or shuts down in safe mode
Mac Os Versions
If your Mac automatically restarts in safe mode, OS X might have found an issue that it's trying to fix.
Watermelon Bash Mac Os 11
Safe mode performs a directory check of your startup disk, similar to what happens when you choose to verify or repair a disk using Disk Utility. If OS X finds an issue, the directory on your startup disk is repaired and your Mac restarts.
If your Mac turns itself off when you start up in safe mode, check the power connection on your Mac to make sure it's plugged in securely at both your Mac and the power outlet. If you're using a MagSafe power adapter, make sure the LED on your power adapter is yellow or green. Then, try starting up in safe mode again.
If your Mac repeatedly restarts or shuts down during safe mode, contact Apple Support, or consult with an Apple Authorized Service Provider or Apple Genius for more help.
Thank you for using Apple Support Communities, all the best!
Jan 6, 2016 11:43 AM