Git Product home page Git Product logo

grunt's People

Contributors

adrianheine avatar coliff avatar cowboy avatar ctalkington avatar danheberden avatar dmethvin avatar fredyc avatar jdalton avatar jimmywarting avatar jugglinmike avatar justlep avatar jzaefferer avatar legendary-moonbat avatar micellius avatar mikesherov avatar mklabs avatar notmoni avatar paladox avatar pifantastic avatar rdworth avatar rwaldron avatar scottgonzalez avatar shama avatar sindresorhus avatar sokra avatar sorccu avatar tbranyen avatar vladikoff avatar xhmikosr avatar xizhao avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

grunt's Issues

Task(s) for releases

I'm considering adopting grunt for a few projects. Something I'd be using is a release task, that would, for example, use git-changelog (from git-extras) to update a History.md and to tag and push the actual release (that's what I do for QUnit).

For my validation plugin, there's a bit more going on, currently implemented in Ant: https://github.com/jzaefferer/jquery-validation/blob/master/build.xml - copies files to a dist dir, replaces @Version, minifies, then zips the package, which I then upload as the release.

Mine would be tailored around git, not sure if it should be abstract enough to work with other VCS'.

If there are plans or ideas for this, please post them here.

Using concat to banner all js files

I've seen a few example grunt files that use concat to prepend a banner at the top of .js files. For example the Grunt JQuery build file (https://github.com/cowboy/grunt-jquery-example/blob/master/grunt.js):

concat: {
    'dist/grunt-jquery-example.js': ['<banner>', '<file_strip_banner:src/grunt-jquery-example.js>']
}

Is there a way to use concat with a matching wildcard in the src and dest to banner an arbitrary number of files? For example:

concat: {
    'dist/*.js': ['<banner>', '<file_strip_banner:src/*.js>']
}

Tangential question:
Is there a reason that the documentation for concat doesn't include the <dest>: [ <src> ] syntax that seems to be used in most grunt files? I'm happy to submit a pull request to the docs with that syntax added if it was just an omission.

decouple tasks from grunt

If I wrote a tool for grunt that allowed listing/installing community maintained tasks from the command line, would you consider removing your default tasks from the default grunt install? I think it would make a little more sense if all the tasks were available under the task dir, rather than having them buried in node_modules, especially if someone wants to modify them.

Config not found

Hi,

I have this issue on 0.2.14

    <WARN> Task "development" not found. Used --force, continuing. </WARN>

development.js exists, I have tried many ways to solve it...but no luck :(
My code:

  grunt.cli({
    base: chdir, // An absolute path to the folder with configs, assets etc
    config: 'development.js',
    tasks: taskList
  });

Add zip task

A task that let's you specify files or folders to zip for a release. Would be combined with concat and min.

To make this work cross-platform, we'd need a node zip implementation that doesn't depend on native bindings.

adm-zip has some potential, but doesn't yet implement its addLocalFolder method: https://github.com/cthackers/adm-zip

node-native-zip doesn't implement compression, or rather, let's the user take care of it, which seems like a rather bad idea: https://github.com/janjongboom/node-native-zip

node-zipstream might work, lacks any higher level APIs: https://github.com/wellawaretech/node-zipstream

Here's a prototype implementation of a zip task, using node-zipstream: https://github.com/jzaefferer/jquery-validation/blob/master/grunt.js#L46 (currently breaks with 0.2.0, due to https://github.com/wellawaretech/node-zipstream/issues/5)

Currently that wouldn't work outside that project, and it doesn't yet even cover the full requirements. Though I hope that's a good starting point for an API discussion.

async tasks don't work

due to the changes introduced in 3eba018, long running asynchronous tasks never finish. We discovered this while migrating a project from a Cakefile based build task using stitch to grunt.

Here's the build task that worked on previous versions:

task.registerBasicTask("stitch", "Compile common.js modules with stitch", function( data, name ){

  data.paths = data.paths.map(function(dir){
    return "./" + dir;
  });

  stitch.createPackage( data ).compile(function( error, src ){

    if( error ){
      return log.error( error );
    }

    file.write( name, src );

    log.writeln("File \"" + name + "\" created.");
  });

});

In the current version of grunt the callback passed into compile is never called.

Mechanism for printing out verbose test details, but not verbose everything else

Example:

$ grunt test -v
Initializing
Command-line options: --verbose
Loading built-in "concat.js" tasks and helpers...OK
Tasks: concat
Helpers: concat
Loading built-in "init.js" tasks and helpers...OK
Tasks: init
Helpers: prompt, prompt_for_obj, prompt_for, git_origin, github_web_url, git_init, git_submodule_add
Loading built-in "lint.js" tasks and helpers...OK
Tasks: lint
Helpers: lint
Loading built-in "min.js" tasks and helpers...OK
Tasks: min
Helpers: uglify, gzip, min_max_info, strip_comments
Loading built-in "misc.js" tasks and helpers...OK
Helpers: config, json, child_process, strip_banner, file_strip_banner, banner
Loading built-in "qunit.js" tasks and helpers...OK
Tasks: qunit
Loading built-in "test.js" tasks and helpers...OK
Tasks: test
Loading built-in "watch.js" tasks and helpers...OK
Tasks: watch
Loading config file "grunt.js" tasks and helpers...OK
Tasks: default

Running tasks: test

Running "test" task

Running "test:files" (test) task
Verifying option test.files exists in config...OK

Testing tophat_test.js
uniqueId - exists...OK
uniqueId - returns...OK

>> 7 assertions passed (3ms)

Done, without errors.

It would be nice to be able to run a task with something similar to -v that prints verbose for only that task, like...

--alman, -a Explain the task to me like Ben Alman would :D

$ grunt test -a ;)
Running tasks: test

Running "test" task

Running "test:files" (test) task
Verifying option test.files exists in config...OK

Testing tophat_test.js
uniqueId - exists...OK
uniqueId - returns...OK

>> 7 assertions passed (3ms)

Done, without errors.

Default gruntfile from init:jquery has the wrong min task path

The grunt file that grunt generated for me when I did

$ grunt init:jquery

Created a min task that looks like this:

  min: {
    'dist/project-name.min.js': ['<banner>', 'dist/project-name.js']
  },

Instead, of looking in dist, it should look in src:

  min: {
    'dist/project-name.min.js': ['<banner>', 'src/project-name.js']
  },

Buster.js integration

I just started playing with Grunt and must say it is pretty sweet. Very similar to a custom tool I built a while ago, but far more refined.

I'm considering using Buster.js as a testing platform and would love to see it integrated into grunt. If I can find some time to work on this, I assume grunt is open to considering pull requests? It would be awesome to attach remote browsers and test them simultaneously.
http://busterjs.org/

I'd love to hear thoughts and suggestions before I take a stab at implementing it.

Watch task - potentially useful feature request

I wanted to bring up a watch task scenario that might by useful and not that uncommon.

Currently the watch task allows us to monitor a file, a group of files or a folder for changes for certain type of files and upon change fire a task that is already defined. This is great but I think there is space and a need for improvement.

Lets say we want to use the watch task for things like CoffeScript, Less, Stylus compiling instead of using their own watch features for the purpose of centralizing our tasks and also fill in for the absence of a watch feature like in the case of Less.

At this point when a task is initiated upon a file change we can only run an existing task without really knowing which file has changed. If the name of the file that has changed can be passed to a task that knows how to handle it would be very beneficial.

I'll try to explain with an example:

Lets say we are watching a folder for changes in CoffeScript files. If one file changes, we don't necessarily want to re-compile all the files but just the one that has changed.

Given that currently there is no way for tasks to communicate with one another, enabling such mechanism may even lead to some other useful stuff.

Ultimately I'd like to use grunt for everything that it is or potentially might be able to handle and avoid the need of using other build / minify / compile tools.

Installation problems

I had the following issue during installation, my npm version is 1.1.0-beta-4

npm install grunt -g
npm http GET https://registry.npmjs.org/grunt
npm http 200 https://registry.npmjs.org/grunt
npm ERR! Could not create /usr/local/lib/node_modules/___grunt.npm
npm ERR! error installing [email protected]
npm ERR! Error: EACCES, permission denied '/usr/local/lib/node_modules/___grunt.npm'
npm ERR! Report this *entire* log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <[email protected]>
npm ERR! 
npm ERR! System Darwin 10.8.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "grunt" "-g"
npm ERR! cwd /Volumes/data/Users/jeroenb/repos/voodoo
npm ERR! node -v v0.6.6
npm ERR! npm -v 1.1.0-beta-4
npm ERR! path /usr/local/lib/node_modules/___grunt.npm
npm ERR! code EACCES
npm ERR! message EACCES, permission denied '/usr/local/lib/node_modules/___grunt.npm'
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Volumes/data/Users/jeroenb/repos/voodoo/npm-debug.log
npm not ok
[12:46:52]โˆด /Volumes/data~/repos/voodoo โˆด grunt โœ— โˆด npm install -g grunt
npm http GET https://registry.npmjs.org/grunt
npm http 304 https://registry.npmjs.org/grunt
npm ERR! Could not create /usr/local/lib/node_modules/___grunt.npm
npm ERR! error installing [email protected]
npm ERR! Error: EACCES, permission denied '/usr/local/lib/node_modules/___grunt.npm'
npm ERR! Report this *entire* log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <[email protected]>
npm ERR! 
npm ERR! System Darwin 10.8.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "-g" "grunt"
npm ERR! cwd /Volumes/data/Users/jeroenb/repos/voodoo
npm ERR! node -v v0.6.6
npm ERR! npm -v 1.1.0-beta-4
npm ERR! path /usr/local/lib/node_modules/___grunt.npm
npm ERR! code EACCES
npm ERR! message EACCES, permission denied '/usr/local/lib/node_modules/___grunt.npm'
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Volumes/data/Users/jeroenb/repos/voodoo/npm-debug.log
npm not ok
[12:47:01]โˆด /Volumes/data~/repos/voodoo โˆด grunt โœ— โˆด sudo !!
sudo npm install -g grunt
npm http GET https://registry.npmjs.org/grunt
npm http 304 https://registry.npmjs.org/grunt
npm http GET https://registry.npmjs.org/async
npm http GET https://registry.npmjs.org/colors
npm http GET https://registry.npmjs.org/dateformat/1.0.2-1.2.3
npm http GET https://registry.npmjs.org/glob-whatev
npm http GET https://registry.npmjs.org/jshint
npm http GET https://registry.npmjs.org/nodeunit
npm http GET https://registry.npmjs.org/nopt
npm http GET https://registry.npmjs.org/prompt
npm http GET https://registry.npmjs.org/uglify-js
npm http GET https://registry.npmjs.org/semver
npm http GET https://registry.npmjs.org/gzip-js
npm http GET https://registry.npmjs.org/underscore
npm http 304 https://registry.npmjs.org/dateformat/1.0.2-1.2.3
npm http 304 https://registry.npmjs.org/colors
npm http 304 https://registry.npmjs.org/jshint
npm http 304 https://registry.npmjs.org/async
npm http 304 https://registry.npmjs.org/glob-whatev
npm http 304 https://registry.npmjs.org/nodeunit
npm http 304 https://registry.npmjs.org/prompt
npm http 304 https://registry.npmjs.org/nopt
npm http 304 https://registry.npmjs.org/semver
npm http 304 https://registry.npmjs.org/uglify-js
npm http 304 https://registry.npmjs.org/gzip-js
npm http 304 https://registry.npmjs.org/underscore
npm http GET https://registry.npmjs.org/argsparser
npm http GET https://registry.npmjs.org/minimatch
npm http GET https://registry.npmjs.org/abbrev
npm http GET https://registry.npmjs.org/minimatch
npm http GET https://registry.npmjs.org/crc32
npm http GET https://registry.npmjs.org/deflate-js
npm http GET https://registry.npmjs.org/pkginfo
npm http GET https://registry.npmjs.org/winston
npm http GET https://registry.npmjs.org/tap-assert
npm http GET https://registry.npmjs.org/tap-producer
npm http 304 https://registry.npmjs.org/abbrev
npm http 304 https://registry.npmjs.org/argsparser
npm http 304 https://registry.npmjs.org/minimatch
npm http GET https://registry.npmjs.org/lru-cache
npm http 304 https://registry.npmjs.org/crc32
npm http 304 https://registry.npmjs.org/minimatch
npm http 304 https://registry.npmjs.org/pkginfo
npm http 304 https://registry.npmjs.org/deflate-js
npm http 304 https://registry.npmjs.org/winston
npm http GET https://registry.npmjs.org/eyes
npm http GET https://registry.npmjs.org/loggly
npm http GET https://registry.npmjs.org/stack-trace
npm http 304 https://registry.npmjs.org/tap-assert
npm http 304 https://registry.npmjs.org/tap-producer
npm http GET https://registry.npmjs.org/inherits
npm http GET https://registry.npmjs.org/tap-results
npm http GET https://registry.npmjs.org/yamlish
npm http 304 https://registry.npmjs.org/lru-cache
npm ERR! error installing [email protected]
npm ERR! error installing [email protected]
npm ERR! Error: ENOENT, no such file or directory '/usr/local/lib/node_modules/grunt/node_modules/jshint/bin/hint'
npm ERR! Report this *entire* log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <[email protected]>
npm ERR! 
npm ERR! System Darwin 10.8.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "-g" "grunt"
npm ERR! cwd /Volumes/data/Users/jeroenb/repos/voodoo
npm ERR! node -v v0.6.6
npm ERR! npm -v 1.1.0-beta-4
npm ERR! path /usr/local/lib/node_modules/grunt/node_modules/jshint/bin/hint
npm ERR! code ENOENT
npm ERR! message ENOENT, no such file or directory '/usr/local/lib/node_modules/grunt/node_modules/jshint/bin/hint'
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /Volumes/data/Users/jeroenb/repos/voodoo/npm-debug.log
npm not ok

Basic task - CSS minifier

I've created a simple basic task that will minify (also concat if multiple) CSS files using sqwish.

Running this on my site CSS shrinks it to half.

task.registerBasicTask( 'css_min', 'Minify CSS files with Sqwish.', function( data, name ) {
    var files = file.expand( data );
    var max = task.helper( 'concat', files );
    var min = require('sqwish').minify( max, config('sqwish').strict ); 
    file.write( name, min );
    if ( task.hadErrors() ) {
        return false;
    }
    log.writeln( 'File "' + name + '" created.' );
    task.helper( 'min_max_info', min, max );
});

Feel free to steal if you want it ;)

