103 comments

[ 2.7 ms ] story [ 187 ms ] thread
http://xkcd.com/

The front page has an embedded command prompt. You can navigate the comics by typing "prev" and "next". It also supports some unix commands.

According to "license.txt":

    Client-side logic for Wordpress CLI theme :: R. McFarland, 2006, 2007, 2008
    jQuery rewrite and overhaul :: Chromakode, 2010
Thanks for the link. When I clicked the submission the first hit on the google search was, um, this page on HN.
A good prank in itself.
.. and now the second link is a reddit page. Since I wasn't able to use the original link (xkcd.com), I used a google search. I probably should have used the google search with the query "q=xkcd" instead. Unfortunately, I can't change the link target.

  make me a sandwich
and

  sudo make me a sandwich
both work

  find kitten
make me a sandwich and sudo !! don't, though.
Following commands work: - ls - emacs - vim - man - cd - random - date - man first - man last - man help - cat - display XXX (shows comic #XXX)
(comment deleted)
"man cat" also works :)
"hello joshua" is my favorite though.
"man last" kind of turns me on.
I ran the source through jsbeautifier.org yielding this: http://gist.github.com/351418

Some fun stuff:

* there is a MUD

* find kitten launches a mini-game

* apt-get moo

* i read the source code

(comment deleted)
Doesn't that spoil the fun of hunting for the Easter eggs?
Apparently not according to xkcd. Type

  i read the source code
Hunting for Easter eggs on a CLI with no "help" command? Grab a dictionary, and start trying all 1, 2, and 3 word combinations, and let me know what you find. I can wait.
I was all excited and boggled by the idea of there being a MUD, but it's actually a (small) text adventure - not Multi User as far as I can see.
funny, I didn't see anything that would log attempted commands. I was expecting a comic displaying a graph aggregating attempted commands, perhaps relating to a failed relationship of his.
They do log them, via a GET request to /unixkcd/missing
No need to read the source to know that these would work as expected:

* make me a sandwich

* sudo make me a sandwich

(comment deleted)
For the MUD either light your lamp and go south twice or go south then...

javascript:Adventure.status.alive = true;Adventure.rooms['666'].exits = {'south': 11};void(0);

then go south again. Your choice :).

"cat" "look" "man" "go" "light" "light lamp" "reddit" all work
Theres an adventure mode. Try "look" and "go"
don't go south!
Light your lamp before going south and you'll be fine.
(comment deleted)
Awesome! Today's date is March 32nd.

guest@xkcd:/$ date

March 32nd

What's doubly awesome is that the source code looks like it should say "March 22nd"!
Not if you look at the real source (not the github link above)
I just noticed: Web Results 1 - 10 of about 157 for unixkcd. (0.04 nanocenturies) I didn't know google showed nanocenturies!

EDIT: Apparently google is just having fun as when I refresh I also see:

Web Results 1 - 10 of about 190 for unixkcd. (1.21 gigawatts)

  Web Results 1 - 10 of about 190 for unixkcd. (11.90 parsecs)

Web Results 1 - 10 of about 198 for unixkcd. (0.02 femtogalactic years)

Web Results 1 - 10 of about 198 for unixkcd. (0.09 microfortnights)

Web  Results 1 - 10 of about 190 for unixkcd. (0.12 centibeats)

All interesting units of time. :)

I got: Results 1 - 10 of about 297 for unixkcd. (2.00 shakes of a lamb's tail)
(comment deleted)
Extra Internet bonus points for nailing 2 April Fools jokes with 1 HN post!
(comment deleted)
I got (28.47 jiffies)
1.07 times the velocity of an unladen swallow, at warp 9.11, 0.31e+43 Planck times
(0.55 times the velocity of an unladen swallow)
This has got to be the coolest website for geeks. props.
(comment deleted)
the adventure map:

0:{description:'You are at a computer using unixkcd.', exits:{west:1, south:10}},

1:{description:'Life is peaceful there.', exits:{east:0, west:2}},

2:{description:'In the open air.', exits:{east:1, west:3}},

3:{description:'Where the skies are blue.', exits:{east:2, west:4}},

4:{description:'This is what we\'re gonna do.', exits:{east:3, west:5}},

5:{description:'Sun in wintertime.', exits:{east:4, west:6}},

6:{description:'We will do just fine.', exits:{east:5, west:7}},

7:{description:'Where the skies are blue.', exits:{east:6, west:8}},

8:{description:'This is what we\'re gonna do.', exits:{east:7}},

10:{description:'A dark hallway.', exits:{north:0, south:11},

COOL. Vimperator totally screws with it though.
<c-z> enters passthrough mode.

  sudo apt-get upgrade
What does Randall have against Firefox?
nothing, it's a joke about upgrading from a command prompt to a gui
No, he put a || where I think it was meant to be &&:

if (($.browser.name == 'msie') || ($.browser.name == 'firefox' || $.browser.versionX < 3)) {

This is true. Sleep deprivation and logic don't mix well. :)
shame, would have been funnier if it were a joke.
with no sense of irony re the date either
lot's of locate commands:

locate ninja for example.

        ninja: "Ninja can not be found!",
        keys: "Have you checked your coat pocket?",
        joke: "Joke found on user.",
        problem: "Problem exists between keyboard and chair.
shutdown -h 100000

And it goes immediately... Not good :)

goto comicnumber

takes you the designated comic

I hope this is a permanent feature, not just for April Fools day.
guest@xkcd:/$ man next

Request confirmed; you will be reincarnated as a man next.

(comment deleted)
rm -rf works for the directories listed and will actually remove the link until you reload.