In addition, there are some other great UNIX tips on that page, including a "renice" command for the Window Manager that may potentially speed up your window redraw. I've added the site to the links section as well.
I have managed to compile on Mac OS X final the "vim" editor from www.vim.org - version 5.7, but syntax highlighting is working WITHOUT COLORS - syntax elements are highlighted only by "underline" attribute, not by colors. Does anybody know:
a. how to activate colors in vim in Mac OS X?
b. how to run vim as gvim, i.e. in graphical mode?
[Editor's note: See the comments for a good discussion and solution to this question]
I just managed to get bash compiled and running but I have a problem whenever I switch the shell in Terminal.app's preferences.
If I set it to bash, zsh or anything besides tcsh, it seems that I can only use commands from /bin. I mean, I'm missing basic stuff like ping and traceroute. I can su root and copy commands from /sbin or /usr/bin, but this doesn't seem like the right way to go about using my spiffy new shell.
Oddly enough, I can start Terminal with tcsh and then temporarily switch to bash, and everything works perfectly. Tried using chsh, but it launches vi, and vi and I are not on speaking terms.
Need help from someone who knows what the heck I'm doing wrong.
I've purchased and installed Mac OS X on my Blue & White G3. Now I'm looking for ssh. Is it missing from this release? It was present in the Public Beta and I need secure telnet to be able to work from home.
Typing 'ssh' in a terminal session results in the shell trying to resolve my unknown command to 'sh' instead.
I have installed everything available on both the Mac OS X Installation CD and the Developer Tools CD. Any help would be greatly appreciated.
Steven M. Fish
[Editor's Note: See the comments for a couple of methods for installing SSH. The URL for the Stepwise how-to is:
[Editor's note: See the comments for a walk-through on how to successfully move your 'Users' folder to another hard drive.]
I'm interested in relocating my Users directory to seperate partition on my hard drive, to make sure there's plenty of room for all my users files. Knowing that Unix requires certain folders/files to be in certain locations, is this possible? If so, what other files/prefs will I have to change in order to make sure the system understands this? (BTW, I'm a total unix newbie, but very keen to learn!)
Strong Warning: You should only enable root if you really really need it, really know what it's for, and realize the security implications of enabling root! You can do everything you need to do with "su do", so root is really not needed ... with that said, here's how to enable it - please understand what you're doing and why before you do this!
The "root" user (also known as the superuser) is the most powerful UNIX account. The root account can do anything to any file or folder, anywhere on the system. For that reason, it's considered quite dangerous, and only needs to be used (occasionally) by advanced users.
Because of the dangers of operating as root, Apple has chosen to hide the root account in OS X Final. However, there are a number of ways to enable it. The easiest is to boot off the install CD, and look under the Install menu for the "Password Reset" option. You can use this to change your own password if you forget it, and to enable the root account. This utility will not run if you copy it to your hard drive! It only works when booting from the CD.
Read the rest if you'd like to know how to do this from within OS X, and skip the CD-based reboot.
[Editor's note: See the comments for the answer to the question.]
Does anybody know how to quit a GUI program through a telnet session? I can open GUI programs through telnet but can't figure out how to then quit that same program. PS won't show GUI programs so I can't KlLL them. Any help is appreciated.
The UNIX environment has two common commands for looking at disk usage - 'df' and 'du'. 'df' returns information about all mounted disks, and 'du' returns information about a given file or set of files. As installed in OS X, though, the 'df' and 'du' commands do not return easy to use information. For example, here's the 'df' output for one drive on my system:
Filesystem 1k-blocks Used Available Use% Mounted on /dev/disk0s9 3121344 1314624 1806720 42% /osxfiles
Wouldn't it be much nicer if you could have it output like this:
Filesystem Size Used Avail Use% Mounted on /dev/disk0s9 3.0G 1.3G 1.7G 42% /osxfiles
Read the rest of this article if you'd like to learn how to create a more usable "df" (and other!) commands.
NOTE: I have packaged four of the more useful of these utilities (ls, dircolors (sets the colors for the new ls), df, and du) into one downloadable archive. These are pre-compiled, and you'll just need to expand the archive with OpenUp or the command line (or the new StuffIt Expander). Move the files into /usr/localbin, and they should be ready to go. I have NOT included the 'man' pages, since I wasn't sure how to do that - read the GNU online help for info on each command, or compile the whole package.
Last night, as I began experimenting with possible successors to geeklog, one package (phpnuke) had an instruction step that read:
"Set all files to 666 permission; set all directories to 777." Although this is relatively trivial for multiple identical items (chmod 777 *), it's a bit trickier when files and directories are mixed in the structure, with sub-directories and sub-files, and different settings for directories and files. The phpnuke package installs literally hundreds of files, and probably 25-50 subdirectories. I was reduced to mass changing everything in a folder (chmod 666 *), and then setting the directories by hand. It took a while!
I was sure there was an easier way, but had no idea what that way might be. A post to the MacNN forums provided the answer, courtesy of "Icampbell":
find . -type f | xargs chmod 666 find . -type d | xargs chmod 777
This does exactly what I needed it to do. 'xargs' is an interesting command, and well worth reading up on ('man xargs'). It basically executes the command specified (chmod in this case) for each item passed to it (the results of the 'find' command, routed via the pipe '|' symbol). It's fairly easy to see how powerful xargs can be, given its ability to act on a series of things passed to it. One note of caution in this example - the 'find' command will search down through the directory structure from where you start, so make sure you want to effect EVERYTHING in that path if you try something along these lines!