Development Environment

Currently, it's unclear how one would develop & test extension and tasks. We should think about a way to create a simple environment to that's bootstrapped with grunt

... I'm not sure if this is the best way to describe what I'm looking for

Suggestion: use child_process.exec instead of spawn in child_process helper task

I've been migrating our custom tasks to use the built-in child_process helper task rather than our custom equivalent. I realized that the built in child_process uses spawn and two custom arrays to buffer output when exec provides this built in.

On top of that, .exec operates more closely to actual command line calls which is what I imagine child_process is typically used to emulate. For example, the command handlebars templates/*.html --output=templates.js works fine on the command line and in child_process.exec because they both expand the * wildcard. It fails when using spawn because spawn does not expand the wildcard.

The following is an implementation of the child_process helper using exec while maintaining the exact same function definition: https://gist.github.com/1989146

Command Line Arguments

Is there an example of how to provide command line arguments for a task?

Thanks,
Louis

Character Encoding Issue when running on Windows

I'm using grunt, as packaged in @tbranyen's BackBone.js BoilerPlate project.

Unfortunately, my development PC is a Windows machine.

I've meticulously checked the input files that grunt is concatenating and minifying, and they all seem to be properly encoded as UTF-8. I'm generating three js files - app.js, lib.js and templates.js.

The app file seems to be correctly encoded as UTF-8. The lib and templates files seem to be encoded ISO-8859-1.

Hoping you might have an idea how I can either configure grunt or express to force the right output encoding.

Update:

I tried the following two changes, with no luck.
concat.js, line 17: file.write(name, task.helper('concat', files).toString('utf8'));
min.js, line 33: file.write(name, min.toString('utf8'));

Also read the uglifyjs docs - uglify should output Unicode unless the --ascii directive is sent to it.

Update 2:

I went through contact.js and min.js and added .toString('utf8') everywhere I could, and my text editor now reports that all files generated by the process are UTF-8. I'd create a pull request, but I'm on a new PC and haven't set up git on it yet (horrors).

Don't spend too much time on it on my account, please - encoding issues can be a real PITA. Consider it an FYI in case someone else comes to you with a problem that could be down to encoding issues.

Thanks for the nice tool!

Init task docs

When do you think you'll have something that documents the init task?

configure inside package.json

In the interest of having fewer files, how about supporting configuration inside of package.json?

As an example, browserify supports a browserify option, and npm happily accepts it.

This should definitely be optional, and the configuration options would have to be json.

Pass config object to the init

Hi

I was wondering if it would be interesting to move the config (optionally) to an object you pass while using grunt inside of a nodejs app. Like so:

# start grunt
grunt.cli {
   base: __dirname,
   config: { /* the full object, as it is present inside grunt.js ยจ/ },
   tasks: tasks
}

The reason I am asking this, is because I made a project that is build upon grunt. Users should be able to add tasks and properties to the original grunt.js. For example, the user wants to execute all predefined tasks, plus wants to add one custom clean task.

I am struggling to get this done. I want to ship a default grunt.js inside of my node module, but allow users to add tasks and specify the order in which the tasks will run. I don't really know how to tackle this. So to wrap it up, consider a grunt.js like so (pseudo code for length):

// default grunt.js shipped with module
config.init({
lint: { files: [] },
concat { files }
);

// grunt.js passed through the CLI by the user, like so
//    MODULE --custom-grunt grunt.js
config.init({
clean { files } // important: this should run BEFORE the default tasks ?
});

I hope you understand my problem?

thank you for your time

Intro/Outro JS and the `concat` task

Something I've often found I include in projects is an intro.js and an outro.js which contain either side of an IIFE that my concatenated code should sit within.

One problem I'm having with grunt is that my lint task looks at the whole lib directory, and obviously errors on these files. It would be really useful to either be able to wrap the results of a concatenation with a helper, or for lint to support negation, e.g:

lint: {
    all: [
        'lib/**/*.js',
        '!lib/intro.js',
        ...
    ]
}

