| 2:52 pm on Mar 21, 2006 (gmt 0)|
|What's in your Unix bag of tricks? |
As much as I can fit, but for starters...
It might not be as easy as other FTP clients, but it never crashes, it's free, and it's on every Mac OS X machine.
I've found that as a Mac webmaster, the more Unix I know the better.
| 3:25 pm on Mar 21, 2006 (gmt 0)|
ssh firstname.lastname@example.org -p
Changing my ssh port has helped fight spammers/hackers/DOS etc.
Definetly the fastest/easiest way to edit any file.
| 3:42 pm on Mar 21, 2006 (gmt 0)|
When installing downloadable software on a remote server (or even locally...):
curl -o filename.ext http://example.com/path/to/filename.ext
Forget this 'download-to-workstation-and-upload-to-server' nonsense!
| 6:41 pm on Mar 21, 2006 (gmt 0)|
scp /file/on/local/machine /location/on/remote/machine
secure copy is great when I need to move a few files and I know exactly where they are going.
| 8:34 pm on Mar 21, 2006 (gmt 0)|
Here's a fun one. When you're out of town and missing that special someone, paste this into the Terminal (all on one line):
|say -v Agnes "For Pete's sake, are you reading that web master world again? Oh for crying out loud, make yourself useful for once and take out that fricken trash it stinks." |
| 8:37 pm on Mar 21, 2006 (gmt 0)|
| 9:15 pm on Mar 21, 2006 (gmt 0)|
grep -rl "string I want to find" *
| 11:45 pm on Mar 21, 2006 (gmt 0)|
whereis php (and for other binaries)
| 12:18 am on Mar 22, 2006 (gmt 0)|
Those were in my console history :)
Oh, my fav is:
I'm a Linux man, but it's the same right?
| 6:23 pm on Mar 23, 2006 (gmt 0)|
Just encountered this: Have a 25+MB file that's a long list, and I needed to strip out the duplicates.
sort original_filemane ¦ uniq > new_filename
uniq only finds duplicates on adjacent lines, hence the need to sort first.
| 10:44 pm on Mar 23, 2006 (gmt 0)|
|I'm a Linux man, but it's the same right? |
"Similar but different" would be a better description. AFAIK OS X adopted FreeBSD's userland utilities, so some things are subtly not quite the same (netstat is the only thing that comes to mind right now though).
(Linux on the desktop and webservers, OpenBSD on the firewall and OS X on the laptop = recipe for command-line confusion ;-).
| 6:47 am on Mar 27, 2006 (gmt 0)|
top -o vsize
| 5:05 am on Mar 30, 2006 (gmt 0)|
Heres my list I could not live with out!
Wanna watch whos at your site in real time?
tail -f /var/log/httpd/access_log
wanna see your errors in real time?
tail -f /var/log/httpd/error_log
Having trouble with your mysql tables?
mysqlcheck -u root -p --all-databases --analyze --optimize
Im making a site right now about commands and such related to os x server commands if your interested in the site message me and ill give you the address.