An MSDN post from 2007 describes how to format a single file to be valid CSS and JavaScript at the same time.
Probably not something I’d use on a regular site, still a clever hack though.
An MSDN post from 2007 describes how to format a single file to be valid CSS and JavaScript at the same time.
Probably not something I’d use on a regular site, still a clever hack though.
At the end of 2015 Automattic hooked up employees up with a free Fitbit ( awesome ). I opted for the Fitbit Charge HR.
It has been a month and I can confidently say that I like it. Quantifying some of the activity I do each day is a good reminder to pay attention to how much ( or how little ) I’m doing.
The HR device itself is a bit more awkward than wearing a traditional watch, because of the longer flat section. Having a single button is a good approach, even my kids like to push the button to see how many steps I’ve taken that day.
There are a few things about the HR that I think could be improved.
It was physically painful to open the box. After finally getting it open lets just say that it did not look pretty.
People like to make fun of others who go crazy over opening Apple packages. The unboxing videos can get out of hand. But it isn’t until you try to open a difficult box that you appreciate how nice it is to open a well thought out box.
In the mean time: cut the box open with a knife/scissors, don’t bother trying to do with your bare hands.
When you plugin in the HR the display shows you battery percentage, which is great. The problem is that the battery percentage UI is only displayed when plugged in. The obvious fix would be to include the battery percentage UI in the rotating display when you push the button.
The iPhone App for Fitbit does claim to display the battery percentage. I’ve found it to not be very accurate. Instead what I’ve started doing is to wear the HR until it runs out of juice completely, then plug in.
In the mean time: buy an extra charging cable, stick it in your back pack.
Jake Archibald covers JavaScript tasks, microtasks, queues and schedules in browsers. A good time geeking out on the JavaScript event loop.
Yesterday we packed up the Christmas decorations. This involves three general steps:
The problem with these steps is that we always manage to forget a few items, which requires bringing back out all of the boxes.
This year I’ve finally learned my lesson and adjusted the steps above to incorporate a staging area for the boxes:
Wish I’d thought of this sooner.
Today I’m joining the time honored tradition of making predictions for the new year. Translation: wild guesses and obvious statements.
Perhaps Apple’s single biggest weak spot has been online services. It is clear they know how to do a good job making hardware, all the way down to the chip level in some cases, and software to run on that hardware. Execution of large scale Internet services hasn’t gone as smoothly.
In the past people have suggested that Apple might buy an existing company to help bring in large scale web DNA. I think what is more likely is that Apple makes a few key high level hires that build out new teams.
This won’t be an easy thing for Apple. When I look around at more recent successful web startups I see lots of sharing. That will be a significant change of pace for a company that invests heavily in secrecy.
I consider Swift going open source a positive sign.
Cloudflare has been pushing the Nginx + Lua combination for years now. I consider that particular combination one of the most under rated technology stacks around.
If you were heavy into all the microservices talk during 2015 then Lua+Nginx is an exciting combination. I wouldn’t be surprised if AWS launches a new service around Lua.
I recommend OpenResty ( a build of Nginx with Lua ) and lua.space ( community news ).
We have pretty good support for the video element, it is time to move Flash for video to a fallback position. You are probably already doing that for mobile devices, time to go all in.
Microsoft has started to gain back some geek cred with their push into making more of their code open source ( check out https://github.com/Microsoft ). My prediction is they go even further, announcing one of their larger key products will go open source. The big bets would be Exchange or SQL Server. The other big candidate would a component of Office.
If you’d asked about this a year ago, I would have focused on how much I’m not keen on family dynasties for President. At the time Jeb Bush and Hillary Clinton were safe bets on being the candidates from their respective parties. One had a brother and father who were President, the other a husband. Since then there have been dramatic changes on the Republican side, and very little change on the Democratic side.
My prediction: things get even stranger before the general election. This might be the year for a contested convention.
The official description for Amazon Aurora:
Amazon Aurora is a MySQL-compatible, relational database engine that combines the speed and availability of high-end commercial databases with the simplicity and cost-effectiveness of open source databases.
This video provides more details:
Looking at all this I’m reminded of something I wrote back in April 2008: Sun Should Be in the Consumer Cloud Services Business ( this was a few months after Sun purchased MySQL and before Oracle purchased Sun ):
What I’d like to see from Sun is a MySQL cloud service that works just like your current MySQL server(s), only better. It should scale such that I don’t have to worry about performance and replicate data sufficiently that I’ll always have access to my data. There’s no need for a new API, since MySQL already supports network connectivity.
It feels like Amazon was aiming for the same thing with Aurora. The rest, as they say, is history.
Earlier this month I mentioned going all in with Google Photos. Part of that process was doing a full export of my photos and videos from Flickr and importing them into Google Photos.
After looking around at options I eventually settled upon this version of flickrtouchr.py to do the export. Background about this code is on a post here.
This worked fine with one exception. It used .jpg
as the extension for all of the files, even the videos. I didn’t realized this until the export was done. So I whipped up a simple Bash script to change the extension on the video files to .mov
:
#!/bin/bash cd $1 for file in * do filename=$(basename $file) filename="${filename%.*}" mimetype=$(file --mime-type -b "$file") case $mimetype in video/quicktime) mv -v "$filename.jpg" "$filename.mov" ;; esac done
In the end I had nearly 7,000 files from my Flickr account.
I started with using the web based uploader, since it worked fine for the one off items in the past. Turns out the web uploader sometimes fails to upload an item. It tells you about the failure, but doesn’t make it easy to re-try ( let alone re-try automatically ).
I gave up on web uploader and switched to the Google Photos “Desktop Uploader” Mac App. If you need to upload a large number of items to Google Photos the Desktop Uploader is the way to go, don’t bother with anything else.
There is one item that you need to be careful with when using the Desktop Uploader. It will use every drop of bandwidth you have, with no rate limiting options. I ended up letting it run over night, when nothing else was using the Internet connection at home.
After several experiments with other options, I’m happy with the process I outlined above. It isn’t perfect, but it does get the job done.
Slides from Nic Jansma on measuring the performance of single page applications:
This is an area that I’ll be spending some time on in 2016.