Globals considered harmful.

https://github.com/cowboy/grunt/blob/master/lib/grunt.js#L12-29

A set of statements like this is basically telling your users emphatically that "it's all or nothing folks," whereas in node generally many files can be required independently of each other and that's considered a good thing. It also makes the hooks for your application very difficult to reconcile with other approaches. If I want to modify how you log in grunt, I need to modify a global variable and that just seems wrong.

The approach we've taken in flatiron is to create an App object and pass that app around, attaching functionality along the way through well-defined plugins; basically a feather-weight IoC mechanism.

Would be interested in your thoughts here. I was going to do spec a potential refactor to the flatiron CLI, but these globals were too hard to reconcile with it. I did another one last week: vesln/issues#8

Anyway, neat project though. <3 buildsystems.

Watch misses events

The way the watch task is structured results in missed events. When a file changes and triggers a run of tasks there is an interval where the watched files are not actually watched. For some editors where a "save" event consists of multiple events (including what looks like a delete from the perspective of inotify/watchFile; check out this analysis) this behavior is particularly problematic. In my particular instance, using gvim, I only ever see files deleted and my tasks run seeing empty files.

Perhaps the right approach is to allow the watch task to be persistent and to invoke its dependent tasks without requiring it to restart itself? I played with some other solutions but they all feel like hacks.

publish to npm

As it stands right now grunt is very useful if you can manually install all the dependencies with npm install . This immediately breaks down when you include it in another project that cannot reference it as a dependency. The native modules glob and zlib cannot be easily bundled and having someone go through to npm rebuild is cumbersome.

Would you entertain putting it in NPM, it's current state appears stable enough for general consumption.

Error message for "grunt init" should explain syntax

If you don't already know to type "grunt init:node" with a colon, you might type "grunt init node" or something and be confused why it's not working. It'd be cool if the error message for "grunt init" explained what to do and/or gave an example.

config('pkg.version') toStrings to [object Object]

Here's a simeple task to reproduce:

task.registerTask('print_version', function() {
  log.writeln(config("pkg.version")); // [object Object]
  log.writeln(config("pkg").version); // actual version, e.g. 0.2.15
});

Looks like config('pkg.version') also returns the pkg object, instead of the version property. That's supposed to work, isn't it?

Write output as XML or JSON

At the moment, I'm specifically referring to the lint task, but this would be useful down the road for others.

The use case is that I'm not invoking grunt directly, I would be invoking it from a .NET MSBuild task so that it'll work with our build system. To do that, I'm writing JSON output to stdout from our custom node build script so that I can parse it in C#, but I'd love to migrate to grunt for that.

Would you be open to modifying the provided tasks for that, or is this a "write your own task" situation?

Process templates when expanding config

Somewhat related to the fix for #62 - I've got this on my config:

