Why I turned off email notifications

Just about a week ago I had an epiphany:
Email is a constant. It will never end.

More often than not nothing is actionable
I made a quick change — turn off all notifications for email. None shall pass.

NO EMAIL NOTIFICATIONS. I’ve been doing this for about a year now on my phone and it’s amazing. I’ve been doing it for 3 years on my laptop. I don’t know why I didn’t do it on all my devices sooner. (I don’t get outlook or gmail notifications). It lowers stress and helps me focus on actual tasks instead of context switching into email all the time. Context switching is expensive

Reply too fast, expectations are set

No arguments here. If someone thinks you respond to emails within 5 mins, they will expect it. When you don’t, you’ll be under delivering.

If it’s urgent, why are you using email?

This is a huge pet peeve of mine. "Did you have a chance to respond to that email I sent you 30 seconds ago?" drives me nuts. If it’s an emergency, send me an IM. If I’m offline or don’t respond, get up off your ass and walk over. If I’m remote and offline for some reason, text me.

Permalink

Coding Under Par

when it’s midnight and I’m on a perceived roll with some coding challenge, there doesn’t appear to be any stopping me. I “have all night,” or at least that’s what my monkey brain says. Of course, the smarter half of me knows I should be getting calling it a day and getting some much-needed rest.

I hear this. As I get older, and keep to a rigid sleep schedule, I tend to find myself being useless after 9pm. I do miss the old days io burning through until 2am. Now that flux exists to take care of the circadian issues, we should be able to burn all night. Right? RIGHT!?!

Permalink

Looping through subviews and downcasting in Swift

I’ve been playing around with Auto-Layout. This snippet was helpful to see what constraints were set on what views in my View Hierarchy.

Getting the downcast right on the subviews Array took a few tries:

|  

Functions or Read-Only Properties in Swift?

I’m not sure which is better.  If it’s returning something that is directly tied to the class: a slice/dice of properties is already has, I’m leaning towards properties. Because of the many examples I feel like read-only properties are the way to do.  I’m not the only person wondering, so that’s validating.

Property:

Function:

[sourcecode wraplines=false gutter=false autolinks=false]
Fool by randomness and the black swan

   foo fo fo fo offoofoofo offo
[/sourcecode]

|  

Parsing sentences from a String in Swift

I’ve been looking at how to parse sentences from text recently. While I’m still looking for a more Machine Learning approach, I found NSStringEnumerationBySentences which can get me there faster (for now).  I need to get all of the sentences from a given String.  This could easily be an Objective-C category method.  But, I’m trying to learn as much Swift as I can. I haven’t played with extensions yet. Here we go.

enumerateSubstringsInRange:options:usingBlock: is what I’ll need, but I need the extension first:

Fiddling with Swift’s closure syntax for a little while, and using the shorthand for NSStringEnumerationBySentences, I end up with this:

This could have been condensed even more, but I find this very hard to read:

Ah, but alas. Now I can’t use this in Objective-C. It won’t see the String extension.  It needs to be NSString:

I haven’t quite figured out the naming convention for Swift Extension files yet. Right now, I have this in StringExtentions.swift in my categories folder.  Though…. I guess to be proper it should be NSStringExtentions.swift…

|  

Apple’s Swift Blog

This new blog will bring you a behind-the-scenes look into the design of the Swift language by the engineers who created it, in addition to the latest news and hints to turn you into a productive Swift programmer.

I LOVE the new, open-er Apple. From the barriers between iOS and OSX coming down, some Apple devs being more open on twitter and in the dev forums, and now this blog.

It’s an amazing time to be using Apple dev tools

Permalink

On Working From Home and Running a Business

Shawn Blanc talks about how he organizes himself and his company for working from home. One day…

I cannot express enough just how absolutely critical it has been to have a budget — both for our company and for our personal household expenses.

Did you know that most of America’s millionaires are people who earn low-six-figure incomes? They have a high net worth (between $1 – $10 million) because they live simply and budget their money.

When we were saving for the down pay payment on our condo we were using a combination of mint.com and an allowance (envelope method, cash)
I’ve started playing around with mint again to get a better idea of what we spend lonely on and prep us for the next chapter.

Permalink

Format JSON and save to gist with Alfred

At work, we have an Angular app that deals with a lot of custom JSON. With a distributed dev team, we pass a LOT of JSON around.  Copying from Chrome’s net tab, formatting, adding to a Github gist for easy transport is a PITA when you are doing it 20 times a day. I have 2 Alfred workflows to help with this.

My Use:

  1. Copy unformatted JSON to clipboard
  2. Alfred “JsonLint”. Formatted JSON is now in my clipboard
  3. Alfred “gist”. URL to raw gist is now in my clipboard
  4. One of these days I’ll chain these together

To get this working:

  1. You’ll need the Alfred PowerPack
  2. Install my JSON lint workflow. (It needs work, but gets the job done)
  3. Install AlfredGist
  • Be sure to follow the setup instructions.
  • I prefer to have the ‘raw’ url returned from AlfredGist. (in the clipboard and opened)
    To enable this, open functions.sh
    Look for this line: gist_url=$(get_json_key “html_url” “$json”)
    Modify to: gist_url=$(get_json_key “raw_url” “$json”)
  • In “gistconfig” set the gists to be private

You should now be able to chain together as I listed above

Let me know if you have any questions!

Whatever goes up, that’s what we do

This is a quite from a Facebook employee:

We’re blind. It doesn’t matter what any individual person thinks about something new. Everything must be tested. It’s feature echolocation: we throw out an idea, and when the data comes back we look at the numbers. Whatever goes up, that’s what we do. We are slaves to the numbers. We don’t operate around innovation. We only optimize. We do what goes up.

There is a flip side to this too, right? Facebook HAS that kind of data. What I wouldn’t DO for that kind of data. Do we have our own custom tracking (Google Analytics) on our magneto sites at work? Of course. Does it get us the data we need? Yes and know. We can track conversions, user flows, A/B test what we need. But, the pixel level knowledge of HOW a user is using the site that Facebook seems to have seems pretty slick.

Permalink