Apple Switches tcsh for bash
gklinger writes "AppleInsider is reporting that Apple has switched from tcsh to bash in the the latest developer build (7B44) of Mac OS X 10.3 (Panther). There is speculation that the switch was made to appeal to Linux users. Experienced users get pretty religious about their shells so what remains to be seen is how diehard tcsh users will react." I don't know about appealing to Linux users in particular, but I just don't know many people who prefers tcsh these days, on any platform. It seems like everyone is using bash or zsh.
Has been the default shell.
Now if they'd only put a real fucking terminal emulator in there -- I never thought something (other than the Windows console) would actually make me long for basic xterm. For a lot of *nix users, the web browser is about the only thing you don't use the shell for, and the default Mac terminal environment is pretty painful.
Clean up the shell, tell me I've got the option to do all the Apple updates from the command line, and get emacs in the default install. Then Mac OS will finally feel like a real UNIX.
Fact: *csh is dying
also does "ogg vorbis" i predict still more complaining....
Needless to say, pdksh is available for OS X too but you need to download and install it.
It's great. Does exactly what I want out of a shell.
You are not alone. This is not normal. None of this is normal.
This move fits with Apple's focus on usability. To be usable, you have to be pronounceable, and you have to be memorable.
bash: nice, violent, memorable name
tcsh: the city in Belorussia?
Its a no-brainer, really.
I for one welcome our new bourne again overlords.
I was a big fan of tcsh until I started doing serious shell scripting in
a heterogeneous environment. Since tcsh wasn't available on all machines, all
shell scripts were written for the bourne shell. After several months of
using bourne shell syntax for scripts but using tcsh shell syntax on the
command line, I finally decided that in order to preserve my sanity, I'd try
bash on the command line. Turns out that after a day or so to get used to
things, bash had everything I used tcsh for plus a couple of features that
I'd never known would be so useful.
I don't like running scripts under bash because it's so big, but as an
environment, it's pretty decent.
*sigh* back to work...
With their penchant for user friendliness, I'm surprised they didn't choose mudsh
If I seem short sighted, it is because I stand on the shoulders of midgets
Am I missing something here?
Surely the aforementioned experienced users would know how to switch shells?
just install whatever shell they wanted to use anyway? Im sure anyone that has shell scripting in mind also knows how to install their own shell the correctly right?
Chaos is Divine *
I was used to bash as well, and still use it as my default on my work accounts. However, I allowed myself to get used to tcsh, AND Apple's configurations for it (eventually disabled by default in 10.2, I think). Once I got used to how they configured tcsh, I was rather content to use it. When they removed the configurations that made tcsh behave as it did in earlier versions of OS X, I was annoyed, and immediate found out how to turn those back on.
So, as long as they offer an option with some nice configurations with bash, then I'm all for it. And I DON'T want to have to configure it myself. I simply don't have the time or patience. IF tcsh actually goes away, they better port the enhancements to bash... that's all I gotta say.
-Alex
I'm pretty sure the default shell that opens in Terminal can be changed. But I don't know how it's done. Does anybody?
I know Apple is just a desktop OS, but remember that it's a powerful platform usable for literate users and not just for mom and grandpa -- myself including. I'm glad that they finally realized that. I have only one questions: was it only recently that they read Tom Christiansen's great article about csh-like shells? Seriously, it was published in 1996. Heaven't they read it before? Haven't they known about those issues which Tom points out before? I know Apple doesn't have a strong Unix background (hell, Apple doesn't even have a CLI background), still I find it somehow strange. Great news though.
If you're writing non-trivial scripts, you would do far better to use a decent scripting language like Ruby, Perl or Python, all of which are more portable than bash, not to mention more robust and less likely to result in scripts filled with security holes.
The bash shell is really the tool of choice for people who can only deal with one tool. For interactive use, tcsh is better, and for scripting almost anything is better.
Basically, bash tries to be jack-of-all-trades, with all that that implies. But to FSF folks, who use emacs, "jack of all trades" is a way of life.
GCHQ Quantum Insert installed. If only our tongues were made of glass, how much more careful we would be when we speak
count me in for long-time tcsh users.
It's not that I'm die-hard fanatic over it, but when I started using Unix there was only tcsh as a comfort shell, no bash. And why switch when tcsh works well.
- Hubert
tcsh works perfectly well as an interactive shell. It has some severe problems when it comes to scripting, so I do my scripting in portable bourne shell.. but tcsh is perfectly functional as an interactive shell. I use it under linux, solaris, aix, hpux, and cygwin without issue.
That said, I'm not surprised that apple change to a bourne-compatible shell. Bourne has been the unix standard for a long time, so changing to this makes sense. It means that all of the unix examples out there will work out of the box and not have to be translated into csh syntax. This is probably a good thing. People can still exec tcsh if they like.
-molo
Using your sig line to advertise for friends is lame.
... that shell that had media properties?
... seems to me that a shell like that would be nice to have under OSX ...
I seem to recall - circa 1995'ish, I guess - that there was a shell around which could do embedded media - so you could say 'cat something.jpg' and it would display the jpeg to the screen, in the scroll buffer, just like it were an inline image.
Anyone remember that shell project? I've searched freshmeat but I can't find it
; -- the corruption of government starts with its secrets. a truly free people keep no secrets. --
Tom Christiansen's article is explaining why csh shouldn't be used for PROGRAMMING.
Nobody's suggesting that tsch be used for programming. Least of all Apple, who don't provide any kind of development documentation for it beyond the man page. Scripting on the Mac is best done in AppleScript. Scripting on UNIX is best done with Python, Perl or Ruby.
You can run any shell's scripts from your choice of shell, and anyone writing shell scripts more than a couple of dozen lines long ought to be taken out and shot anyway, so there's absolutely no reason to pick your interactive shell based on its scripting capabilities. That's like picking your web browser based on how well it does "display source of page".
Fact is, tcsh is a better interactive shell than bash for newbies, thanks to intelligent command completion. (No, I don't mean the "complete the program name" stuff bash has, I mean the way tcsh knows about common arguments and options of the most-used programs, and can fill those in for you as well.)
GCHQ Quantum Insert installed. If only our tongues were made of glass, how much more careful we would be when we speak
Yes, a version of it is.
[ravensroost:~] raven% bash
bash-2.05a$
Integrate Keynote and LaTeX
Emacs is a 'basic' tool? You deserve +5 funny for that one.
Anyway, Apple has enough problems with OS X being RAM-hungry, without enticing people to fill 80MB with a text editor.
I'm glad they don't install emacs. I'd be even happier if they removed sendmail as well.
GCHQ Quantum Insert installed. If only our tongues were made of glass, how much more careful we would be when we speak
I don't know much about shells, but there are a number of unique commands in the os x command line environment. One of them is "open", which works exactly like double clicking the icon in the finder - the file opens with the default os x application. I'm not sure why you would want to display media (particularly interactive media, which is everything besides plain images) directly in a command line environment, except maybe if you were lacking a GUI entirely.
---If you can't trust a nerd, who can you trust?
What's so great about bash and/or zsh? Now that I've gotten used to tcsh I'm not sure why it should change. They all seem pretty much the same to me, except the do the same things in slightly different ways.
If you ask me, the default shell should be whichever one with a history that loads the fastest. Many os x users only use terminal.app for the occasional foray into command-line-only commands (like me). Waiting for your shell to load are precious seconds wasted.
---If you can't trust a nerd, who can you trust?
tcsh is a tad easier to work with. yes its less powerful but most of the time i dont need the power and would gladly trade for the simpler syntax and even more gladly trade uniformity for customization.
it seem to me that making the default shell tcsh and letting power users change it to bash if they want might bave been a better alternative. also considering that all my scripts will now break under the defaults its not so good for me.
Some drink at the fountain of knowledge. Others just gargle.
For a moment there, I thought the headline read: Apple Switches THC for hash...
But I like working in tcsh!
This is a wonderful feature, especially when working on a case-preserving-yet-insensitive filesystem like HFS+.
This one doesn't always save me -- one of my common typos is to repeat the 'd' when changing directory, thus:
But it's enough of a win that I wouldn't want to go back to an interactive shell that doesn't have such a feature.
Whenever I'm trying to do anything complex, I tend to drop into a bash subshell, but for 90% of interactive work I find that tcsh can do about everything bash can, and has a lot of interesting enhancements that AFAIK bash doesn't. Please feel free to correct me if that's not true, and bash can now do such things.
(Also, another nice thing about being comfortable in an alternative shell, aside from being able to work productively when dropped on a machine that maybe doesn't have a wide variety of shells, is the built in security factor. It has been long observed that using an unusual keyboard or pointing device is an excellent (if mild) way to discourage people from messing around with your computer when you're away from your desk. Using an unusual command shell can have the same mild deterrance effect: it may not keep your Linux-loving neighbor from messing around in a login session you forgot to close, but it might annoy him enough to get it to get bored & go away pretty quickly :-)
DO NOT LEAVE IT IS NOT REAL
The shell seems pretty clean to me, especially compared to certain linux distros I've tried, but I suppose that's pretty subjective.
/usr/bin/emacs.
You can do all the apple software updates from the command line, the command is softwareupdate.
And emacs is in the default install in
If you'd care to provide some details on why you feel the shell is unclean, I'd be happy to debunk them (assuming they're as mis-informed as the rest of your FUD).
In the mean time, if you don't like the Terminal.app, then use another terminal. IIRC the plain old xterm you said you long for is included with Panther, and included with the various X11 packages available online for older versions of OSX. And there are other more full featured mac alternatives like glterm too.
"The worst tyrannies were the ones where a governance required its own logic on every embedded node." - Vernor Vinge
bash-2.04$ chsh
emacs isn't in the default install. It's in the Developer Tools. Please double-check your facts before you tell somebody they are wrong.
If you think the terminal emulator is okay, you haven't tried using other languages or a tabbed terminal emulator before. Both are being improved in the next release however.
Please stop posturing or trying to scare away potential Mac users (I'm not sure which you're doing). We Mac users are above that, so educate them instead. It helps all of us.
-- Mac user for 18 years, and it keeps getting better --
I imagine it will go something along the lines of...
user@mac:~$ tcsh
mac:~>
This is just how it will ship. Open it the first time, Preferences menu, default shell /bin/tcsh and you are back where you were before.
Prevent email address forgery. Publish SPF records for y
This is a mild gripe, but I'd like to see a version of "ps" that follows the Linux conventions for arguments. I work with three *nix operating systems: OS X, Linux, and HP-UX. The arguments are mostly the same between Linux and HP-UX, e.g. "ps -ef" for a listing of all processes. I invariably try typing that same command in OS X, only to remember, after being told that the arguments are invalid, that the equivalent command is "ps -ax". Annoying!
If you ssh into your box or use screen, it will go back to the default shell. To make change your default shell you need to edit your user in Netinfo.
Is it possible to use any shell in Mac OS X. I have never done it, but I have always read that in Linux, you can choose to use any shell you wish. Would it be that difficult to do in Mac OSX? (I am a Mac newbie, got my first G4 two months ago and am still getting acclimated.)
This isn't well known, and for those who aren't hopelessly devoted to their shell, it's a good reason to use tcsh on Mac OS X. Fred Sanchez maintains a nice set of tcsh configuration files that are installed, but not loaded, by default. For more information, see the file located at:
/usr/share/tcsh/examples/README
If you're a new tcsh user, setting this up is as simple as echoing a few files into your home directory. If you've already got a tcsh configuration, it shouldn't be too hard to shift things around. When all is done, you'll have a great set of default command completions and aliases, and a cool way to organize your customizations.
I'm a dyed-in-the-wool tcsh user. I hate bash. I bash bash.
I could care less what Apple does with the shell. Any Mac developer worth his or her salt can keep tcsh as their shell.
Apple can have my tcsh when they pry it from my cold, crinkled, 90-year-old arthritic hands.
Only two things are infinite, the universe and human stupidity, and I'm not sure about the former. (Einstein)
I followed the link provided, and found the section titled "Unix-lover Heaven" rather funny. It said, "Panther will include a final X11 window server for Unix-based apps, improved NFS/UFS, FreeBSD 5 innovations as well as support for popular Linux APIs, IPv6 and other important acronyms." I'm guessing the marketing folks wrote that last bit...
In the Terminal Preferences window (Terminal -> Preferences) You will clearly see the option to change the command shell (This is with Jaguar 10.2.6):
Execute this command (specify complete path
The default is "/bin/tcsh"
An Apple a day keeps the BSoD away
I only came here to do two things; kick some ass, and drink some beer...looks like we're almost out of beer.
emacs : in the default install of OS X.
Terminal : rocks. I use it constantly.
xterm : install apple's X11 package, how hard is that?!? Oh, and it'll be in the default install of the next version.
you can do apple updates from the command line.
How is this funny and not a troll?
I'm proud of my Northern Tibetian Heritage
yes! YES!!!! i have this exact same problem but ONLY on the apple pro keyboard. i have, alas, also resigned to aliasing "cdd".
I know about the 'open' ability from OSX Terminal, and all that.
... and since I spend most of my life in the Terminal windows, it'd be useful to me, also, actually.
This was just an interesting shell - curiousity more than anything else. It was fully 'media enabled', which means it was able to function as if it were a regular web browser, image viewer, movie player - but the bounding rect for the media was always within the 'Terminal window', if you understand what I mean, and it functions just like a normal shell - with scrollback buffer, etc.
It was pretty cool, actually, to have media interspersed with regular text commands - a 'cat *.jpg' in some dir full of images would give you thumbnails output, etc.
I've really got to chase it down and have another look. It seems to me that in the world of Aqua and Quartz, it would work quite well
; -- the corruption of government starts with its secrets. a truly free people keep no secrets. --
...to the term mac bash-ing.
...or bourne again mac user.
bash is GPL and zsh is Berkeley, Apple seemed to be afraid of GPL at the beginning and has taken a more practical stance more recently...
OS X ships with four shells, but in reality there are only two. bash and sh, what should be the Bourne shell, are identical; tsch and csh are too. FWIW.
I don't have the developer tools, but I do have emacs installed, ergo you are wrong.
I try to keep shells out of my mac, they can make a real GUI mess.
I apologise for being a Unix n00b, (but a long time Mac user). However, I have never understood the difference between the different shells.
Are the commands different? The display style? What changes between bash, tsch, and all the others?
"Reality is merely an illusion, albeit a very persistent one " -Albert Einstein
I like the idea though, and I'm a bit saddened by the fact that no-one's doing much to advance the state of the CLI. I think there's plenty to be done, and not just with CLI/GUI fusion.
Fuck the system? Nah, you might catch something.
dangit and i was actually looking forward to paying for multiple copies of panther; then they pull this crap, of well, guess they don't want my money anymore.
You can just update your account to use whatever shell you want anyway. I see both bash and tcsh on my MacOS X 10.2 install, so there should be no trouble for someone who cares enough to change shells.
It is a moot point.
Brennan Stehling - http://brennan.offwhite.net/blog/
I'm running 10.2.6 with bash 2.05a. I put 'set completion-ignore-case on' in my .inputrc and started a new bash shell. From my home dir, I did:
.profile, .bash_profile, or .bashrc that might be conflicting.
cd Code/p<tab>
bash completed this (correctly) to:
cd Code/Perl
Soooo, works great for me, as advertised. Perhaps double-check your set command (I accidentally used 'completion-case-ignore' at first), and double check anything you have in
Perl - $Just @when->$you ${thought} s/yn/tax/ &couldn\'t %get $worse;
Now the mac basher will come out in force.
Jesus was a compassionate social conservative who called individuals to sin no more.
So yes, this is a fairly big deal. It also makes OSX how-tos easier to follow (many had tcsh-specific command-line instructions).
Si la vida me da palo, yo la voy a soportar Si la vida me da palo, yo la voy a espabilar
I just changed my default shell. who cares? I use bash. I always have and I always will. I've never once used tcsh in my year of having an OS-X machine.
If people are too ignorant to change their shell themselves, then they've peobably never even use a CLI.
Why don't they tell us about the real exciting stuff with 10.3?
The reason girls and Windows users don't understand UNIX is because all the documentation is in Man files.
I had the same problem (with ps but mostly with other commands). I download fink and I felt so much better... ;)
Within a few moments and quick commands, I had all the GNU tools installed and my $PATH changed to point to them first. Now, whenever I have serious work to do on a Unix system, I install them (if it makes sense for me to take the time and freedom to do so). Even on Windows cygwin allows you to use the tools you are used to (with all the same parameters, options, etc.) if they are needed. For that I thank the GNU project!
Perhaps if they bundled a working copy of Windows in it would be nice. Of course that has nto been invented yet though.
I'll have to assume that I can chsh or Netinfo my way to choose the shell that I want? Yeah -- I personally go towards tcsh each and everytime. I really don't know _why_ (anymore :) other that I know all the shortcuts, Bash can do all the same bells & whistles (AT&T Sys V "sh" certainly could NOT and that's when I switched to tcsh :).
./configure it, and make it. Wait. I just downloaded the 805K source (less than 1 MEG my friends :) and tried it. What's the issue?
:) -- I still do _all_ batch routines in "sh" (bash on OS X already today). They're just changing the default user shell -- which the typical type user probably won't see, notice, or care. Those that do probably know how to "fix" it too...
/bin/sh (pretty much bash anywhere you go today). Apple's system level geeks probably are bash gurus (they should have to be) -- so why not? Why is root always /bin/sh? For compatibility or for no damn reason. It's the way it is... :)
:)
Not included? Not a problem. Get it,
This _is_ just Unix after all. For _whatever_ reason (way back in the day it was for compatibility as tcsh was rare
Care to guess what my "root" shell always has been?
This from a tcsh person: so? It's not like I'm a user on Apple's mainframe and I'm not allowed to chsh myself. I've enabled "root" on each and everyone one of my Mac's for various reaons -- and can sure change a shell if I need to. Those that don't know how won't care and those that care probably know how...those that don't know how but think they care? Well -- they should probably be using Windows then.
Well, it looks like apple is moving up (even though I still like my old tcsh shell and don't want to have to learn a bunch of new commands), but any user of microsoft's UNIX tools (probably none of you) will know that Microsoft provides you with the Korn shell to use.
We don't need no stinking Leenux shell!
-- unix is for people without a social life - Patrick van Eijk
I've been using zsh since yesterday and i like it. The autocomplete features are much nicer than tcsh. I can actually write little scripts now with little trouble thanks to functions. For the record, autolist and automenu seem to already be enabled on my os x install. You were right about specifying /bin/zsh in the terminal prefs speeding up load time considerably.
Guess I gotta study bash too if that will be the os x default. I know linux is the one driving shell choices now, but I reckon mac users will choose the more user advanced and user friendly choice over the more widespread choice any day.
---If you can't trust a nerd, who can you trust?
Who moderated this as offtopic? It's certainly on-topic and insightful at that.
Want to improve your Karma? Instead of "Post Anonymously", try the "Post Humously" option.
This is not NEWS. A simple google search will bring up news relating to the "switch" way back in the days of 7B21 (aka the Developers Preview).
The shell crash may not be an upgrade issue. A reinstall cured it for me. The second time, I didn't install developer's package and used Apple's X11 and it's still going strong. Or it could have been Fink's way of doing things. I didn't think it had happened to anybody else.
Too bad you got the anal retentive support department. There is a lot of that going around.
Any preoccupation with ideas of what is right or wrong in conduct shows an arrested intellectual development. (Wilde)
To clarify something else, I didn't think using bash instead of tcsh should break anything, but Apple's help line wouldn't help me because I had used bash. Whether that was the problem or not, they were unwilling (or unable) to help me fix my system once they heard I had changed some Darwin-level settings. Bah. What good is a help line if they can't actually help you?
I guess a reinstall might be in order, but it seems a bit drastic . . . I'd rather pinpoint and fix the specific problems.
As another side note--anyone see flickering screens (this on my laptop's LCD) after moving to jaguar? I'm guessing it's poorly-implemented quartz-extreme, b/c it usually happens on graphics-intensive programs.
Si la vida me da palo, yo la voy a soportar Si la vida me da palo, yo la voy a espabilar
Sigh... Now I must change all of my scripts...
Still, I think bash is a better default.
RateVegas.com - Vegas Reviews