[npm] scripts - npm cache clean -> bower cache clean

175 views
Skip to first unread message

Aaron Gray

unread,
Feb 1, 2015, 5:59:58 PM2/1/15
to nod...@googlegroups.com
Hi I have a :-

"scripts": {
"install": "cd public && bower install"
}

I wanted a :-

"scripts": {
...
"cache.clean": "cd public && bower cache clean"
},

but cannot work out how to specify it if it is allowed ?

any thanks in advance,

Aaron

Aria Stewart

unread,
Feb 1, 2015, 6:23:37 PM2/1/15
to nod...@googlegroups.com
There is no npm lifecycle script for cache clearing -- it's a global action, not related to your package at all. so, too, is the bower cache, I believe.

However, if you're needing to clear the cache, you've either found a bug in npm, or using an old version. I strongly suggest using the latest npm, clearing your cache after the upgrade, and then not doing that any more.

Aria

Aaron Gray

unread,
Feb 1, 2015, 9:06:30 PM2/1/15
to nod...@googlegroups.com
Thanks I was confusing clearing the cache with clearing out /
deleteing all node_modules and bower_component directories.
> --
> Job board: http://jobs.nodejs.org/
> New group rules: https://gist.github.com/othiym23/9886289#file-moderation-policy-md
> Old group rules: https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
> ---
> You received this message because you are subscribed to the Google Groups "nodejs" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to nodejs+un...@googlegroups.com.
> To post to this group, send email to nod...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/nodejs/80C64610-6418-43B0-A69A-08DFFAB23100%40dinhe.net.
> For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages