Half-Elf on Tech

Thoughts From a Professional Lesbian

Tag: macintosh

  • A Case Sensitive Headache

    A Case Sensitive Headache

    Like most people, I pull my site down to develop locally. After all, it’s safer. But also like most people, my live machine is a linux box and my personal machine is not. In fact, it’s a Mac, running whatever the latest OS X is. But don’t worry, today’s drama happens on Windows as well.

    You see, I downloaded my local data, imported my database, changed my URLs to local, and stared at a page that had the wrong data. Or rather, the right data and the wrong image. The page for “Sam” was showing me a photo for another character named “Sam.” But on my live site it was fine.

    Commence the Debugging

    The first thing I did was copy the image to a new folder to try and re-upload it. Only that didn’t work out the way I thought it would. You see, I knew the filename was Sam.jpg so I tried to copy that over:

    cp ~/sites/example.com/wp-content/uploads/2018/05/Sam.jpg ~/Downloads

    Only when I went to look, it was again the bad image. In fact, when I looked at all the files in the folder, there was only one file named ‘sam’ when there should be two

    A list of files in local and live sites. The one of the left is local, and it's missing a bunch of files.
    Local site is on the left, live is on the right

    Things were starting to become clear. Next I copied it and renamed it sam.jpg and got an error:

    Error: The name "sam" with extension ".jpg" is already taken. Please choose a different name.

    I’ve got it now. Mac doesn’t understand the different between upper and lower case. It’s not case sensitive.

    Bad News: No Easy Fix

    I’m really sorry about this. There isn’t an easy fix.

    First of all, if you wanted to fix your main hard drive, you would have to reformat it. That’s a pain in the ass. Second? Your Mac will not be happy and things will break. For example, the Steam app doesn’t like it if your Mac is case sensitive. Seriously, I have no idea why. But it’s what it expects.

    This means the ‘fix’ is to partition your hard drive. Since I’m using AFPS, I opted to make a volume instead of a partition, which feels pretty much the same but it’s not. I opted for AFPS with case sensitive and encrypted because I’m generally a neurotic. Making a volume is very fast, and once I was done, I copied everything in my ~/Sites/ folder over to /Volumes/websites/ (where websites is the name of my new volume).

    And now it looks great!

    Mac OS screenshot showing the files are now case sensitive! Yay!

    Except… I still only see one in terminal. I freaked out for a moment and then I realized that while the GUI is smart enough to know that Sam and sam are both S’s, terminal put the capital letters above the lowercase. So all the S’s came before all the s’s.

    Miss Piggy bashing her head into a table. Which is how I felt about now.

    The last step was to move my copy of Chassis over to the new websites volume, spin it back up, and finally it was working properly.

    The Moral?

    Don’t use case-sensitive filenames. Or filenames with special characters like á or í because operating systems are stupid.

    No seriously, that’s it. Haven’t you wondered why people advocate we all use all lower-case for filenames in our code repositories? Because different operating systems are stupid. They don’t always talk properly to each other, they have different ideas of right and wrong, and they’re never going to agree. If you work with multiple operating systems, aim at the lowest common denominator, pick a style, and stick the hell to it.

    That’s your moral.

  • The Never-ending Progress Bar

    The Never-ending Progress Bar

    When you download a file from Safari, it shows you a progress bar for how it's going along. If you happen to download files to a folder in your dock, you'll see a line grow as it downloads, and then vanish.

    Except… sometimes it doesn't.

    A download bar that won't go away

    And then it gets worse if your bar changes size…

    A download bar that looks worse becuase it's not connected to the folder

    Well great. Now what?

    To the terminal!

    No really. It's one command:

    killall Dock

    That's it. It restarts the dock, the download bar goes away, and you can relax.

  • Review: Do The Twist

    Review: Do The Twist

    When I got ready to go to WordCamp Europe this year, I realized I needed a new adapter. I had one, and it worked, but it also was highly imperfect as it required me to charge everything through my laptop. You know that drill, right?

    Like a lot of road warriors, I travel with about four USB plugs and it’s a mess. It’s always looking for good plugs in a hotel room, and hoping I can charge everything. I used to have a cheap USB hub, but it shorted out. Cheap. I knew what I needed, and it was a charging ‘station.’ But I wanted one that would work ‘universally.’

    The Drama Of Plugs

    I don’t actually remember how I found this. It may have actually been an ad that popped up when I was searching for chargers. I’d been thinking about getting a multi-outlet travel power strip with a couple USB ports. My constant worry with those is the 3-prong US outlet isn’t actually universal here. I’ve been in a lot of nice hotels that don’t have them. Worse, converting from 3-prong to European outlets has, in summer at least, caused a power short.

    Seriously, I blew out the power on my floor in Spain once. Sorry.

    OneAdaptr to Bind Them

    And then I ran into OneAdaptr. At first I was skeptical of the idea. While I had a universal adapter, the sort you can plugin anything into and get anything back out of, this was slightly different.

    If you’ve got a Mac laptop, you’re familiar with the odd way you can change your power adapter to use the 2-prong or grab an extension and use a 3-prong. Backpacking off that concept, the Twist+ adapter lets you plugin your laptop right into the base, while leaving you four USB outlets.

    Example of the twist adapter

    This is the TWIST+ World Charging Station. And I’m a super fan.

    How I Use It

    First, yes, I use it entirely as intended, plugging my laptop and all my devices in. But I actually use it more as a USB hub. Shoving it into my purse, I was able to whip it out at a dinner with friends and plug all our devices in to charge. One of them had a 3-in-1 USB charging cable, and we ended up with 6 devices all plugged in and charging.

    This works well with my ‘style’ as I tend to plugin laptops to charge while I shower and clean up at the end of the day. By the time I’m done, the laptop is charged and goes away, and the hub gets plugged in at my nightstand to charge a Watch, a phone, and an iPad. It could even do another phone without breaking a sweat. And in the absolute worst case? I could plug in my laptop and get two more ports.

    If you just want a USB hub, they (will soon) have a World Charging Station which looks about perfect for a lot of things.

  • Postbox: Desktop Email That Doesn’t Suck

    Postbox: Desktop Email That Doesn’t Suck

    While I greatly prefer to use Apple’s default apps whenever possible, I’ve been using Postbox for my email for a while now, especially since I switched over to Gmail for my email hosting.

    While you can use Mail.app with Gmail, it has a lot of issues. I’m not a fan of Gmail in a web browser, either, though I do use it for other things. I like having an app separate to my browser where I can read email. Gmail was built for … well … the browser. It’s never really been a happy marriage to Mail.app, and that’s because Gmail’s IMAP isn’t really IMAP.

    Enter Postbox.

    This is an app based on the open source Thunderbird, but I find it much easier to use. It has a Windows and Mac client, and it looks clean. Since the recent update this year, it’s a purchase I’m happy to have made.

    I currently have two email accounts, one is my Gmail account and one is my ipstenu.org email… Except that second email actually houses a dozen aliases. They all get funneled to different folders based on which alias they’re sent to (or who sent the email at all). My goal was to have only my important emails land in my inbox, which basically means my wife or my family.

    Postbox pretty much just works for me. It’s well documented for how to configure for gmail and it lets me use my keyboard to navigate between folders. I love the arrow keys to go up and down and see what my email is.

    About the only thing that annoys me is there’s a random [Gmail] folder I can’t seem to get rid of. Also you have to be careful about the Gmail All Mail folder being too large but that’s really a problem with Gmail more than any app. In fact, it’s most of why Mail.app is so terrible to use with Gmail.

    Postbox isn’t perfect. It can suck up a lot of memory, and there is some hands-on configuration. This is no ‘set it an forget it’ email client, but again, that’s back to Gmail being a giant moron with regards to IMAP. When compared with Mail.App, I find it more reliable if you have multiple accounts, but also if you have a lot of dynamically sorted folders. Like I do.

    If you’re just using one Gmail account, or you don’t have a complex set of filters and rules, this is overkill. But if you do, give Postbox a try. It has a free trial after all.

  • App Review: iStat Menus

    App Review: iStat Menus

    It’s a simple question. If the meeting is held at noon Pacific time, what time is it UTC? The answer is 1900 hours.

    The reason for the question is complicated. I work with people around the world. My family lives in a multitude of timezones, some across the date line. I travel a lot. I need to know when ‘now’ is, and I need to know when ‘now’ is for someone else all the time.

    Enter iStat Menus for Mac.

    It’s not actually meant for what I use it for. iStat Menus is to help you make a menu item on your Mac that shows you some interesting stats. I can see, at a glance, how strong my wifi really is, or my computer’s temperature (I’m on a MacBook Air, so this is important). I can look at how much memory I’m using to quickly see why things are slow. It gives me quick links to deep dive into things. It’s wonderful when I’m testing new apps and I can see that, yes that one is slow slow slow.

    An example of iStat Menu showing me my CPU details

    But the side benefit for me is how it replaces the Time and Date Menu in my Apple menu bar. When I click on the time, I get this:

    Time and Date menu replacement in my toolbar

    I get my month at a glance, a list of everything for today (including birthdays which I blocked out for you) and then it lists what time it is now in various place. If I hover over each time, I get more details including a Mercator map showing where daylight is right now and relative other places people care about. For $18 I’m able to keep track and know “Oh, maybe I shouldn’t ping someone on social media when it’s 2am for them…” For that alone it would be worth it, but the rest have become invaluable to debugging why my laptop was rebooting randomly.

    If you just need the basic stats, iStat Mini is pretty brilliant. And it’s free.

  • TotalSpaces

    TotalSpaces

    For everyone at WCSF who asked “How did you get your Spaces on Mac to have names?” here’s the answer.

    TotalSpaces 2, by Binary Rage, is “the ultimate grid spaces manager for your Mac” and they’re not wrong. It took me a long time to agree that I needed to utilize spaces on my Mac, but as I started to want to isolate windows to concentrate (and turned off a lot of notifications), I realized that everything in one ‘space’ wasn’t a great idea.

    I sat down and broke out my spaces into what I frequently do:

    • WordPress
    • DreamHost
    • coding
    • writing
    • being social
    • watching movies

    There is some overlap of apps, but in order to make my life easier, I use Chrome for DreamHost and Chromium for ‘WordPress’ (i.e. me) with separate user accounts in Chrome(ium). That way they can sync between users. I made eight spaces and assigned various apps to only open in those spaces, which is why my screen bounces between spaces when I boot up my laptop. This works fine for me, I just don’t look at it for the 4 seconds it takes for an SSD to boot.

    Allocating what apps open where

    The only issue that remains is that sometimes I want multiple apps in multiple spaces, like a web browser. I have Chromium set to ‘Ipstenu’ but I also want it over in my IRC/Slack window, so I can poke things while I talk in meetings. Right now I just tossed one browser window over there, but I wish I could designate an app to be in only two specific spaces at a time.

    I do keep some apps, like BBEdit, set to ‘all spaces’ for that, but that makes it a little weird as it means that window is open in all spaces. The alternative to that is ‘none’ which I use for iTerm2 to have an SSH window for each space.

    TotalSpaces2 has a free trial, so I advocate people test it and use it to see if it helps their flow. It made mine perfect for my brain, which was the most important thing for me.