Obnoxious boot chime in OS X? SILENCE IT!

From the terminal:

sudo nvram SystemAudioVolume=%80

To get the chime back:

sudo nvram -d SystemAudioVolume

If you can’t get OS X to boot properly, and are stuck in reboot hell, get to the terminal via Single User mode.  Hold command+S after you hear the chime, or see the grey screen appear after starting your mac.  Then follow the onscreen instructions to mount your main hard drive partition, which consists of this command:

/sbin/mount -uw /

Happy booting in silent peace!!!!

Geektool (geeklet glet) update for Yahoo weather icons, 2014 edition!

Yahoo France made a small change to their icon source URLs, putting them on secure servers.  My old script command will work, but you need to change the URL to https vs. http:

curl --silent "https://fr.meteo.yahoo.com/united-states/california/aliso-viejo-12796580/" | grep "obs-current-weather" | sed "s/.*background\:url(\'\(.*\)\') .*/\1/" | xargs curl --silent -o /tmp/weather.png

Original post here.

Geektool weather icon unix shell script for September 2013

Well, Yahoo! is going through a (frankly) much needed UI/UX update on all their sites, and that has stranded a few Geek Tool users who rely on Yahoo for awesome .png image weather icons.  Fret not, France to the rescue! (SAY WHAT?)

Yes, Yahoo! France still has our beloved weather icons that we can steal from (but for how long??).  Use the following unix command to grab the weather icon, and save to the /tmp folder.  Modify as you see fit of course:

curl –silent “http://fr.meteo.yahoo.com/united-states/california/aliso-viejo-12796580/” | grep “obs-current-weather” | sed “s/.*background\:url(\’\(.*\)\’) .*/\1/” | xargs curl –silent -o /tmp/weather.png


And in the meantime, if anybody has a new source for great weather icons for the future (for when the French finally surrender to the new Yahoo! UI), drop a comment!  Thanks.

See my updated post for 2014.

A few HTML 5 and CSS 3 tips I wish I knew 72 hours ago.

I’ve been wanting to get back to developing websites, and hence wanted to start getting some design and modern front-end development experience under the belt.  I haven’t done serious front-end work for a while, so I took on a small project for a friend – a place-holder website to have up for his future clients (SL-Capital.com).

