I worked with a Mac last week for the first time ever. I noticed that the shell is very similar to Linux. I normally develop on a Windows machine and tend to be a noob at all things Linux. Will a Mac help me with this, or will it make things worse for me due to minor differences in Mac's OS?
|
It certainly won't make things worse. There are numerous similarities between OS X and Linux and if you're beginning to dabble with OS X, the minor differences won't be relevant right now. Things like the bash shell, scripting tools, and many Linux shell applications are all available for OS X. I regularly develop on OS X on my MacBook and run my programs on a Linux workstation. There will be a point where you'll need to learn the differences between Linux and OS X (e.g. how services are managed) but by the time you get to that point, you'll know where to find the information you need. |
|||||
|
|
I would have to say yes, but not completely. And that yes depends on how frequently you use the Mac's command line (Terminal). For various things, I've come to use the command line often and see the similarities between the BSD base of OSX and Linux. So much so that I've also come to refer to Macs as "linux done right" (please don't flame, I have good reasons! (for me)), speaking from a power/ease-of-use point of view. Sure, there are some big differences between the two (app installation, for example) but on the low level, you can get a good, basic understanding of linux via frequent use of the Mac's Terminal application. Of course, to master linux you will need to use it regularly; and from my personal experience I would guess that mastering linux, like anything else, can take years of use, tinkering and learning. |
|||
|
|
|
Certainly. OS X is a POSIX compliant UNIX based OS built on top of the XNU kernel, that includes many standard Unix tools that can be explored from Terminal.app. Because of the POSIX compliance many programs written for Linux can be recompiled to run on it. The Fink and MacPorts projects can help extend the toolsets you can learn with as well. |
|||||
|
|
I like Macs, and it does give a good (BSD) UNIX experience but strictly on getting a Linux experience on your PC, I feel there are better alternatives. I personally use Cygwin on any Windows machine I own. You download the installer from http://www.cygwin.com/setup.exe The commands are basically the same GNU ones that Linux runs, so scripts should run fairly similar to Linux (the big difference tends to be paths, with spaces in filenames and $HOME directory path much more likely). There are also various utilities to help merge the UNIX/Windows experience, like cygpath, cygstart, etc. You can also try running COLinux. An interesting port of the Linux kernel to run as a Windows process and interact with Windows cleanly. I've never tried it, but it looks promising. http://www.colinux.org/ If you just want to play with it a bit, you can always run from a LiveCD or a USB drive. If you just want to try it, LiveCD is fine, but if you want to do any real work you'd want a USB drive to be able to save and get updates. And there's always dual boot, but that tends to be more difficult setting up on Windows versus Mac Bootcamp. |
|||||||||
|
|
Linux will help you learn Linux. Linux may well help you learn Mac. I'm not sure Mac will help you learn Linux, though. You're correct that there are many similarities between Mac OS X and Linux. This is because they're both based on Unix. There are major differences, however. Mac OS X is set up to be a consumer operating system. This means that all but the most detailed and fiddly tasks have a graphical interface that's nice and easy to use. Linux was originally designed as a hobby project and is now mainly used in servers. For normal desktop users Linux is getting better and better every day, but many more routine tasks simply assume you can use the terminal. Sometimes there isn't a GUI, or it isn't installed by default. Sometimes there is a GUI, but the instructions are out of date and still refer to the terminal, or the author just uses the terminal out of habit. Either way, going from Mac OS X to Linux will still leave you with a learning curve (as there is with any switch of operating system). It also depends on how much you want to learn about the depths of the operating system - if you're doing low level stuff like driver programming, they'll be very different. High-level programming will probably be very similar. That said, there are many things that are the same. You've already noticed the shell - likely |
|||
|
|
cp,top, ...) have different command-line switches, I think because Mac OS X uses the BSD versions. – Daniel Beck♦ Nov 16 '10 at 19:31