{"id":36501398,"url":"https://github.com/nelsyeung/usemin-cli","last_synced_at":"2026-01-12T02:22:02.362Z","repository":{"id":34109859,"uuid":"37938647","full_name":"nelsyeung/usemin-cli","owner":"nelsyeung","description":"Replaces references to non-optimized scripts or stylesheets into a set of HTML files (or any templates/views)","archived":false,"fork":false,"pushed_at":"2023-04-16T15:19:15.000Z","size":305,"stargazers_count":23,"open_issues_count":3,"forks_count":9,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-19T08:36:38.610Z","etag":null,"topics":["build-tool","cli","html","javascript","nodejs","usemin","usemin-cli"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nelsyeung.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-06-23T18:56:46.000Z","updated_at":"2022-02-20T20:20:34.000Z","dependencies_parsed_at":"2024-06-18T21:44:39.532Z","dependency_job_id":null,"html_url":"https://github.com/nelsyeung/usemin-cli","commit_stats":{"total_commits":37,"total_committers":5,"mean_commits":7.4,"dds":"0.29729729729729726","last_synced_commit":"2c5a9fec6be201ec4c3641c7df69b342db59f23c"},"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"purl":"pkg:github/nelsyeung/usemin-cli","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nelsyeung%2Fusemin-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nelsyeung%2Fusemin-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nelsyeung%2Fusemin-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nelsyeung%2Fusemin-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nelsyeung","download_url":"https://codeload.github.com/nelsyeung/usemin-cli/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nelsyeung%2Fusemin-cli/sbom","scorecard":{"id":679245,"data":{"date":"2025-08-11","repo":{"name":"github.com/nelsyeung/usemin-cli","commit":"2c5a9fec6be201ec4c3641c7df69b342db59f23c"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.7,"checks":[{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 0/15 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 16 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"11 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-pfq8-rq6v-vf5m","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7","Warn: Project is vulnerable to: GHSA-p9pc-299p-vxgp"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-21T22:34:02.813Z","repository_id":34109859,"created_at":"2025-08-21T22:34:02.813Z","updated_at":"2025-08-21T22:34:02.813Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28332033,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-12T00:36:25.062Z","status":"online","status_checked_at":"2026-01-12T02:00:08.677Z","response_time":98,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["build-tool","cli","html","javascript","nodejs","usemin","usemin-cli"],"created_at":"2026-01-12T02:22:00.011Z","updated_at":"2026-01-12T02:22:02.356Z","avatar_url":"https://github.com/nelsyeung.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# usemin-cli \n\n[![Build Status](https://travis-ci.org/nelsyeung/usemin.svg?branch=master)](https://travis-ci.org/nelsyeung/usemin)\n[![NPM Version](https://img.shields.io/npm/v/usemin-cli.svg)](https://www.npmjs.com/package/usemin-cli)\n[![Downloads per Month](https://img.shields.io/npm/dm/usemin-cli.svg)](https://www.npmjs.com/package/usemin-cli)\n\n\u003e CLI version of usemin. For _purists_, those who don't use build tools like [Grunt](https://github.com/yeoman/grunt-usemin) and [Gulp](https://github.com/zont/gulp-usemin), but just use NPM as their build tool.\n\n## Getting started\n\nInstall with npm:\n```\nnpm install usemin-cli\n```\n\n## API\n[usemin](https://github.com/nelsyeung/usemin) - API for this module.\n\n## Usage\n\n```\nusemin [input.html] [--dest|-d dir] [--output|-o output.html] [options]\n```\n### Example commands\n```\nusemin src/index.html --dest dist --output dist/index.html\nusemin src/index.html -d dist -o dist/index.html\nusemin src/index.html -d dist \u003e dist/index.html\nusemin src/index.html -d dist -o dist/index.html --htmlmin true --rmlr true\nusemin src/index.html -d dist -o dist/index.html --htmlmin true -c config.js\n```\n\n### Available options\n```\n--htmlmin - Also minifies the input HTML file (Boolean)\n--rmlr, --removeLivereload - Remove livereload script (Boolean)\n--noprocess - Do not process files, just replace references (Boolean)\n-c, --config - Supply a configurations file for UglifyJS, CleanCSS and HTML minifier.\n--listblocks - Write blocks to stdout or filename.json.\n               E.g., --listblocks // print to stdout\n                     --listblocks blocks.json // write to blocks.json\n```\n\n### Example HTML\n#### Blocks\nBlocks are expressed as:\n```html\n\u003c!-- build:\u003cpipelineId\u003e(alternate search path) \u003cpath\u003e --\u003e\n... HTML Markup, list of script / link tags.\n\u003c!-- endbuild --\u003e\n```\n\n- **pipelineId**: pipeline id for options or remove to remove a section\n- **alternate search path**: (optional) By default the input files are relative to the treated file. Alternate search path allows one to change that\n- **path**: the file path of the optimized file, the target output\n\n```html\n\u003c!-- build:css css/main.js --\u003e\n\u003clink rel=\"stylesheet\" href=\"css/main.css\"\u003e\n\u003clink rel=\"stylesheet\" href=\"css/modules.css\"\u003e\n\u003c!-- endbuild --\u003e\n\n\u003c!-- build:js js/main.js --\u003e\n\u003cscript src=\"js/app.js\"\u003e\u003c/script\u003e\n\u003cscript src=\"js/controllers.js\"\u003e\u003c/script\u003e\n\u003c!-- endbuild --\u003e\n\n\u003c!-- build:js js/main.js --\u003e\n\u003cscript defer async src=\"js/app.js\"\u003e\u003c/script\u003e\n\u003cscript defer async src=\"js/controllers.js\"\u003e\u003c/script\u003e\n\u003c!-- endbuild --\u003e\n\n\u003c!-- build:remove --\u003e\n\u003cscript src=\"js/app.js\"\u003e\u003c/script\u003e\n\u003cscript src=\"js/controllers.js\"\u003e\u003c/script\u003e\n\u003c!-- endbuild --\u003e\n\n\u003cscript\u003edocument.write('\u003cscript src=\"http://' + (location.host || 'localhost').split(':')[0] + ':35729/livereload.js?snipver=1\"\u003e\u003c/' + 'script\u003e')\u003c/script\u003e\n```\nRunning the command with `--rmlr true` will output:\n```\n\u003clink rel=\"stylesheet\" href=\"css/main.js\"\u003e\n\u003cscript src=\"js/main.js\"\u003e\u003c/script\u003e\n\u003cscript defer async src=\"js/main.js\"\u003e\u003c/script\u003e\n```\n\n#### Alternate search path\n```html\n\u003c!-- build:js(js) js/main.js --\u003e\n\u003cscript defer async src=\"app.js\"\u003e\u003c/script\u003e\n\u003cscript defer async src=\"controllers.js\"\u003e\u003c/script\u003e\n\u003c!-- endbuild --\u003e\n\n\u003c!-- build:js(js,.tmp) js/main.js --\u003e\n\u003cscript defer async src=\"app.js\"\u003e\u003c/script\u003e\n\u003cscript defer async src=\"controllers.js\"\u003e\u003c/script\u003e\n\u003c!-- endbuild --\u003e\n```\n\n### Config file\n\nPlease check the relevant documentations for the available options: [ UglifyJS](https://github.com/mishoo/UglifyJS2), [CleanCSS](https://github.com/jakubpawlowicz/clean-css) and [HTML minifier](https://github.com/kangax/html-minifier).\n\n```JavaScript\nmodule.exports = {\n\tuglifyjs: {\n\t\t// ... UglifyJS API options\n\t},\n\tcleancss: {\n\t\t// ... CleanCSS API options\n\t},\n\thtmlminifier: {\n\t\t// ... HTML minifier API options\n\t}\n}\n```\n\n## License\n\n[MIT license](http://opensource.org/licenses/MIT.php)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnelsyeung%2Fusemin-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnelsyeung%2Fusemin-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnelsyeung%2Fusemin-cli/lists"}