I decided to go with a somewhat responsive design, with CSS-driven blur effects, font scaling, etc.  But as I started really testing the site with various devices, browsers, etc., I very quickly came across some weaknesses in my skill set.  Here are some tips and tricks that I learned while making this very small and simple page a little more compatible with the real world:

  • Firefox still can’t do CSS blur, etc. – I had to create an SVG file and point the css to the file in order to get the blur working in Firefox.  And Firefox still renders blur pretty ugly… not much you can do about that.  Here is the code I used to get the blur going in Firefox:Create a file called ‘filter.svg’, place in same directory as your .css stylesheet file (or wherever you keep your css that you want to render the blur with).  Contents of filter.svg:
    <?xml version="1.0" standalone="no"?>
    <svg width="1" height="1" version="1.1"
     <filter id="blur">
     <feGaussianBlur in="SourceGraphic" stdDeviation="2 3" />

    Here is the CSS to reference the above SVG:

    filter: url(filter.svg#blur);

    Don’t forget to make sure your web server/web host is configured to serve up the SVG file to browser clients.  Apache users probably won’t need this, but you’ll need a MIME type enabled for IIS (for example):

    Extension: .SVG
    MIME Type: image/svg+xml

  • IE10 (Internet Explorer 10) no longer supports any kind of filtering (at least until CSS3 is officially ratified).  BUT, if you force IE10 into ‘compatibility mode’ for IE9, you can do filtering via the old DirectX CSS tags.  To have your website force IE10 to support blur, add this tag RIGHT AFTER your <head> tag in your HTML file where you will be using the blur (if it isn’t the first META tag after <head>, it won’t work):
    <meta http-equiv="X-UA-Compatible" content="IE=9" />

    And here is the CSS for getting IE10 (IE9) to render the blur:

  • For Chrome and Safari (both webkit-based browsers) it couldn’t be easier:
    -webkit-filter: blur(5px);
  • As a final tip, I’d like to point out that Media Queries are your friend.  They act as giant IF-statements that help activate (or deactivate) portions of code that meet or don’t meet the criteria specified in the media query.  For example, if you want a specfic section of CSS to be active when the browser window (or mobile/tablet device) is in a landscape orientation (width > height):
    @media all and (orientation:landscape){
    css here

    The media query ensures that the encompassed section of CSS (the CSS code between the {}) is only active if it meets the criteria you specify.  This is very helpful for switching between different sections of a single CSS sheet, without having to resort to Javascript dom hacking, linking to multiple stylesheets, etc.  It is especially helpful in responsive design, because you can often switch the sizing and layout of your text depending on the width of the client window, orientation, etc.  For example, adding some extra criteria for screen height:

    @media all and (orientation:landscape) and (min-height:875px){

    This will trigger the encompassed CSS to only be active when the window/device is in a landscape orientation, with the height of the window being a minimum of 875 pixels high.  When using media queries to direct your active div positioning, sizes, orientation, and even font sizes (for example, switching between vh and vw viewport units), they really become the ultimate responsive design tool.

That about does it for this post.  I hope this helps you out in your CSS3/HTML5 quest for glory.

Restore from a Drobo FS to your mac, over the network, using OS X Lion

I recently had my iMac Hard Drive completely fail. It would boot to the white/grey screen with the Apple logo, put a progress bar underneath, and then just spin that spinning spinner forever, never actually booting. Very scary! Although I am concerned that I might have to replace my HD before my Apple Care runs out, what I wasn’t concerned about was whether I lost any data.  I knew I had a backup, and that it would be easy to restore from this backup!  Or so I thought…

I had been backing up my iMac via Time Machine, over the network, to my Drobo FS Time Machine partition/share that I had previously set up.  So thus, I knew I had my data backed up, but what I didn’t know is what a nightmare it would be to actually do a restore from this network backup.

As it tuns out, it’s actually a pain in the ass, unless you know the secrets to unlocking the mysteries of Time Machine, and the Drobo FS.  Here is what I had to do, I hope this helps somebody someday:


Launch into Lion’s (in my case, OS X 10.7.4) Recovery partition (hold down the option key after turning on your Mac via the power button, then select the Recovery Partition), or alternatively, boot from the OS X Lion USB Stick or DVD, whatever you have access to (for Snow Leopard 10.6.x, this will probably have the same instructions, so this should work for SL as well).

Next, ignore the main menu options that pop up, and instead run Terminal, via the Utilities menu at the top menu bar (very top of screen, near the middle).  In Terminal, you have to do a few steps (use the following Terminal commands as templates, substituting your own data as necessary):

  1. We have to create a volume on the disk drive that OS X’s Recovery/Restore software can ‘see’ (otherwise known as a ‘mount point’):
    mkdir /Volumes/TimeMachine
  2. Then, we have to mount the network share to this newly created volume, so that it appears as a ‘local’ disk to OS X:
    mount -t afp afp://YourDroboFSAdminUserName:YourDroboFSAdminPassword@IPAddressOfDrobo/YourDroboTimeMachineShareName /Volumes/TimeMachine

    Using the above template, my command wound up looking something like this:

    mount -t afp afp://admin:password@ /Volumes/TimeMachine
  3. Finally (and this may be Lion only, so try with and without), we have to mount the actual image of your Time Machine backup to make its contents readable by OS X’s Restore process:
    hdid /Volumes/TimeMachine/yourMacsTimeMachineFile.sparsebundle

    Using the above template, my hdid command looked like:

    hdid /Volumes/TimeMachine/mainImacTimeMachineBackup.sparsebundle

If you don’t know the name of your sparsebundle file (required for Step 3 above), from the same Terminal window, you can just switch into the /Volumes/TimeMachine directory you created (“cd /Volumes/TimeMachine”), and after completing Step 2 above, you can type “ls” to list all the files in that newly mounted directory.  Your sparsbundle file should be there, so make a note of its name for Step 3.

After you complete the above steps, you can quit the Terminal application, and then launch the ‘Restore From Time Machine Backup’ option from the main menu that Lion originally presented to you.  Click ‘continue’, and choose your Time Machine backup (which may take a second or two to show up, but not much longer than that).

From there, you are on the long road to recovery, and you can enjoy watching that ‘Restoring’ progress bar for the next few hours.


eBay’s greatest scam – duping sellers out of fees caused by fake eBay buyers

Let’s say you want to sell an item on eBay… such as that old iPhone 3G that you just replaced by another phone.  You list it on eBay, maybe pick a reserve price (just to be sure it doesn’t sell for pennies on the dollar), and a few days later, viola!  The phone sells.  Great!

But then you realize that the buyer who just bought your item has zero feedback, and created the account less than a month ago.  Red flag.  But let’s be optimistic… surely they created an account because they wanted your old iPhone so badly…  Surely they will pay!

Nope.  They don’t pay.  So you want to re-list your item as quickly as possible to get past all this, yet eBay makes you wait about 4 days before they consider the item ‘unpaid’.  Fine, we wait.

A week rolls around, and finally the item falls into an ‘unpaid’ status, where you can use the ‘unpaid item assistant’ to file a claim on your behalf.  Why do you need to file a claim?  You need to because you now owe eBay the commission on your item that ‘sold’, even though it is now unpaid.

Makes sense?  No, it doesn’t make sense to me either.  This is eBay’s scam #1.  Now, on to scam #2:  This claim won’t be filed until the next month, so you are stuck ‘owing’ eBay money until the next billing cycle.  I can live with that part, but guess what?  They will only refund you the commission and the listing fee… They WILL NOT refund you the reserve auction fee!

That’s right, eBay’s scam #2 is that they do not issue a full refund on unpaid items, because they consider certain options (such as reserve price) a ‘service’ to be used at the time of auction, to help your item get sold in a manner that you want.

The only problem with this logic is that your item never actually sells because the auction was rigged by a fake and scummy buyer who never had the intention of paying in the first place.  However, eBay doesn’t care what the end result is… they just want their fees.  So in the end, the breakdown is something like this:

Insertion fee: $2.40 (this will be refunded, in a month)
Reserve auction fee: $2.40 (fuck you, pay me)
Final Value Fee: $30.00  (this will be refunded, in a month)

The best part?  I get to pay another $2.40 to re-list my item as I wait for this claim to go through.

What a fucking scam.  And just in case you were wondering, I’ve been an eBay seller for over a decade, with many sold items under my belt.  I’m a veteran eBayer, and as such, I have every single seller protection tool enabled that I can possibly enable, including blocking all buyers that:

  • Don’t have a PayPal account
  • Have received 2 Unpaid Item strike(s) within 1 Month(s)
  • Have a primary shipping address in a location I don’t ship to
  • Have 4 Policy Violation report(s) within 1 Month(s)
  • Have a feedback score of -1 or lower
  • Are currently winning or have bought 1 of my items in the last 10 days and have a feedback score of 1 or lower

These are the most aggressive settings that eBay allows, yet they are missing one critical setting:  The ability to block bids from ‘new’ or zero feedback accounts.  You can only block bids from shoppers with a known sketchy history.

I understand why they don’t allow this setting… after all, how could any new eBay shopper be able to shop if all sellers enabled this setting?  Fair enough.  Maybe it wouldn’t be a good idea to have this kind of restriction available to sellers.  But as it stands now, sellers on eBay can be effectively bled dry of money simply by being scammed over and over by these fake eBay shoppers, all while eBay collects the juice.

Fuck that.  If this happens to you, call eBay and scream bloody murder until they give you a FULL REFUND on your original auction, including all ‘service’ fees.  That’s what I did, and I’ll do it every single time this happens to me until eBay addresses this issue properly.

How should they address it?  Howabout automatic refunds on unpaid items for ALL FEES, and a discount on re-listing your auction (as a nice gesture for your lost time and hassle)?

That would be a great start.

iTunes Match does not work with DRM’ed files (obviously).

In case you were wondering, iTunes Match (the music cloud service provided by Apple, which matches and catalogs your entire music collection into the cloud for playing on all your Apple devices) does not work with files that have DRM.  This is pretty obvious, but I tried to match my Zune collection just to see if it would work, and iTunes threw a ‘content protected’ error.  I assume this includes all forms of DRM files, for example, Zune WMA protected files, etc. – These cannot be matched and uploaded (or otherwise) to the cloud.

So if you were hoping of porting your entire Zune subscription over to iTunes Match, you are out of luck, but all of your mp3 files (as well as the mp3 files you get from Zune’s keep 10 a month program) will upload and/or match just fine, as these are DRM free by default.

There you have it…  Time to start converting everything to MP3!