Skip to content

Instantly share code, notes, and snippets.

@samsonw
Forked from drnic/$
Created June 23, 2011 08:38
Show Gist options
  • Save samsonw/1042159 to your computer and use it in GitHub Desktop.
Save samsonw/1042159 to your computer and use it in GitHub Desktop.

Revisions

  1. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion $
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,3 @@
    #!/usr/bin/env bash

    $@
    "$@"
  2. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions README.md
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,7 @@
    # Never fear tutorials again

    See [Blog post](http://drnicwilliams.com/2011/06/11/never-fear-dollar-in-readmes-again/)

    Ever see example shell commands like this and wish you could paste them in?

    ```
  3. @drnic drnic renamed this gist Jun 10, 2011. 1 changed file with 0 additions and 2 deletions.
    2 changes: 0 additions & 2 deletions example_readme.md → example_readme.sh
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,3 @@
    ```
    $ rails new myapp
    $ cd myapp
    $ bundle
    ```
  4. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions prompt_addition.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1 @@
    [[ -d $HOME/bin/magic-dollar ]] && export PATH=$PATH":$HOME/bin/magic-dollar"
  5. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 5 additions and 0 deletions.
    5 changes: 5 additions & 0 deletions example_readme.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,5 @@
    ```
    $ rails new myapp
    $ cd myapp
    $ bundle
    ```
  6. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 4 additions and 0 deletions.
    4 changes: 4 additions & 0 deletions install.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,4 @@
    cd ~
    mkdir bin
    git clone git://gist.github.com/1019041.git ~/bin/magic-dollar
    chmod +x ~/bin/magic-dollar/$
  7. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -17,7 +17,7 @@ git clone git://gist.github.com/1019041.git ~/bin/magic-dollar
    chmod +x ~/bin/magic-dollar/$
    ```

    In your `.bash_profile` add the following, if its not already:
    In your `.bash_profile` add the following:

    ```
    [[ -d $HOME/bin/magic-dollar ]] && export PATH=$PATH":$HOME/bin/magic-dollar"
  8. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -20,7 +20,7 @@ chmod +x ~/bin/magic-dollar/$
    In your `.bash_profile` add the following, if its not already:

    ```
    export PATH=$PATH:$HOME/bin
    [[ -d $HOME/bin/magic-dollar ]] && export PATH=$PATH":$HOME/bin/magic-dollar"
    ```

    ## Thanks
  9. @drnic drnic revised this gist Jun 10, 2011. 2 changed files with 6 additions and 2 deletions.
    2 changes: 1 addition & 1 deletion $
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,3 @@
    #!/usr/bin/env bash

    $1 $2 $3 $4 $5 $6 $7 $8 $9
    $@
    6 changes: 5 additions & 1 deletion README.md
    Original file line number Diff line number Diff line change
    @@ -21,4 +21,8 @@ In your `.bash_profile` add the following, if its not already:

    ```
    export PATH=$PATH:$HOME/bin
    ```
    ```

    ## Thanks

    @dwaite for `$@` instead of `$0 $1 ...`
  10. @drnic drnic revised this gist Jun 10, 2011. 1 changed file with 12 additions and 0 deletions.
    12 changes: 12 additions & 0 deletions README.md
    Original file line number Diff line number Diff line change
    @@ -10,3 +10,15 @@ $ bundle

    Fear no more.

    ```
    cd ~
    mkdir bin
    git clone git://gist.github.com/1019041.git ~/bin/magic-dollar
    chmod +x ~/bin/magic-dollar/$
    ```

    In your `.bash_profile` add the following, if its not already:

    ```
    export PATH=$PATH:$HOME/bin
    ```
  11. @drnic drnic revised this gist Jun 10, 2011. 2 changed files with 12 additions and 0 deletions.
    File renamed without changes.
    12 changes: 12 additions & 0 deletions README.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,12 @@
    # Never fear tutorials again

    Ever see example shell commands like this and wish you could paste them in?

    ```
    $ rails new myapp
    $ cd myapp
    $ bundle
    ```

    Fear no more.

  12. @drnic drnic created this gist Jun 10, 2011.
    3 changes: 3 additions & 0 deletions snippet.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,3 @@
    #!/usr/bin/env bash

    $1 $2 $3 $4 $5 $6 $7 $8 $9