config.init({
  pkg: '<json:package.json>',
  files: {
    distFolder: 'dist/<%= pkg.name %>-<%= pkg.version %>',
    cdnDistFolder: 'dist/<%= pkg.name %>-<%= pkg.version %>-cdn',
    zip: 'dist/<%= pkg.name %>-<%= pkg.version %>.zip',
    cdnZip: 'dist/<%= pkg.name %>-<%= pkg.version %>-cdn.zip'
  }

Currently I have to expand that manually...

var files = config().files;
for (var key in files) {
  files[key] = template.process(files[key], config());
}
config(

...in order to acccess the processed results from other config properties:

zip: {
  dist: {
    src: '<%= files.distFolder %>/**/*',
    dest: '<%= files.zip %>'
  },
  cdn: {
    src: '<%= files.cdnDistFolder %>/**/*',
    dest: '<%= files.cdnZip %>'
  }
}

Or is there a better way to get the same result? The idea is to not repeat certain paths again and again...

Convert tabs to spaces in lint evidence output

Currently look like....

[L299:C25] 'src' is already defined.
                var src = scripts[i].href.baseVal;
[L301:C17] 'src' used out of scope.
            if (src && src.slice(src.length - "testharness.js".length) === "testharness.js") {
[L301:C24] 'src' used out of scope.
            if (src && src.slice(src.length - "testharness.js".length) === "testharness.js") {
[L301:C34] 'src' used out of scope.
            if (src && src.slice(src.length - "testharness.js".length) === "testharness.js") {
[L302:C33] 'src' used out of scope.

jquery scaffold, qunit test scripts out of order

Currently the source is being included after the tests:

  <!-- Load local lib and tests. -->
  <script src="foo.js_test.js"></script>
  <script src="../src/foo.js"></script>     

It should be included before the tests:

  <!-- Load local lib and tests. -->
  <script src="../src/foo.js"></script>     
  <script src="foo.js_test.js"></script>

This results in "Uncaught TypeError: Object [object DOMWindow] has no method 'foo'"

Possibly change how file-building targets are specified.

Right now, we have:

config.init({
 concat: {
    'dist/grunt-jquery-example.js': ['<banner>', '<file_strip_banner:src/grunt-jquery-example.js>']
  }
});

And while you can do grunt concat, if you want to just concat a specific target, you need to do something like grunt concat:dist/grunt-jquery-example.js.

It would be a lot easier to run only that target like grunt concat:dist, which would be possible if this format was supported:

config.init({
 concat: {
    dist: {
      src: ['<banner>', '<file_strip_banner:src/grunt-jquery-example.js>'],
      dest: 'dist/grunt-jquery-example.js'
    }
  }
});

In addition, it would be cool if the dest filename could be processed as a template like:

'dist/<%= pkg.name %>-<%= pkg.version %>.zip'

See #51 as well.

Can't install

Just installed npm.
[email protected] /usr/local/lib/node_modules/npm

sh-3.2# npm install grunt -g
npm http GET https://registry.npmjs.org/grunt
npm http 304 https://registry.npmjs.org/grunt
npm http GET https://registry.npmjs.org/colors
npm http GET https://registry.npmjs.org/dateformat/1.0.2-1.2.3
npm http GET https://registry.npmjs.org/glob-whatev
npm http GET https://registry.npmjs.org/handlebars/1.0.2beta
npm http GET https://registry.npmjs.org/jshint
npm http GET https://registry.npmjs.org/nodeunit
npm http GET https://registry.npmjs.org/nopt
npm http GET https://registry.npmjs.org/uglify-js
npm http GET https://registry.npmjs.org/underscore
npm http GET https://registry.npmjs.org/gzip-js
npm http 304 https://registry.npmjs.org/colors
npm http 304 https://registry.npmjs.org/handlebars/1.0.2beta
npm http GET https://registry.npmjs.org/handlebars/-/handlebars-1.0.2beta.tgz
npm http 304 https://registry.npmjs.org/dateformat/1.0.2-1.2.3
npm http GET https://registry.npmjs.org/dateformat/-/dateformat-1.0.2-1.2.3.tgz
npm http 304 https://registry.npmjs.org/jshint
npm http 304 https://registry.npmjs.org/glob-whatev
npm ERR! error installing [email protected]
npm http GET https://registry.npmjs.org/jshint/-/jshint-0.5.6.tgz

npm ERR! Error: No compatible version found: glob-whatev@'>=0.1.0- <0.2.0-'
npm ERR! No valid targets found.
npm ERR! Perhaps not compatible with your version of node?
npm ERR!     at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:488:10)
npm ERR!     at next_ (/usr/local/lib/node_modules/npm/lib/cache.js:438:17)
npm ERR!     at next (/usr/local/lib/node_modules/npm/lib/cache.js:415:44)
npm ERR!     at /usr/local/lib/node_modules/npm/lib/cache.js:408:5
npm ERR!     at Object.saved [as oncomplete] (/usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:147:7)
npm ERR! You may report this log at:
npm ERR!     <http://github.com/isaacs/npm/issues>
npm ERR! or email it to:
npm ERR!     <[email protected]>
npm ERR! 
npm ERR! System Darwin 11.2.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "grunt" "-g"
npm ERR! cwd /usr/local/bin
npm ERR! node -v v0.6.1-pre
npm ERR! npm -v 1.1.0
npm ERR! message No compatible version found: glob-whatev@'>=0.1.0- <0.2.0-'
npm ERR! message No valid targets found.
npm ERR! message Perhaps not compatible with your version of node?
npm ERR! 
npm ERR! Additional logging details can be found in:
npm ERR!     /usr/local/bin/npm-debug.log
npm not ok

Here's the log
info it worked if it ends with ok
verbose cli [ 'node', '/usr/local/bin/npm', 'install', '-g', 'grunt' ]
info using [email protected]
info using [email protected]
verbose config file /var/root/.npmrc
verbose config file /usr/local/etc/npmrc
verbose config file /usr/local/lib/node_modules/npm/npmrc
silly exec /usr/local/bin/node "/usr/local/lib/node_modules/npm/bin/npm-get-uid-gid.js" "nobody" 0
silly spawning [ '/usr/local/bin/node',
silly spawning [ '/usr/local/lib/node_modules/npm/bin/npm-get-uid-gid.js',
silly spawning 'nobody',
silly spawning 0 ],
silly spawning null ]
silly output from getuid/gid {"uid":-2,"gid":0}
silly output from getuid/gid
verbose cache add [ 'grunt', null ]
silly cache add: name, spec, args [ undefined, 'grunt', [ 'grunt', null ] ]
verbose parsed url { pathname: 'grunt', path: 'grunt', href: 'grunt' }
verbose addNamed [ 'grunt', '' ]
verbose addNamed [ null, '' ]
silly name, range, hasData [ 'grunt', '', false ]
verbose raw, before any munging grunt
verbose url resolving [ 'https://registry.npmjs.org/', './grunt' ]
verbose url resolved https://registry.npmjs.org/grunt
verbose etag "1AZMXOYJH7VUE32CRO0BYV2KG"
http GET https://registry.npmjs.org/grunt
http 304 https://registry.npmjs.org/grunt
silly get cb [ 304,
silly get cb { server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"1AZMXOYJH7VUE32CRO0BYV2KG"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:30 GMT',
silly get cb 'content-length': '0' } ]
verbose etag grunt from cache
silly name, range, hasData 2 [ 'grunt', '', true ]
silly versions [ 'grunt', [ '0.1.0' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '8f2e718664a7db2d5efdb27622ba2d22277039d1',
verbose bin dist tarball: 'http://registry.npmjs.org/grunt/-/grunt-0.1.0.tgz' } ]
verbose caching /var/root/.npm/grunt/0.1.0/package/package.json
verbose loadDefaults [email protected]
silly resolved [ { author: { name: '"Cowboy" Ben Alman', url: 'http://benalman.com/' },
silly resolved name: 'grunt',
silly resolved description: 'A command line build tool for JavaScript projects.',
silly resolved version: '0.1.0',
silly resolved homepage: 'http://github.com/cowboy/grunt',
silly resolved repository: { type: 'git', url: 'git://github.com/cowboy/grunt.git' },
silly resolved bugs: { url: 'http://github.com/cowboy/grunt/issues' },
silly resolved licenses:
silly resolved [ { type: 'MIT',
silly resolved url: 'http://github.com/cowboy/grunt/blob/master/LICENSE-MIT' } ],
silly resolved main: 'lib/grunt',
silly resolved bin: { grunt: 'bin/grunt' },
silly resolved engines: { node: '>= 0.4.12' },
silly resolved preferGlobal: true,
silly resolved keywords:
silly resolved [ 'cli',
silly resolved 'minify',
silly resolved 'uglify',
silly resolved 'build',
silly resolved 'underscore',
silly resolved 'unit',
silly resolved 'test',
silly resolved 'make',
silly resolved 'jake',
silly resolved 'tool' ],
silly resolved dependencies:
silly resolved { colors: '~0.6.0',
silly resolved dateformat: '1.0.2-1.2.3',
silly resolved 'glob-whatev': '~0.1.0',
silly resolved handlebars: '1.0.2beta',
silly resolved jshint: '~0.5',
silly resolved nodeunit: '~0.6.4',
silly resolved nopt: '~1.0.10',
silly resolved 'uglify-js': '~1.0.7',
silly resolved underscore: '~1.2.4',
silly resolved 'gzip-js': '~0.3.1' },
silly resolved devDependencies: {},
silly resolved _id: '[email protected]',
silly resolved optionalDependencies: {},
silly resolved _engineSupported: true,
silly resolved _npmVersion: '1.1.0',
silly resolved _nodeVersion: 'v0.6.1-pre',
silly resolved _defaultsLoaded: true,
silly resolved scripts: {} } ]
info into /usr/local/lib [email protected]
info installOne [email protected]
info unbuild /usr/local/lib/node_modules/grunt
verbose from cache /var/root/.npm/grunt/0.1.0/package/package.json
verbose mkdir (expected) error ENOENT, No such file or directory '/usr/local/lib/node_modules/___grunt.npm'
verbose mkdir done: /usr/local/lib/node_modules/__grunt.npm 755
verbose unpack
uid, gid [ -2, 0 ]
verbose unpackTarget /usr/local/lib/node_modules/grunt
silly gunzTarPerm modes [ '755', '644' ]
silly afterUntar undefined
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/.npmignore
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/grunt.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/LICENSE-MIT
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/package.json
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/README.md
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/bin
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/bin/grunt
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/util
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/util/namespace.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/util/task.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/cli.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/config.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/fail.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/file.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/help.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/log.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/option.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/task.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/template.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/util.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/tasks
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/tasks/concat.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/tasks/lint.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/tasks/min.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/tasks/misc.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/tasks/test.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/lib/grunt/tasks/watch.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/fixtures
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/fixtures/a.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/fixtures/b.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/fixtures/banner.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/util
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/util/namespace_test.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/util/task_test.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/grunt
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/grunt/tasks
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/grunt/tasks/concat_test.js
silly asyncMap in gTP /usr/local/lib/node_modules/___grunt.npm/package/test/grunt/tasks/misc_test.js
verbose gunzed /usr/local/lib/node_modules/___grunt.npm/package
verbose rm'ed /usr/local/lib/node_modules/grunt
verbose renamed [ '/usr/local/lib/node_modules/__grunt.npm/package',
verbose renamed '/usr/local/lib/node_modules/grunt' ]
verbose caching /usr/local/lib/node_modules/grunt/package.json
verbose loadDefaults [email protected]
info preinstall [email protected]
verbose from cache /usr/local/lib/node_modules/grunt/package.json
verbose cache add [ 'colors@~0.6.0', null ]
silly cache add: name, spec, args [ undefined, 'colors@~0.6.0', [ 'colors@~0.6.0', null ] ]
verbose parsed url { pathname: 'colors@~0.6.0',
verbose parsed url path: 'colors@~0.6.0',
verbose parsed url href: 'colors@~0.6.0' }
silly cache add: name, spec, args [ 'colors', '~0.6.0', [ 'colors', '~0.6.0' ] ]
verbose parsed url { pathname: '~0.6.0', path: '~0.6.0', href: '~0.6.0' }
verbose addNamed [ 'colors', '~0.6.0' ]
verbose addNamed [ null, '>=0.6.0- <0.7.0-' ]
silly name, range, hasData [ 'colors', '>=0.6.0- <0.7.0-', false ]
verbose cache add [ '[email protected]', null ]
silly cache add: name, spec, args [ undefined,
silly cache add: name, spec, args '[email protected]',
silly cache add: name, spec, args [ '[email protected]', null ] ]
verbose parsed url { pathname: '[email protected]',
verbose parsed url path: '[email protected]',
verbose parsed url href: '[email protected]' }
silly cache add: name, spec, args [ 'dateformat', '1.0.2-1.2.3', [ 'dateformat', '1.0.2-1.2.3' ] ]
verbose parsed url { pathname: '1.0.2-1.2.3',
verbose parsed url path: '1.0.2-1.2.3',
verbose parsed url href: '1.0.2-1.2.3' }
verbose addNamed [ 'dateformat', '1.0.2-1.2.3' ]
verbose addNamed [ '1.0.2-1.2.3', '1.0.2-1.2.3' ]
verbose raw, before any munging colors
verbose url resolving [ 'https://registry.npmjs.org/', './colors' ]
verbose url resolved https://registry.npmjs.org/colors
verbose etag "2E3M5RUCGAR8FIO5CKTU67NEB"
http GET https://registry.npmjs.org/colors
verbose raw, before any munging dateformat/1.0.2-1.2.3
verbose url resolving [ 'https://registry.npmjs.org/', './dateformat/1.0.2-1.2.3' ]
verbose url resolved https://registry.npmjs.org/dateformat/1.0.2-1.2.3
verbose etag "BZVNXZP6VS4ZU71L7N04I6YOU"
http GET https://registry.npmjs.org/dateformat/1.0.2-1.2.3
verbose cache add [ 'glob-whatev@~0.1.0', null ]
silly cache add: name, spec, args [ undefined,
silly cache add: name, spec, args 'glob-whatev@~0.1.0',
silly cache add: name, spec, args [ 'glob-whatev@~0.1.0', null ] ]
verbose parsed url { pathname: 'glob-whatev@~0.1.0',
verbose parsed url path: 'glob-whatev@~0.1.0',
verbose parsed url href: 'glob-whatev@~0.1.0' }
silly cache add: name, spec, args [ 'glob-whatev', '~0.1.0', [ 'glob-whatev', '~0.1.0' ] ]
verbose parsed url { pathname: '~0.1.0', path: '~0.1.0', href: '~0.1.0' }
verbose addNamed [ 'glob-whatev', '~0.1.0' ]
verbose addNamed [ null, '>=0.1.0- <0.2.0-' ]
silly name, range, hasData [ 'glob-whatev', '>=0.1.0- <0.2.0-', false ]
verbose cache add [ '[email protected]', null ]
silly cache add: name, spec, args [ undefined,
silly cache add: name, spec, args '[email protected]',
silly cache add: name, spec, args [ '[email protected]', null ] ]
verbose parsed url { pathname: '[email protected]',
verbose parsed url path: '[email protected]',
verbose parsed url href: '[email protected]' }
silly cache add: name, spec, args [ 'handlebars', '1.0.2beta', [ 'handlebars', '1.0.2beta' ] ]
verbose parsed url { pathname: '1.0.2beta', path: '1.0.2beta', href: '1.0.2beta' }
verbose addNamed [ 'handlebars', '1.0.2beta' ]
verbose addNamed [ '1.0.2beta', '1.0.2beta' ]
verbose cache add [ 'jshint@~0.5', null ]
silly cache add: name, spec, args [ undefined, 'jshint@~0.5', [ 'jshint@~0.5', null ] ]
verbose parsed url { pathname: 'jshint@~0.5',
verbose parsed url path: 'jshint@~0.5',
verbose parsed url href: 'jshint@~0.5' }
silly cache add: name, spec, args [ 'jshint', '~0.5', [ 'jshint', '~0.5' ] ]
verbose parsed url { pathname: '~0.5', path: '~0.5', href: '~0.5' }
verbose addNamed [ 'jshint', '~0.5' ]
verbose addNamed [ null, '>=0.5.0- <0.6.0-' ]
silly name, range, hasData [ 'jshint', '>=0.5.0- <0.6.0-', false ]
verbose raw, before any munging jshint
verbose url resolving [ 'https://registry.npmjs.org/', './jshint' ]
verbose url resolved https://registry.npmjs.org/jshint
http GET https://registry.npmjs.org/jshint
verbose cache add [ 'nodeunit@~0.6.4', null ]
silly cache add: name, spec, args [ undefined, 'nodeunit@~0.6.4', [ 'nodeunit@~0.6.4', null ] ]
verbose parsed url { pathname: 'nodeunit@~0.6.4',
verbose parsed url path: 'nodeunit@~0.6.4',
verbose parsed url href: 'nodeunit@~0.6.4' }
silly cache add: name, spec, args [ 'nodeunit', '~0.6.4', [ 'nodeunit', '~0.6.4' ] ]
verbose parsed url { pathname: '~0.6.4', path: '~0.6.4', href: '~0.6.4' }
verbose addNamed [ 'nodeunit', '~0.6.4' ]
verbose addNamed [ null, '>=0.6.4- <0.7.0-' ]
silly name, range, hasData [ 'nodeunit', '>=0.6.4- <0.7.0-', false ]
verbose cache add [ 'nopt@~1.0.10', null ]
silly cache add: name, spec, args [ undefined, 'nopt@~1.0.10', [ 'nopt@~1.0.10', null ] ]
verbose parsed url { pathname: 'nopt@~1.0.10',
verbose parsed url path: 'nopt@~1.0.10',
verbose parsed url href: 'nopt@~1.0.10' }
silly cache add: name, spec, args [ 'nopt', '~1.0.10', [ 'nopt', '~1.0.10' ] ]
verbose parsed url { pathname: '~1.0.10', path: '~1.0.10', href: '~1.0.10' }
verbose addNamed [ 'nopt', '~1.0.10' ]
verbose addNamed [ null, '>=1.0.10- <1.1.0-' ]
silly name, range, hasData [ 'nopt', '>=1.0.10- <1.1.0-', false ]
verbose cache add [ 'uglify-js@~1.0.7', null ]
silly cache add: name, spec, args [ undefined, 'uglify-js@~1.0.7', [ 'uglify-js@~1.0.7', null ] ]
verbose parsed url { pathname: 'uglify-js@~1.0.7',
verbose parsed url path: 'uglify-js@~1.0.7',
verbose parsed url href: 'uglify-js@~1.0.7' }
silly cache add: name, spec, args [ 'uglify-js', '~1.0.7', [ 'uglify-js', '~1.0.7' ] ]
verbose parsed url { pathname: '~1.0.7', path: '~1.0.7', href: '~1.0.7' }
verbose addNamed [ 'uglify-js', '~1.0.7' ]
verbose addNamed [ null, '>=1.0.7- <1.1.0-' ]
silly name, range, hasData [ 'uglify-js', '>=1.0.7- <1.1.0-', false ]
verbose cache add [ 'underscore@~1.2.4', null ]
silly cache add: name, spec, args [ undefined, 'underscore@~1.2.4', [ 'underscore@~1.2.4', null ] ]
verbose parsed url { pathname: 'underscore@~1.2.4',
verbose parsed url path: 'underscore@~1.2.4',
verbose parsed url href: 'underscore@~1.2.4' }
silly cache add: name, spec, args [ 'underscore', '~1.2.4', [ 'underscore', '~1.2.4' ] ]
verbose parsed url { pathname: '~1.2.4', path: '~1.2.4', href: '~1.2.4' }
verbose addNamed [ 'underscore', '~1.2.4' ]
verbose addNamed [ null, '>=1.2.4- <1.3.0-' ]
silly name, range, hasData [ 'underscore', '>=1.2.4- <1.3.0-', false ]
verbose cache add [ 'gzip-js@~0.3.1', null ]
silly cache add: name, spec, args [ undefined, 'gzip-js@~0.3.1', [ 'gzip-js@~0.3.1', null ] ]
verbose parsed url { pathname: 'gzip-js@~0.3.1',
verbose parsed url path: 'gzip-js@~0.3.1',
verbose parsed url href: 'gzip-js@~0.3.1' }
silly cache add: name, spec, args [ 'gzip-js', '~0.3.1', [ 'gzip-js', '~0.3.1' ] ]
verbose parsed url { pathname: '~0.3.1', path: '~0.3.1', href: '~0.3.1' }
verbose addNamed [ 'gzip-js', '~0.3.1' ]
verbose addNamed [ null, '>=0.3.1- <0.4.0-' ]
silly name, range, hasData [ 'gzip-js', '>=0.3.1- <0.4.0-', false ]
verbose raw, before any munging nodeunit
verbose url resolving [ 'https://registry.npmjs.org/', './nodeunit' ]
verbose url resolved https://registry.npmjs.org/nodeunit
http GET https://registry.npmjs.org/nodeunit
verbose raw, before any munging nopt
verbose url resolving [ 'https://registry.npmjs.org/', './nopt' ]
verbose url resolved https://registry.npmjs.org/nopt
http GET https://registry.npmjs.org/nopt
verbose raw, before any munging uglify-js
verbose url resolving [ 'https://registry.npmjs.org/', './uglify-js' ]
verbose url resolved https://registry.npmjs.org/uglify-js
http GET https://registry.npmjs.org/uglify-js
verbose raw, before any munging underscore
verbose url resolving [ 'https://registry.npmjs.org/', './underscore' ]
verbose url resolved https://registry.npmjs.org/underscore
http GET https://registry.npmjs.org/underscore
verbose raw, before any munging gzip-js
verbose url resolving [ 'https://registry.npmjs.org/', './gzip-js' ]
verbose url resolved https://registry.npmjs.org/gzip-js
http GET https://registry.npmjs.org/gzip-js
verbose raw, before any munging glob-whatev
verbose url resolving [ 'https://registry.npmjs.org/', './glob-whatev' ]
verbose url resolved https://registry.npmjs.org/glob-whatev
verbose etag "B2RTW86TLK5E6WAWCXMWSUOC6"
http GET https://registry.npmjs.org/glob-whatev
verbose raw, before any munging handlebars/1.0.2beta
verbose url resolving [ 'https://registry.npmjs.org/', './handlebars/1.0.2beta' ]
verbose url resolved https://registry.npmjs.org/handlebars/1.0.2beta
verbose etag "34UKO8IYOAYH8MYZ3EZBMV5DS"
http GET https://registry.npmjs.org/handlebars/1.0.2beta
http 304 https://registry.npmjs.org/colors
silly get cb [ 304,
silly get cb { server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"2E3M5RUCGAR8FIO5CKTU67NEB"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:30 GMT',
silly get cb 'content-length': '0' } ]
verbose etag colors from cache
silly name, range, hasData 2 [ 'colors', '>=0.6.0- <0.7.0-', true ]
silly versions [ 'colors', [ '0.3.0', '0.5.0', '0.5.1', '0.6.0', '0.6.0-1' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '6dbb68ceb8bc60f2b313dcc5ce1599f06d19e67a',
verbose bin dist tarball: 'http://registry.npmjs.org/colors/-/colors-0.6.0-1.tgz' } ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/colors/-/colors-0.6.0-1.tgz',
verbose addRemoteTarball '6dbb68ceb8bc60f2b313dcc5ce1599f06d19e67a' ]
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786'
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667710786-0.7529468110296875'
verbose mkdir done: /tmp/npm-1326667710786/1326667710786-0.7529468110296875 755
verbose fetch to /tmp/npm-1326667710786/1326667710786-0.7529468110296875/tmp.tgz
http GET https://registry.npmjs.org/colors/-/colors-0.6.0-1.tgz
http 304 https://registry.npmjs.org/dateformat/1.0.2-1.2.3
silly get cb [ 304,
silly get cb { server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"BZVNXZP6VS4ZU71L7N04I6YOU"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:30 GMT',
silly get cb 'content-length': '0' } ]
verbose etag dateformat/1.0.2-1.2.3 from cache
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: 'b0220c02de98617433b72851cf47de3df2cdbee9',
verbose bin dist tarball: 'http://registry.npmjs.org/dateformat/-/dateformat-1.0.2-1.2.3.tgz' } ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/dateformat/-/dateformat-1.0.2-1.2.3.tgz',
verbose addRemoteTarball 'b0220c02de98617433b72851cf47de3df2cdbee9' ]
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667710825-0.1542531333398074'
verbose mkdir done: /tmp/npm-1326667710786/1326667710825-0.1542531333398074 755
verbose fetch to /tmp/npm-1326667710786/1326667710825-0.1542531333398074/tmp.tgz
http GET https://registry.npmjs.org/dateformat/-/dateformat-1.0.2-1.2.3.tgz
http 200 https://registry.npmjs.org/nopt
silly get cb [ 200,
silly get cb { vary: 'Accept',
silly get cb server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"7TEB8SBLM6358ESQXPRRR16XM"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:31 GMT',
silly get cb 'content-type': 'application/json',
silly get cb 'content-length': '9606' } ]
verbose mkdir (expected) error ENOENT, No such file or directory '/var/root/.npm/nopt'
verbose mkdir done: /var/root/.npm/nopt 755
silly name, range, hasData 2 [ 'nopt', '>=1.0.10- <1.1.0-', true ]
silly versions [ 'nopt',
silly versions [ '1.0.0',
silly versions '1.0.1',
silly versions '1.0.2',
silly versions '1.0.3',
silly versions '1.0.4',
silly versions '1.0.5',
silly versions '1.0.6',
silly versions '1.0.7',
silly versions '1.0.8',
silly versions '1.0.9',
silly versions '1.0.10' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '6ddd21bd2a31417b92727dd585f8a6f37608ebee',
verbose bin dist tarball: 'http://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz' } ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz',
verbose addRemoteTarball '6ddd21bd2a31417b92727dd585f8a6f37608ebee' ]
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667710933-0.8643804911989719'
verbose mkdir done: /tmp/npm-1326667710786/1326667710933-0.8643804911989719 755
verbose fetch to /tmp/npm-1326667710786/1326667710933-0.8643804911989719/tmp.tgz
http GET https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz
http 200 https://registry.npmjs.org/nodeunit
silly get cb [ 200,
silly get cb { vary: 'Accept',
silly get cb server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"B021TVMY8JBXG4TO2H6KHTWT4"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:30 GMT',
silly get cb 'content-type': 'application/json',
silly get cb 'content-length': '25560' } ]
http 200 https://registry.npmjs.org/jshint
silly get cb [ 200,
silly get cb { vary: 'Accept',
silly get cb server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"280RU5S303TIC31R8IDPQC05O"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:31 GMT',
silly get cb 'content-type': 'application/json',
silly get cb 'content-length': '19580' } ]
verbose mkdir (expected) error ENOENT, No such file or directory '/var/root/.npm/nodeunit'
verbose mkdir (expected) error ENOENT, No such file or directory '/var/root/.npm/jshint'
verbose mkdir done: /var/root/.npm/nodeunit 755
verbose mkdir done: /var/root/.npm/jshint 755
silly name, range, hasData 2 [ 'nodeunit', '>=0.6.4- <0.7.0-', true ]
silly versions [ 'nodeunit',
silly versions [ '0.1.0',
silly versions '0.1.1',
silly versions '0.1.2',
silly versions '0.2.0',
silly versions '0.2.1',
silly versions '0.2.2',
silly versions '0.2.3',
silly versions '0.2.4',
silly versions '0.3.1',
silly versions '0.4.0',
silly versions '0.5.0',
silly versions '0.5.1',
silly versions '0.5.2',
silly versions '0.5.3',
silly versions '0.5.4',
silly versions '0.5.5',
silly versions '0.6.0',
silly versions '0.6.1',
silly versions '0.6.2',
silly versions '0.6.3',
silly versions '0.6.4' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '9bd543035b6f86d9db2030d872dee28513dbf499',
verbose bin dist tarball: 'http://registry.npmjs.org/nodeunit/-/nodeunit-0.6.4.tgz' } ]
silly name, range, hasData 2 [ 'jshint', '>=0.5.0- <0.6.0-', true ]
silly versions [ 'jshint',
silly versions [ '0.1.8',
silly versions '0.1.9',
silly versions '0.2.0',
silly versions '0.2.1',
silly versions '0.2.2',
silly versions '0.2.3',
silly versions '0.3.0',
silly versions '0.3.1',
silly versions '0.4.0',
silly versions '0.5.0',
silly versions '0.5.1',
silly versions '0.5.2',
silly versions '0.5.3',
silly versions '0.5.4',
silly versions '0.5.5',
silly versions '0.5.6' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '64ed3d3701d2becbd3f838b4d4280aef72731b2c',
verbose bin dist tarball: 'http://registry.npmjs.org/jshint/-/jshint-0.5.6.tgz' } ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/nodeunit/-/nodeunit-0.6.4.tgz',
verbose addRemoteTarball '9bd543035b6f86d9db2030d872dee28513dbf499' ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/jshint/-/jshint-0.5.6.tgz',
verbose addRemoteTarball '64ed3d3701d2becbd3f838b4d4280aef72731b2c' ]
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667710987-0.8974952280987054'
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667710987-0.8644481091760099'
verbose mkdir done: /tmp/npm-1326667710786/1326667710987-0.8974952280987054 755
verbose mkdir done: /tmp/npm-1326667710786/1326667710987-0.8644481091760099 755
verbose fetch to /tmp/npm-1326667710786/1326667710987-0.8974952280987054/tmp.tgz
verbose fetch to /tmp/npm-1326667710786/1326667710987-0.8644481091760099/tmp.tgz
http GET https://registry.npmjs.org/nodeunit/-/nodeunit-0.6.4.tgz
http GET https://registry.npmjs.org/jshint/-/jshint-0.5.6.tgz
http 200 https://registry.npmjs.org/uglify-js
silly get cb [ 200,
silly get cb { vary: 'Accept',
silly get cb server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"DZMWU7I4ISG63E8QZER4QB3P6"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:31 GMT',
silly get cb 'content-type': 'application/json',
silly get cb 'content-length': '15063' } ]
verbose mkdir (expected) error ENOENT, No such file or directory '/var/root/.npm/uglify-js'
verbose mkdir done: /var/root/.npm/uglify-js 755
silly name, range, hasData 2 [ 'uglify-js', '>=1.0.7- <1.1.0-', true ]
silly versions [ 'uglify-js',
silly versions [ '0.0.1',
silly versions '0.0.2',
silly versions '0.0.3',
silly versions '0.0.4',
silly versions '0.0.5',
silly versions '1.0.1',
silly versions '1.0.2',
silly versions '1.0.3',
silly versions '1.0.4',
silly versions '1.0.5',
silly versions '1.0.6',
silly versions '1.0.7',
silly versions '1.1.0',
silly versions '1.1.1',
silly versions '1.2.0',
silly versions '1.2.1',
silly versions '1.2.2',
silly versions '1.2.3',
silly versions '1.2.4',
silly versions '1.2.5' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '2b7a10e628f88029a553d2b4bbb17409343755c0',
verbose bin dist tarball: 'http://registry.npmjs.org/uglify-js/-/uglify-js-1.0.7.tgz' } ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/uglify-js/-/uglify-js-1.0.7.tgz',
verbose addRemoteTarball '2b7a10e628f88029a553d2b4bbb17409343755c0' ]
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667711150-0.8715019102673978'
verbose mkdir done: /tmp/npm-1326667710786/1326667711150-0.8715019102673978 755
verbose fetch to /tmp/npm-1326667710786/1326667711150-0.8715019102673978/tmp.tgz
http GET https://registry.npmjs.org/uglify-js/-/uglify-js-1.0.7.tgz
http 200 https://registry.npmjs.org/underscore
silly get cb [ 200,
silly get cb { vary: 'Accept',
silly get cb server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"CCITUS2VKOUEBXVK4G1RPYTXH"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:31 GMT',
silly get cb 'content-type': 'application/json',
silly get cb 'content-length': '15578' } ]
verbose mkdir (expected) error ENOENT, No such file or directory '/var/root/.npm/underscore'
verbose mkdir done: /var/root/.npm/underscore 755
silly name, range, hasData 2 [ 'underscore', '>=1.2.4- <1.3.0-', true ]
silly versions [ 'underscore',
silly versions [ '1.0.3',
silly versions '1.0.4',
silly versions '1.1.0',
silly versions '1.1.1',
silly versions '1.1.2',
silly versions '1.1.3',
silly versions '1.1.4',
silly versions '1.1.5',
silly versions '1.1.6',
silly versions '1.1.7',
silly versions '1.2.0',
silly versions '1.2.1',
silly versions '1.2.2',
silly versions '1.2.3',
silly versions '1.2.4',
silly versions '1.3.0' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: 'e8da6241aa06f64df2473bb2590b8c17c84c3c7e',
verbose bin dist tarball: 'http://registry.npmjs.org/underscore/-/underscore-1.2.4.tgz' } ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/underscore/-/underscore-1.2.4.tgz',
verbose addRemoteTarball 'e8da6241aa06f64df2473bb2590b8c17c84c3c7e' ]
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667711195-0.8880158914253116'
verbose mkdir done: /tmp/npm-1326667710786/1326667711195-0.8880158914253116 755
verbose fetch to /tmp/npm-1326667710786/1326667711195-0.8880158914253116/tmp.tgz
http GET https://registry.npmjs.org/underscore/-/underscore-1.2.4.tgz
http 200 https://registry.npmjs.org/gzip-js
silly get cb [ 200,
silly get cb { vary: 'Accept',
silly get cb server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"1F67V3DYRKGNKXO6327F2SIWG"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:31 GMT',
silly get cb 'content-type': 'application/json',
silly get cb 'content-length': '4948' } ]
verbose mkdir (expected) error ENOENT, No such file or directory '/var/root/.npm/gzip-js'
verbose mkdir done: /var/root/.npm/gzip-js 755
http 304 https://registry.npmjs.org/handlebars/1.0.2beta
silly get cb [ 304,
silly get cb { server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"34UKO8IYOAYH8MYZ3EZBMV5DS"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:31 GMT',
silly get cb 'content-length': '0' } ]
verbose etag handlebars/1.0.2beta from cache
silly name, range, hasData 2 [ 'gzip-js', '>=0.3.1- <0.4.0-', true ]
silly versions [ 'gzip-js', [ '0.3.0', '0.3.1' ] ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '7a367c4d40921033010218a2740659db8caf2792',
verbose bin dist tarball: 'http://registry.npmjs.org/gzip-js/-/gzip-js-0.3.1.tgz' } ]
verbose bin dist [ '0.6-ares1.7.5-DEV-evundefined-openssl0.9.8r-v83.6.6.6-darwin-x64-11.2.0',
verbose bin dist { shasum: '533aa8755d1cd4ac616e48b9f77b9c98d0088a91',
verbose bin dist tarball: 'http://registry.npmjs.org/handlebars/-/handlebars-1.0.2beta.tgz' } ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/gzip-js/-/gzip-js-0.3.1.tgz',
verbose addRemoteTarball '7a367c4d40921033010218a2740659db8caf2792' ]
verbose addRemoteTarball [ 'https://registry.npmjs.org/handlebars/-/handlebars-1.0.2beta.tgz',
verbose addRemoteTarball '533aa8755d1cd4ac616e48b9f77b9c98d0088a91' ]
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667711252-0.78650869615376'
verbose mkdir (expected) error ENOENT, No such file or directory '/tmp/npm-1326667710786/1326667711252-0.9851873638108373'
verbose mkdir done: /tmp/npm-1326667710786/1326667711252-0.78650869615376 755
verbose mkdir done: /tmp/npm-1326667710786/1326667711252-0.9851873638108373 755
verbose fetch to /tmp/npm-1326667710786/1326667711252-0.78650869615376/tmp.tgz
verbose fetch to /tmp/npm-1326667710786/1326667711252-0.9851873638108373/tmp.tgz
http GET https://registry.npmjs.org/gzip-js/-/gzip-js-0.3.1.tgz
http GET https://registry.npmjs.org/handlebars/-/handlebars-1.0.2beta.tgz
http 304 https://registry.npmjs.org/glob-whatev
silly get cb [ 304,
silly get cb { server: 'CouchDB/1.1.0 (Erlang OTP/R14B04)',
silly get cb etag: '"B2RTW86TLK5E6WAWCXMWSUOC6"',
silly get cb date: 'Sun, 15 Jan 2012 22:48:31 GMT',
silly get cb 'content-length': '0' } ]
verbose etag glob-whatev from cache
silly name, range, hasData 2 [ 'glob-whatev', '>=0.1.0- <0.2.0-', true ]
silly versions [ 'glob-whatev', [] ]
verbose about to build /usr/local/lib/node_modules/grunt
ERR! error installing [email protected]
info unbuild /usr/local/lib/node_modules/grunt
verbose from cache /usr/local/lib/node_modules/grunt/package.json
info preuninstall [email protected]
info uninstall [email protected]
verbose unbuild [email protected] [ true,
verbose unbuild [email protected] '/usr/local/lib/node_modules',
verbose unbuild [email protected] '/usr/local/lib/node_modules' ]
verbose binRoot [ '/usr/local/bin', { grunt: 'bin/grunt' } ]
info postuninstall [email protected]
verbose installOne cb [email protected]
ERR! Error: No compatible version found: glob-whatev@'>=0.1.0- <0.2.0-'
ERR! No valid targets found.
ERR! Perhaps not compatible with your version of node?
ERR! at installTargetsError (/usr/local/lib/node_modules/npm/lib/cache.js:488:10)
ERR! at next
(/usr/local/lib/node_modules/npm/lib/cache.js:438:17)
ERR! at next (/usr/local/lib/node_modules/npm/lib/cache.js:415:44)
ERR! at /usr/local/lib/node_modules/npm/lib/cache.js:408:5
ERR! at Object.saved [as oncomplete] (/usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:147:7)
ERR! You may report this log at:
ERR! http://github.com/isaacs/npm/issues
ERR! or email it to:
ERR! [email protected]
ERR!
ERR! System Darwin 11.2.0
ERR! command "node" "/usr/local/bin/npm" "install" "-g" "grunt"
ERR! cwd /usr/local/bin
ERR! node -v v0.6.1-pre
ERR! npm -v 1.1.0
ERR! message No compatible version found: glob-whatev@'>=0.1.0- <0.2.0-'
ERR! message No valid targets found.
ERR! message Perhaps not compatible with your version of node?
verbose exit [ 1, true ]

Not sure where to go from here. Any advice would be appreciated. Thanks!

specifying default options to grunt.cli

This is useful when you want to use the CLI, but also provide default options.

var grunt = require("grunt");

grunt.cli({

  config: "build/config.js",

  tasks: ["build/tasks"]

});

Exclude files in config file (regular expression/wildcard) ?

Hi

Would it be possible to exclude certain files from certain tasks within the config file.

For example, I have a /js/libs/ folder which holds regular javascript libs as well as already minified scripts, so I would like to use something like this:

lint: { files: ["assets/js/libs/(*(^min).js"] },
Or something similar? Right now I have the option of using the * wildcart for all .js files, or using every filename specifically.

Thanks btw for this great tool!

grunt init can be smarter about bugs URL

If i enter http://github.com/paulirish/newsite/ as my "Project git repository " then

grunt should prompt me with http://github.com/paulirish/newsite/issues as a default issue tracker

Fix exit codes

I'm not sure if the failure to exit bug is caused by incorrect exit codes or not, this ticket can be updated accordingly

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.