{"id":13623949,"url":"https://github.com/ralphtheninja/mkstack","last_synced_at":"2025-08-20T22:38:37.510Z","repository":{"id":26414165,"uuid":"29864272","full_name":"ralphtheninja/mkstack","owner":"ralphtheninja","description":"Create and apply your favorite npm stacks.","archived":false,"fork":false,"pushed_at":"2018-06-24T10:16:14.000Z","size":33,"stargazers_count":26,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-12-27T17:39:38.314Z","etag":null,"topics":["devops","javascript","npm","stacks"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ralphtheninja.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}},"created_at":"2015-01-26T14:23:45.000Z","updated_at":"2023-05-23T03:14:02.000Z","dependencies_parsed_at":"2022-08-26T18:12:42.840Z","dependency_job_id":null,"html_url":"https://github.com/ralphtheninja/mkstack","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ralphtheninja%2Fmkstack","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ralphtheninja%2Fmkstack/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ralphtheninja%2Fmkstack/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ralphtheninja%2Fmkstack/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ralphtheninja","download_url":"https://codeload.github.com/ralphtheninja/mkstack/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":232028811,"owners_count":18462508,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["devops","javascript","npm","stacks"],"created_at":"2024-08-01T21:01:37.238Z","updated_at":"2024-12-31T20:56:49.431Z","avatar_url":"https://github.com/ralphtheninja.png","language":"JavaScript","readme":"# mkstack\n\n\u003e Create and apply your favorite npm stacks.\n\n[![npm](https://img.shields.io/npm/v/mkstack.svg)](https://www.npmjs.com/package/mkstack)\n![Node version](https://img.shields.io/node/v/mkstack.svg)\n[![Build Status](https://travis-ci.org/ralphtheninja/mkstack.svg?branch=master)](https://travis-ci.org/ralphtheninja/mkstack)\n[![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)\n\n## Install\n\n```\n$ npm install mkstack -g\n```\n\n## Usage\n\n#### Create a stack\n\n`$ mkstack -c|--create :id`\n\nLets setup a web stack. We need `browserify` and some other stuff.\n\n```\n$ mkdir ~/new-web-project \u0026\u0026 cd ~/new-web-project \u0026\u0026 npm init --yes\n$ npm i browserify --save\n$ npm i shoe --save --save-exact\n$ npm i send --save --save-exact\n$ npm i node-sass --save\n$ npm i tape --save-dev\n$ npm i nodemon --save-dev --save-exact\n```\n\nSave it.\n\n```\n$ mkstack -c web\nCreated web\n```\n\n#### Apply stack(s)\n\n`$ mkstack -a|--apply :ids [-y|--yarn]`\n\nTime for a new web project. Create a new folder and apply the previously saved stack. This will do:\n\n* `npm i :project --save` for all `dependencies`\n* `npm i :project --save-dev` for all `devDependencies`.\n\n*Use -y or --yarn if you want to use yarn instead of npm*\n\n```\n$ mkdir ~/next-project \u0026\u0026 cd ~/next-project \u0026\u0026 npm init --yes\n$ mkstack -a web\nApplying web\n..\n```\n\nIf you create your stack abstractions well you can combine them. Perhaps you want a `test` stack that contains your favorite test modules, e.g. `tape`, `chai`, `phantomjs` etc.\n\nNote that the order of the stacks are important since npm will save `package.json` each time and update in the order the stacks are applied.\n\n```\n$ mkstack -a web\n$ mkstack -a sockets\n$ mkstack -a tcp-server\n$ mkstack -a irc2\n$ mkstack -a console\n```\n\nOr use a comma separated list. This is more optimal since the dependency configuration will be merged before doing `npm install` to avoid installing modules multiple times to save time.\n\n```\n$ mkstack -a web,sockets,tcp-server,irc2,console\nApplying web,sockets,tcp-server,irc2,console\n..\n```\n\n#### List stacks\n\n`$ mkstack -l|--list`\n\nList your saved stacks with the `-l` flag. Note that `mkstack` does not have any opinions on version numbers. It just saves them as you specified them the first time.\n\n```\n$ mkstack -l\n{\n  \"web\": {\n    \"dependencies\": {\n      \"browserify\": \"^8.1.1\",\n      \"node-sass\": \"^2.0.0-beta\",\n      \"send\": \"0.11.1\",\n      \"shoe\": \"0.0.15\"\n    },\n    \"devDependencies\": {\n      \"nodemon\": \"1.3.2\",\n      \"tape\": \"^3.4.0\"\n    }\n  }\n}\n```\n\n#### Remove stack\n\n`$ mkstack --rm :id`\n\n```\n$ mkstack --rm web\nRemoved web\n$ mkstack -l\nNo stacks found\n```\n\n## Config\n\n`mkstack` uses [`rc`](https://github.com/dominictarr/rc). Default path for current config file is `~/.mkstackrc` but that can be changed by using the `--config` flag:\n\n```\n$ mkstack -c websockets --config ~/path/to/my/stacks\n```\n\n## License\n\n[GPL-3.0](LICENSE) © 2018-present Lars-Magnus Skog.\n","funding_links":[],"categories":["JavaScript"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fralphtheninja%2Fmkstack","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fralphtheninja%2Fmkstack","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fralphtheninja%2Fmkstack/lists"}