Skip to content

Instantly share code, notes, and snippets.

@bryanwb
Created February 3, 2010 07:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bryanwb/293430 to your computer and use it in GitHub Desktop.
Save bryanwb/293430 to your computer and use it in GitHub Desktop.
// hope this answers your question
//first follow the instructions for setting up narwhal
// http://karmaeducation.org/2010/01/15/getting-started-with-narwhal-a-standard-library-for-javascript/
//update your catalog of available commonJS packages
// tusk is a lot like ruby's 'gem' command
$ tusk update
//then install yuicompressor, shrinksafe others
$ tusk install yuicompressor shrinksafe closure-compiler
//sadly yuicompressor doesn't accept multiple js files as inputs
$ yuicompressor 1.js >> allmy.js; yuicompressor 2.js >> allmy.js; yuicompressor n.js >> allmy.js
//shrinksafe does
$ shrinksafe *.js >> allmy.js
//closure-compiler doesn't seem to work for me for more than 1 file at a time
$ closure-compiler -js some.js >> allmy.js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment