Another really useful linux command is test, which can be used to test if a file exists and then rename it.
Here’s an example:
$ test -f test.txt && mv test.txt test.txt.`date +%Y%m%d-%H%M%S`
This first tests if the file test.txt exists. If it does, it renames the file test.txt.YYYMMDD-HHMMSS (appropriate date/time stamp). Great for scripts that are working with a log file and need to rename it before starting a new log.
An interesting commentary on how I use my iPhone. I’ve actually removed the “Phone” and “Message” apps form the 4 app iPhone launch bar at the bottom of the screen, and replaced them with the Gmail and Wunderlist. Turns out, I actually don’t use the “Phone” or “Message” apps as much as these so, why have them there? Obviously Safari remains, so you can see how my iPhone is less of a “phone” and more of a personal information device.
Note for the observant, I’ll let you guess what the 4th app might be (it is a system app – i.e. not downloaded and it’s not Music or App Store).
Interestingly, even in this day in age, I still occasionally have the the need to generate fancy ASCII text. For example, for README.TXT files for source code. This is a fun tool to do this. Note in the font options, find _all fonts with your text_ so you can pick the best font for your text.
If you are looking for software, a great site to start is at Alternative To. There are a few ways to go about searching on the site. One way, if you already know of a similar product is to search for it, then look at the alternative matches (which you can then filter by license and platform).
The other option if you don’t have anything in mind is to simply browse by platform and license across all software. You can use the most likes/views to see what’s being used.
As you may know, most Telco’s have additional charges for mobile data usage. Some of these Telcos (yes I’m looking at you Telstra), have decided that the web page to tell you how much data you’ve used doesn’t have to be all that accurate. Sure it’s a couple days behind but that never hurt anyone …
I’m sorry, but if you filled up at a fuel station where the bowser kinda “guessed” how much fuel you put in your car, and you only found out you were $10 over when you went to pay, you’d be royally pissed right?
Sure, the Telcos will argue about the difficultly of keeping data usage information up to the minute. That’s fine, but if they truly can’t measure data usage that accurately (funny the accounting department doesn’t have any trouble), then how about giving us all some grace –
Dear Sir/Madam, we aren’t really sure how much data you’ve used, and you only went over in the last few days of the quota period so we won’t charge you for it.
Of course, its clear why they do this. It is very difficult to use 100% of your quota without going over. That way they save on bandwidth for every single customer, while still getting full payment based on 100% usage. Very sneaky.
Turns out that you can apply virtual host changes in Apache config (httpd.conf) with a graceful apache restart, rather than a full restart which forcibly kicks (which means kicking users off your web server).
Here’s how to do a graceful change:
Change the httpd.conf file accordingly
Check your config with sudo service httpd configtest (make sure you get syntax OK)
Issue sudo service httpd graceful (most Linux variants)
Note quite a few other Apache changes take effect with a graceful restart. Well worth trying this first, before resorting to a full restart.