Skip to content

Instantly share code, notes, and snippets.

@colwilson
Forked from TooTallNate/install-nodejs.sh
Created August 3, 2013 08:02

Revisions

  1. @TooTallNate TooTallNate revised this gist Aug 7, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion oneliner-nodejs.md
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,3 @@
    Starting with node v0.8.6, we're gonna be releasing official binary tarballs of the releases for the most common platform+architecture combos.

    Here's a simple script that will install node using a simple `curl | tar` piping. By default the files will get installed into `/usr/local` (_note:_ you may need to run this as `root` depending on the PREFIX). Change the PREFIX variable to `/usr/local` if you're feeling ambitious.
    Here's a simple script that will install node using a simple `curl | tar` piping. By default the files will get installed into your HOME directory. Change the PREFIX variable to `/usr/local` if you're feeling ambitious (_note:_ you may need to run this as `root` depending on the PREFIX).
  2. @TooTallNate TooTallNate revised this gist Aug 7, 2012. 2 changed files with 11 additions and 14 deletions.
    10 changes: 10 additions & 0 deletions install-nodejs.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    #!/bin/sh

    VERSION=0.8.6
    PLATFORM=darwin
    ARCH=x64
    PREFIX="$HOME/node-v$VERSION-$PLATFORM-$ARCH"

    mkdir -p "$PREFIX" && \
    curl http://nodejs.org/dist/v$VERSION/node-v$VERSION-$PLATFORM-$ARCH.tar.gz \
    | tar xzvf - --strip-components=1 -C "$PREFIX"
    15 changes: 1 addition & 14 deletions oneliner-nodejs.md
    Original file line number Diff line number Diff line change
    @@ -1,16 +1,3 @@
    Starting with node v0.8.6, we're gonna be releasing official binary tarballs of the releases for the most common platform+architecture combos.

    Here's a simple script that will install node using a simple `curl | tar` piping. By default the files will get installed into `/usr/local` (_note:_ you may need to run this as `root` depending on the PREFIX). Change the PREFIX variable to `/usr/local` if you're feeling ambitious.

    ``` bash
    #!/bin/sh

    VERSION=0.8.6
    PLATFORM=darwin
    ARCH=x64
    PREFIX="$HOME/node-v$VERSION-$PLATFORM-$ARCH"

    mkdir -p "$PREFIX" && \
    curl http://nodejs.org/dist/v$VERSION/node-v$VERSION-$PLATFORM-$ARCH.tar.gz \
    | tar xzvf - --strip-components=1 -C "$PREFIX"
    ```
    Here's a simple script that will install node using a simple `curl | tar` piping. By default the files will get installed into `/usr/local` (_note:_ you may need to run this as `root` depending on the PREFIX). Change the PREFIX variable to `/usr/local` if you're feeling ambitious.
  3. @TooTallNate TooTallNate revised this gist Aug 7, 2012. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion oneliner-nodejs.md
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,6 @@
    Starting with node v0.8.6, we're gonna be releasing official binary tarballs of the releases for the most common platform+architecture combos.

    Here's a simple script that will install node using a simple `curl | tar` piping. By default the files will get installed into `/usr/local` (_note:_ you may need to stick `sudo` in front of the `tar` command). Change the PREFIX variable to `/usr/local` if you're feeling ambitious.
    Here's a simple script that will install node using a simple `curl | tar` piping. By default the files will get installed into `/usr/local` (_note:_ you may need to run this as `root` depending on the PREFIX). Change the PREFIX variable to `/usr/local` if you're feeling ambitious.

    ``` bash
    #!/bin/sh
  4. @TooTallNate TooTallNate revised this gist Aug 7, 2012. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion oneliner-nodejs.md
    Original file line number Diff line number Diff line change
    @@ -10,5 +10,7 @@ PLATFORM=darwin
    ARCH=x64
    PREFIX="$HOME/node-v$VERSION-$PLATFORM-$ARCH"

    curl http://nodejs.org/dist/v$VERSION/node-v$VERSION-$PLATFORM-$ARCH.tar.gz | tar xzvf - --strip-components=1 -C $PREFIX
    mkdir -p "$PREFIX" && \
    curl http://nodejs.org/dist/v$VERSION/node-v$VERSION-$PLATFORM-$ARCH.tar.gz \
    | tar xzvf - --strip-components=1 -C "$PREFIX"
    ```
  5. @TooTallNate TooTallNate created this gist Aug 7, 2012.
    14 changes: 14 additions & 0 deletions oneliner-nodejs.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    Starting with node v0.8.6, we're gonna be releasing official binary tarballs of the releases for the most common platform+architecture combos.

    Here's a simple script that will install node using a simple `curl | tar` piping. By default the files will get installed into `/usr/local` (_note:_ you may need to stick `sudo` in front of the `tar` command). Change the PREFIX variable to `/usr/local` if you're feeling ambitious.

    ``` bash
    #!/bin/sh

    VERSION=0.8.6
    PLATFORM=darwin
    ARCH=x64
    PREFIX="$HOME/node-v$VERSION-$PLATFORM-$ARCH"

    curl http://nodejs.org/dist/v$VERSION/node-v$VERSION-$PLATFORM-$ARCH.tar.gz | tar xzvf - --strip-components=1 -C $PREFIX
    ```