Tags: files

22

sparkline

Tuesday, July 10th, 2018

When 7 KB Equals 7 MB - Cloud Four

I remember Jason telling me about this weird service worker caching behaviour a little while back. This piece is a great bit of sleuthing in tracking down the root causes of this strange issue, followed up with a sensible solution.

Sunday, June 17th, 2018

Detecting image requests in service workers

In Going Offline, I dive into the many different ways you can use a service worker to handle requests. You can filter by the URL, for example; treating requests for pages under /blog or /articles differently from other requests. Or you can filter by file type. That way, you can treat requests for, say, images very differently to requests for HTML pages.

One of the ways to check what kind of request you’re dealing with is to see what’s in the accept header. Here’s how I show the test for HTML pages:

if (request.headers.get('Accept').includes('text/html')) {
    // Handle your page requests here.
}

So, logically enough, I show the same technique for detecting image requests:

if (request.headers.get('Accept').includes('image')) {
    // Handle your image requests here.
}

That should catch any files that have image in the request’s accept header, like image/png or image/jpeg or image/svg+xml and so on.

But there’s a problem. Both Safari and Firefox now use a much broader accept header: */*

My if statement evaluates to false in those browsers. Sebastian Eberlein wrote about his workaround for this issue, which involves looking at file extensions instead:

if (request.url.match(/\.(jpe?g|png|gif|svg)$/)) {
    // Handle your image requests here.
}

So consider this post a patch for chapter five of Going Offline (page 68 specifically). Wherever you see:

if (request.headers.get('Accept').includes('image'))

Swap it out for:

if (request.url.match(/\.(jpe?g|png|gif|svg)$/))

And feel to add any other image file extensions (like webp) in there too.

Friday, February 9th, 2018

Href Tools - Free online web tools

Handy web-based tools—compress HTML, CSS, and JavaScript, and convert files from one format to another.

Tuesday, January 16th, 2018

How To Make A Drag-and-Drop File Uploader With Vanilla JavaScript — Smashing Magazine

A step-by-step guide to implementing drag’n’drop, and image previews with the Filereader API. No libraries or frameworks were harmed in the making of this article.

Monday, September 11th, 2017

No space left on device – running out of Inodes – Ivan Kuznetsov

This blog post saved my ass—the Huffduffer server was b0rked and after much Duck-Duck-Going I found the answer here.

I’m filing this away for my future self because, as per Murphy’s Law, I’m pretty sure I’ll be needing this again at some point

Thursday, January 12th, 2017

Saving you bandwidth on Google+ through machine learning

This is an interesting use of voodoo magic (or “machine learning” as we call it now) by Google to interpolate data in a small image to create a larger version. A win for performance.

Thursday, March 24th, 2016

Angola’s Wikipedia Pirates Are Exposing the Problems With Digital Colonialism | Motherboard

The street finds its own uses for colonial internet practices:

Because the data is completely free, Angolans are hiding large files in Wikipedia articles on the Portuguese Wikipedia site (Angola is a former Portuguese colony)—sometimes concealing movies in JPEG or PDF files. They’re then using a Facebook group to direct people to those files, creating a robust, completely free file sharing network.

Wednesday, April 8th, 2015

CloudConvert - convert anything to anything

Ignore the silly name: this looks a supremely useful service—convert just about any file format into just about any other file format.

Friday, January 23rd, 2015

The Emularity « ASCII by Jason Scott

Jason documents some pretty amazing levels of emulation in JavaScript:

That’s Netscape 1.0n, released in December of 1994, running inside Windows 3.11, released in August of 1993, running inside of Google Chrome 39.0.2171.99 m, released about a week ago, on a Windows 7 PC, released in 2009.

But when it comes to trying to navigate the web with that set-up, things get a bit depressing.

Tuesday, December 2nd, 2014

On File Formats, Very Briefly, by Paul Ford · The Manual

A history lesson and a love letter to the early web, taking in HTML, Photoshop, and the web standards movement.

Those were long years, the years of drop-shadows. Everything was jumping just slightly off the screen. For a stretch it seemed that drop-shadows and thin vertical columns of text would define the web. That was before we learned that the web is really a medium to display slideshows, as many slideshows as possible, with banner ads.

Tuesday, June 24th, 2014

Permanence - Matt Gemmell

Some good ideas from Matt on the importance of striving to maintain digital works. I find it very encouraging to see other people writing about this, especially when it’s this thoughtful.

Thursday, January 17th, 2013

Song blogging: Files That Last

I hereby declare that this song is my official anthem.

I want some files that last, data that will not stray.

Files just as fresh tomorrow as they were yesterday.

Friday, October 26th, 2012

Just Solve the Problem Month 2012: Nitty Gritty « ASCII by Jason Scott

Jason goes into detail describing the File Format problem that he and others are going to tackle in the effort known as Just Solve The Problem.

Wednesday, March 21st, 2012

ARCHIVE TEAM: A Distributed Preservation of Service Attack - YouTube

Jason’s rip-roaring presentation from Defcon last year.

ARCHIVE TEAM: A Distributed Preservation of Service Attack

Thursday, March 1st, 2012

The Jason Scott Adventure | Glorious Trainwrecks

Download and play the Jason Scott Adventure — only you can help Jason save the internet!

Monday, August 17th, 2009

Re-finding five numbers

So, remember when I posted all those episodes of Simon Singh’s Five Numbers radio series on Pownce so that they’d have permanent URLs? Yeah, well, so much for that.

Fortunately Brian had saved all the MP3s. I’ve posted them on S3 and huffduffed them all. I can be fairly confident that Huffduffer won’t be going the way of Pownce, Magnolia, Geocities, and so many more.

Anyway, if you want to listen to the fifteen episodes of the three radio series’ on mathematics, you can subscribe to the podcast at https://huffduffer.com/adactio/tags/five+numbers/rss.

Or you can listen to each episode at these permanent URLs:

  1. Five Numbers

    1. A Countdown to Zero
    2. Simple as Pi
    3. The Golden Ratio
    4. The Imaginary Number
    5. Infinity
  2. Another Five Numbers

    1. The Number Four
    2. The Number Seven
    3. The Largest Prime Number
    4. Kepler’s Conjecture
    5. Game Theory
  3. A Further Five Numbers

    1. 1 — The Most Popular Number
    2. 2 — At The Double
    3. 6 Degrees of Separation
    4. 6.67 x 10^-11 – The Number That Defines the Universe
    5. 1729 — The First Taxicab Number

Friday, August 8th, 2008

Finding five numbers

I like Tumblr. I like Pownce. They both make it very quick and easy to post discrete quanta of information. I use Pownce for posting audio files and links to videos. I use Tumblr to post quotations. But both services suffer from the same problem: refindability.

Magnolia and Delicious encourage tagging. Those tags can then surface some pretty interesting aggregate behaviour but first and foremost, they’re useful for the individual doing the tagging. It’s pretty easy for me to track down something I bookmarked on Magnolia even if it was quite a while back. I don’t need to keep a list of all the tags I’ve ever used: I just need to search for a word that I think I might have used when I was tagging a bookmark. While it would be very difficult for me to try to second-guess how someone else might describe something, it’s usually pretty easy to put myself in the shoes of my past self.

As my store of data on Pownce and Tumblr increases, I’m starting to miss tagging (or any kind of search) more and more. Then again, I can understand why both services would resist that kind of scope creep. Both services rely on their simplicity. Adding another field to fill in could potentially be a road block between the user and the task they want to accomplish (although it doesn’t feel that way with Delicious or Magnolia). Update: it turns out that you can tag in Tumblr but it’s hidden behind the “advanced” link. Thanks to Keith Bell for pointing that out.

Here’s a case in point. Over time I’ve been posting MP3 files to Pownce of a series of radio programmes by Simon Singh, author of The Code Book — a superb piece of work. The audio from the radio programmes is available from the BBC website but only in Real Audio which, let’s face it, is complete pants. I originally got the MP3 files from Brian but after a catastrophic hard drive crash, I realised that it would be better to store them at an addressable URL. Besides, I wanted to geek out with my mathematically-minded friends. Pownce’s raison d’être is sharing stuff with friends so it seemed like the perfect home for the Singh files.

But without any kind of tagging or search, there’s no easy way for me or anyone else to revisit just those files at a later date. As a temporary patch, I’m listing the URLs for the Pownce posts that correspond to each episode. If you want to download the files, you’ll need to log in to Pownce.

  1. Five Numbers

    1. A Countdown to Zero
    2. Simple as Pi
    3. The Golden Ratio
    4. The Imaginary Number
    5. Infinity
  2. Another Five Numbers

    1. The Number Four
    2. The Number Seven
    3. The Largest Prime Number
    4. Kepler’s Conjecture
    5. Game Theory
  3. A Further Five Numbers

    1. 1 — The Most Popular Number!
    2. 2 — At the Double
    3. 6 Degrees of Separation
    4. 6.67 x 10-11 — The Number that Defines the Universe
    5. 1729 — The First Taxicab Number

Thursday, May 8th, 2008

The Pownce Blog » Blog Archive » Public file sharing and increased file sizes!

Here are the fruits of the latest code push at Pownce: the ability to share files with the public and a tenfold increase in the file size limit.

Monday, July 2nd, 2007

Pownce

The latest social networking app de jour is called Pownce. Like most people, I signed up a few days ago and starting playing around.

If you read the 140 character reviews of Pownce on Twitter, you’d be forgiven for thinking that Pownce is some kind of Twitter clone. Here, for example, is the collected wisdom of Paul Boag:

Just dont get pownce. Just feels like Twitter but i need to invite all my friends again

Not sure I can be bothered to update both twitter and pownce. Might have to make a decision soon.

It’s understandable, I suppose. Pownce lets you send little updates… just like Twitter. You can share links… just like Del.icio.us. You can share share events… just like Upcoming. So comparing Pownce to any of these services is understandable, I suppose. But I am reminded of the story of the blind men and the elephant. It seems that many of my own friends are displaying a disappointing lack of imagination by only comparing Pownce to what they already know.

The key feature of Pownce is the ability to share files. If you read the about page, the service is defined in a nutshell:

Pownce is a way to send stuff to your friends.

Stuff + friends. And like all the best apps, it was built to scratch an itch:

Pownce is brought to you by a bunch of geeks who were frustrated trying to send stuff from one cube to another.

If you want to compare it to anything, Dropsend feels like the closest competitor. Pownce is a pain-free way of sharing music, video and images amongst a discrete group of people.

And that’s the other key point: groups of people. It’s no coincidence that this app has support for groups built in from the start. The combination of file sharing with groups could potentially make it a killer app. It could be a social app like Twitter or whatever, but I think it could just as easily be a productivity app, more akin to something from 37 Signals.

Here’s an example: I’ve got everyone in the Clearleft office signed up. Each of us can have as many friends as we want but as long as we each have a Clearleft group, we can share files, links, events and notes with one another.

I’ve also created a Britpack group. If enough of my fellow Illuminati sign up, I can share stuff privately with them—something I can’t do on the mailing list because it quite rightly strips out attachments.

Another potential use would be for my band, Salter Cane. Emailing songs around is a royal pain. Being able to share MP3 files with an addressable but private URL could be really handy.

Far from being another Twitter or Jaiku, Pownce is a completely different part of the ecosystem of the social web.

I still plan to put public events on Upcoming and videos on YouTube, Viddler, Vimeo or wherever. But for that space between private and public, when I want to share something with a certain number of people, Pownce sure beats CCing a bunch of email addresses.

There’s another unspoken advantage that Pownce has over other social uploading sites like YouTube. If you’re sharing a file that might be slightly bending the law around license agreements or copyright, the ability to restrict the circulation could save everyone a lot of hassle. What the RIAA and MPAA don’t know won’t hurt ‘em.

The utility of Pownce isn’t the only reason I like it. It’s also really nicely designed. I don’t just mean the visual design—which is lovely, thanks to Daniel. The interaction design is well thought-out.

This is a surprisingly full-featured app considering that just four people put it together. There was just one full-time programmer for the website: Leah Culver. In spite of that, the site has launched (still in Alpha) with a whole bunch of features. The notifications and privacy settings, for example, are really nicely done. There’s also a nice “friends of friends” feature to help you track down people you might know.

Oh, and it’s got one of the best 404 pages ever.

Under the hood, everything has been put together with Django with storage handled by Amazon’s Simple Storage Service. If you peek into the markup, you’ll also find a bunch of nice microformats.

There’s also a desktop app for the service. It’s built using AIR née Apollo. It’s pretty slick and frankly, seeing an independent product like this is going to be far more likely to convince me of the benefits of the platform than any product demo from Adobe.

There are whole bunch of other little things that I like about Pownce that add to its personality—like the gender options in the profile form or the ability to choose themes—but I’ll stop going on about it. The key thing is that I can see this service filling a need through the combination of groups + file sharing.

If you’ve tried Pownce and come away feeling that it’s just like Twitter, you’re doing it wrong.

Thursday, November 9th, 2006

The Promise of a Post-Copyright World | QuestionCopyright.org

The origins and history of copyright. Copyright was originally designed to subsidize distribution, not creation. Not much has changed... until now.