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 🙏

© 2024 – Pkg Stats / Ryan Hefner

xd-build

v0.4.2

Published

build the standard cmd module

Downloads

7

Readme

spm-build

the build tools for spmjs.org


spm build is designed to build standard cmd modules.

自定义构建,请不要用这个库,除非你清楚自己在做什么!

Customized building should use these grunt tasks:

  • https://github.com/spmjs/grunt-cmd-transport
  • https://github.com/spmjs/grunt-cmd-concat

Standard Module

A standard module contains:

  • a package.json
  • a src directory
  • a dist directory
package.json
src/
  module-name.js
dist/
  module-name.js   <-- will be created by spm-build

Learn more on package.json.

Install

Install spm-build with npm:

$ npm install [email protected] -g

此插件适用于 [email protected] 版本,spm3 已自带构建,无须安装插件。

API

var builder = require('spm-build')

builder.loadTasks()

It will load all tasks of the default build. Including:

  • grunt-cmd-transport
  • grunt-cmd-concat
  • grunt-contrib-uglify
  • grunt-contrib-copy
  • grunt-contrib-cssmin
  • grunt-contrib-clean
  • spm-install
  • spm-newline

If you are using spm-build to run the grunt task, you can also load these tasks with:

grunt.loadGlobalTasks('spm-build')

Changelog

Feb 15th, 2015 0.4.1

filter the files that not matched by spm.output

Sep 9th, 2014 0.4.0

Remove running scripts in package.json

Oct 11th, 2013 0.3.19

just warn when output not found

Sep 3rd, 2013 0.3.18

output support *

Jan 24th, 2013 0.3.13

Lock grunt-contrib-uglify's version to avoid uglify-js being update to high version.

Sep 5th, 2013 0.3.10

Update dependencies

Aug 15, 2013 0.3.9

Fix #34

Aug 15, 2013 0.3.8

Update dependencies

Jul 30, 2013 0.3.7

export parseOptions

Jun 26, 2013 0.3.6

support styleBox option

Jun 25, 2013 0.3.5

  • support include config
  • install will throw exception

Jun 24, 2013 0.3.4

  • force option for spm.install
  • output support for object

Jun 18, 2013 0.3.3

  • Update dependencies

Jun 03, 2013 0.3.2

  • Fix source option in package.json
  • Update dependencies

May 21, 2013 0.3.1

  • Pass options from command line to config

May 5, 2013 0.3.0

  • Update dependencies.
  • Fix on options, -I, -O.

April 23, 2013 0.2.0

  • Fix on commander options.
  • Add --include option for build.

April 23, 2013 0.1.2

  • Update dependencies.
  • Show error on postinstall scripts.

April 16, 2013 0.1.1

Update dependencies.

April 15, 2013 0.1.0

First version.