npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

mission

v0.0.9

Published

Common used tasks in Web development

Downloads

43

Readme

Mission: common tasks in Web development

Bundled tasks for developing single page apps.

Usage

npm install --save-dev mission shelljs

Config in CoffeeScript or JavaScript:

#!/usr/bin/env coffee
require 'shelljs/make'

mission = require 'mission'

target.coffee = ->
  mission.coffee
    from: 'src/'
    files: ['a.coffee', 'dir/b.coffee']
    to: 'lib/'
    options:
      bare: yes

Here's mine: https://github.com/jiyinyiyong/mk/blob/master/make.coffee

Run it like this:

chmod +x make.coffee
./make.coffee coffee

or like me:

alias mk='coffee make.coffee'
mk coffee

Other configurations

Say if you want to compile only one file:

target.coffee = ->
  mission.coffee
    file: 'a.coffee'
    from: 'src/'
    to: 'lib/'
    options:
      bare: yes

Or you may need to find some files that are deep in folders:

target.coffee = ->
  mission.coffee
    find: /\.coffee$/
    from: 'src/'
    to: 'lib/'
    options:
      bare: yes

from and to are optional, you mat only need to write file sometimes:

target.coffee = ->
  mission.watch
    file: 'dir'
    trigger: (filename, extname) ->

Usage

  • tree: creates file tree

  • bump: bump version with semver.

  • uglify: minify JavaScript code

  • coffee: compile CoffeeScript to JavaScript, with sourceMap support

  • watch: watch directories, callback filenames and extnames

  • time: log the time it cost

  • realod: reload tab with devtools-reloader-station

  • browserify: combine JavaScript code on CommonJS

  • browserifyVender: helper for browserify to generate vender.js

  • cssmin: combine CSS files and minify code

  • dot: precompile dot files to JavaScript

  • jade: compile Jade to HTML

  • less: compile LESS to CSS

SourceMap is enabled by default, and here I have to use command line. Related to: https://github.com/less/less.js/issues/1985 Anyway, mission.less needs to be updated in the future.

  • rsync: run Rsync with some default configs

  • copy: copy files and directories

  • wait: wait chan.done = false to be true and run task

  • cirruHtml compile Cirru HTML

  • cirruHtmlJs compile Cirru to template in JavaScript(not tested)

Notice

Asynchronous callings are hard to handle in ShellJS. In this angle, Grunt did a good job in sequencing tasks.

But you can try wait to reduce the pain. mission would keep watching .done and run task when it's true.

target.test = ->
  a = done: no
  mission.wait a, ->
    console.log 'finish task'

  setTimeout ->
    a.done = yes
  , 2000

Development

Compile *.coffee:

./make.coffee compile

Changelog

  • 0.0.8

    • add external option for browserify

    • add browserifyVender task for multiple bundling

  • 0.0.7

    • Add cirruHtmlJs and rename cirruHtml
  • 0.0.6

    • Updated Cirru HTML to fix double quote in attributes
  • 0.0.5

    • Added sourceMap support
  • 0.0.4

    • Added flexibility and some default options to rsync

License

MIT