Archive for March 14, 2015

Saturday, March 14, 2015

Jony Ive and the Newton MessagePad 110

Leander Kahney (via Thomas Brand):

Jony designed a clever, spring-loaded latch mechanism; when you pressed the lid, it popped open. The mechanism depended on a tiny copper spring carefully calibrated to give just the right amount of pop. To allow the lid to clear any expansion cards in the slot on top, Jony created a double hinge to allow the lid to clear any obstructions. When the lid was open, it flipped up and over the back to be stored out of the way. That conveyed something to the user too. “Pushing the lid up and around the back was important because the action is not culturally specific,” Jony noted at the time.

The original Newton MessagePad had no cover/lid. The thinner pen attached to the right side and didn’t telescope.

Simple Reflection in Swift

Angelo Di Paolo (via Aaron Brager):

Swift offers metatype type to refer to the type of any Swift type such as enumerations, structures, and protocols. To access the value of the metatype type use the postfix self expression. […] Now the value of objectType can be used to create a new SomeClass instance just like how a Class value would be used in Objective-C.

[…]

If you examine Swift in Xcode you may have noticed the Reflectable and MirrorType protocols. […] This mirror-based reflection API is not yet officially documented anywhere (at least that I know of) and it seems that for now it is mostly used by the REPL. However, this limited API does give us the capability to inspect some basic information about our values.

[…]

The Swift standard library defines a reflect method that takes a value of any type and returns a mirror (MirrorType) object which provides information about the value such as its type and properties.

[…]

You may have noticed that our Brew struct does not conform to Reflectable and despite the lack of a getMirror() implementation we are still able to produce a mirror when calling reflect(brew). This works because the runtime provides a fall back MirrorType implementation that works for any type when a mirror is not directly provided for a type.

Simple Proof of the Tetris Lamp

Jack Morris (via Hacker News):
The lamp itself is composed of 7 individual pieces, containing a total of 28 squares. Therefore, assuming we can indeed form it into a rectangle, it would have to be 7x4 or 14x2 squares in size. I’m using the former case here simply because it’s a more natural shape, however this proof applies equally as well to the latter. Now imagine that we label each of these squares with a colour - either black or white - such that they form a checkerboard pattern as shown above. Notice that the number of black squares must be equal to the number of white, a property we’ll exploit. So that’s 14 black squares, and 14 white. Looking at each of the pieces individually, the issue with our assumption quickly appears.

Arq Adds Archiving and Google Cloud Storage Nearline

Stefan Reitshamer:

Lots of people have emailed me asking for a way to put their stuff on Glacier and then delete it from their hard drives, because they’re running out of disk space. I used to think that disk space was becoming so plentiful that this would never be a problem, but the disk-space growth graph started over with the advent of SSDs, so I guess we’re not there yet!

Arq is our backup app that reliably backs up your files to your own Amazon Glacier account. It has always expected the files to remain on your disk. But now we’ve changed that! You can pick a folder and mark it as an archive.

Avtandil Garakanidze:

Today, we're excited to introduce Google Cloud Storage Nearline, a simple, low-cost, fast-response storage service with quick data backup, retrieval and access. Many of you operate a tiered data storage and archival process, in which data moves from expensive online storage to offline cold storage. We know the value of having access to all of your data on demand, so Nearline enables you to easily backup and store limitless amounts of data at a very low cost and access it at any time in a matter of seconds.

The response time is about 3 seconds, rather than about 3 hours for Amazon Glacier. The current price for storage is 1 cent per GB per month, the same as Glacier. Unlike Glacier, uploading is free.

Stefan Reitshamer:

Arq 4.10 is now available, and it includes support for backing up to Google’s just-announced “nearline” storage!

Bidding Farewell to Google Code

Chris DiBona:

As developers migrated away from Google Code, a growing share of the remaining projects were spam or abuse. Lately, the administrative load has consisted almost exclusively of abuse management. After profiling non-abusive activity on Google Code, it has become clear to us that the service simply isn’t needed anymore.

Beginning today, we have disabled new project creation on Google Code. We will be shutting down the service about 10 months from now on January 25th, 2016. Below, we provide links to migration tools designed to help you move your projects off of Google Code.

[…]

January 25, 2016 - The project hosting service is closed. You will be able to download a tarball of project source, issues, and wikis. These tarballs will be available throughout the rest of 2016.