Skip to content

Commit

Permalink
Merge pull request #100 from deinsoftware/dev
Browse files Browse the repository at this point in the history
feat: 🐛 revert location global
  • Loading branch information
equiman authored Dec 26, 2023
2 parents 31cd323 + b4d65fe commit 2f773ba
Show file tree
Hide file tree
Showing 16 changed files with 1,145 additions and 756 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ jobs:

- name: Get package info
id: package
uses: codex-team/action-nodejs-package-info@v1
uses: kylejrp/action-nodejs-package-info@v1.2

- name: Analyze with SonarCloud
uses: sonarsource/sonarcloud-github-action@master
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ jobs:
if: ${{ !github.event.repository.private }}
with:
tweet-message: "swpm ${{ github.event.release.tag_name }} 🐛🔨 is here 🥳\n\n
$ npm install swpm@latest --location=global\n\n
$ npm install swpm@latest --global\n\n
#swpm #cli #npm #yarn #pnpm #bun #nodejs #javascript #typescript\n\n
https://github.com/deinsoftware/swpm/blob/main/CHANGELOG.md"
env:
Expand Down
5 changes: 3 additions & 2 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
"esnext",
"github",
"gitlab",
"kylejrp",
"lcov",
"linux",
"lockb",
Expand Down Expand Up @@ -73,8 +74,8 @@
"editor.defaultFormatter": "dbaeumer.vscode-eslint",
"editor.formatOnSave": false,
"editor.codeActionsOnSave": {
"source.formatDocument": true,
"source.fixAll.eslint": true
"source.formatDocument": "explicit",
"source.fixAll.eslint": "explicit"
},
},
"explorer.fileNesting.patterns": {
Expand Down
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,16 @@ Fixed for any bug fixes.
Security to invite users to upgrade in case of vulnerabilities.
-->

## 2.6.0 - 2023/12/26

### Changed

- Revert the `--location=global` flag translation on npm, [the warning message was fixed and deprecated](https://github.com/npm/statusboard/issues/518)

### Updated

- Bump package versions

## 2.5.2 - 2023/10/31

## Fixed
Expand Down
12 changes: 6 additions & 6 deletions CHEATSHEET.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,21 @@ This is a cheat sheet that you can use as a handy reference for [npm](https://ww
| [x] | don't read or generate a lockfile | `swpm install --package-lock` | `npm install --no-package-lock` | `yarn install --no-lockfile` | `yarn install --no-lockfile` | N/A | `bun install --no-save` |
| [ ] | don't generate a lockfile | | | `yarn install --pure-lockfile` | `yarn install --pure-lockfile` | | N/A |
| [x] | lockfile is not updated | `swpm install --frozen` | `npm ci` | `yarn install --frozen-lockfile` | `yarn install --immutable` | `pnpm install --frozen-lockfile` | `bun install --frozen-lockfile` |
| [x] | add package | `swpm add <package> [--global]` | `npm install <package> [--location=global]` | `yarn [global] add <package>` | `yarn [global] add <package>` | `pnpm add <package> [--global]` | `bun add <package> [--global]` |
| [x] | add package | `swpm add <package> [--global]` | `npm install <package> [--global]` | `yarn [global] add <package>` | `yarn [global] add <package>` | `pnpm add <package> [--global]` | `bun add <package> [--global]` |
| [x] | add package as `dependencies` | `swpm add <package>` | `npm install <package>` | `yarn add <package>` | `yarn add <package>` | `pnpm add <package>` | `bun add <package>` |
| [x] | add package as `devDependencies` | `swpm add <package> --save-dev` | `npm install <package> --save-dev` | `yarn add <package> --dev` | `yarn add <package> --dev` | `pnpm add <package> --save-dev` | `bun add <package> --dev` |
| [x] | add package as `optionalDependencies` | `swpm add <package> --save-optional` | `npm install <package> --save-optional` | `yarn add <package> --optional` | `yarn add <package> --optional` | `pnpm add <package> --save-optional` | `bun add <package> --optional` |
| [x] | add package as `peerDependencies` | `swpm add <package> --save-peer` | `npm install <package> --save-peer` | `yarn add <package> --peer` | `yarn add <package> --peer` | `pnpm add <package> --save-peer` | N/A |
| [x] | add exact version | `swpm add <package> --save-exact` | `npm install <package> --save-exact` | `yarn add <package> --exact` | `yarn add <package> --exact` | `pnpm add <package> --save-exact` | `bun add <package> --exact` |
| [x] | remove package | `swpm remove [<package>] [--global]` | `npm uninstall <package> [--location=global]` | `yarn [global] remove <package>` | `yarn [global] remove <package>` | `pnpm uninstall <package> [--global]` | `bun remove [<package>] [--global]` |
| [x] | remove package | `swpm remove [<package>] [--global]` | `npm uninstall <package> [--global]` | `yarn [global] remove <package>` | `yarn [global] remove <package>` | `pnpm uninstall <package> [--global]` | `bun remove [<package>] [--global]` |
| [x] | remove package as `dependencies` | `swpm remove <package>` | `npm uninstall <package>` | `yarn remove <package>` | `yarn remove <package>` | `pnpm uninstall <package>` | `bun remove <package>` |
| [x] | remove package as `devDependencies` | `swpm remove <package> --save-dev` | `npm uninstall <package> --save-dev` | `yarn remove <package> --dev` | `yarn remove <package> --dev` | `pnpm uninstall <package> --save-dev` | `bun remove <package> --dev` |
| [x] | remove package as `optionalDependencies` | `swpm remove <package> --save-optional` | `npm uninstall <package> --save-optional` | `yarn remove <package> --optional` | `yarn remove <package> --optional` | `pnpm uninstall <package> --save-optional` | `bun remove <package> --optional` |
| [x] | remove package as `peerDependencies` | `swpm remove <package> --save-peer` | `npm uninstall <package> --save-peer` | `yarn remove <package> --peer` | `yarn remove <package> --peer` | `pnpm uninstall <package> --save-peer` | N/A |
| [x] | update package (no `package.json`) | `swpm update [<package>] [--global]` | `npm update [<package>] [--location=global]` | `yarn [global] upgrade [<package>]` | `yarn [global] semver up [<package>]` | `pnpm update [<package>] [--global]` | N/A |
| [x] | upgrade package on `package.json` | `swpm upgrade <package> [--global]` | `npm add <package>@latest [--location=global]` | `yarn [global] upgrade <package> --latest` | `yarn [global] up <package>` | `pnpm update <package> --latest [--global]` | N/A |
| [x] | update package (no `package.json`) | `swpm update [<package>] [--global]` | `npm update [<package>] [--global]` | `yarn [global] upgrade [<package>]` | `yarn [global] semver up [<package>]` | `pnpm update [<package>] [--global]` | N/A |
| [x] | upgrade package on `package.json` | `swpm upgrade <package> [--global]` | `npm add <package>@latest [--global]` | `yarn [global] upgrade <package> --latest` | `yarn [global] up <package>` | `pnpm update <package> --latest [--global]` | N/A |
| [x] | upgrade interactive | `swpm interactive` | N/A | `yarn upgrade-interactive` | `yarn upgrade-interactive` | `pnpm upgrade --interactive` | N/A |
| [ ] | list all package at the top level | | `npm list --depth 0 [--location=global]` | `yarn [global] list --depth 0` | `yarn [global] list --depth 0` | `pnpm list --depth 0 [--global]` | `bun pm ls` |
| [ ] | list all package at the top level | | `npm list --depth 0 [--global]` | `yarn [global] list --depth 0` | `yarn [global] list --depth 0` | `pnpm list --depth 0 [--global]` | `bun pm ls` |
| [ ] | audit vulnerable dependencies | | `npm audit [fix]` | `yarn audit` | `yarn audit` | `pnpm audit [--fix]` | |

## Shared Commands
Expand All @@ -47,7 +47,7 @@ Use the same command structure between package managers.
| [x] | config list | `swpm config list` | `npm config list` | `yarn config list` | `yarn config list` | `pnpm config list` | TBA |
| [x] | config `--save-default` as default | `swpm config set save-exact true` | `npm config set save-exact true` | `yarn config set save-exact true` | `yarn config set save-exact true` | `pnpm config set save-exact true` | TBA |
| [x] | config `~` as default instead `^` | `swpm config set save-prefix '~'` | `npm config set save-prefix '~'` | `yarn config set save-prefix '~'` | `yarn config set save-prefix '~'` | `pnpm config set save-prefix '~'` | TBA |
| [x] | list outdated packages | `swpm outdated [<package>] [--global]` | `npm outdated [<package>] [--location=global]` | `yarn [global] [<package>] outdated` | `yarn [global] [<package>] upgrade-interactive` | `pnpm outdated [<package>] [--global]` | TBA |
| [x] | list outdated packages | `swpm outdated [<package>] [--global]` | `npm outdated [<package>] [--global]` | `yarn [global] [<package>] outdated` | `yarn [global] [<package>] upgrade-interactive` | `pnpm outdated [<package>] [--global]` | TBA |
| [x] | link local package | `swpm link` | `npm link [<folder>]` | `yarn link [<folder>]` | `yarn link [<folder>]` | `pnpm link [<folder>]` | `bun link [<folder>]` |
| [x] | unlink local package | `swpm unlink` | `npm unlink [<folder\|package> --no-save]` | `yarn unlink [<folder\|package>]` | `yarn unlink [<folder\|package>]` | `pnpm unlink [<folder\|package>]` | `bun unlink [<folder\|package>]` |

Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ Install as global with any of this package managers

| Package Manager | Install Command |
| --------------- | ------------------------------------ |
| **npm** | `npm install swpm --location=global` |
| **npm** | `npm install swpm --global` |
| **yarn** | `yarn global add swpm` |
| **pnpm** | `pnpm install swpm --global` |
| **bun** | `bun install -g swpm` |
Expand Down Expand Up @@ -509,7 +509,7 @@ Quick and short aliases for `swpm` and `swpx` commands.

| Package/Alias | `sag <package>` | `sag eslint` |
| -------------- | -------------------------------------- | ----------------------------------- |
| **npm** | `npm add <package> --location=global` | `npm add eslint --location=global` |
| **npm** | `npm add <package> --global` | `npm add eslint --global` |
| **yarn** | `yarn add global <package>` | `yarn add global eslint` |
| **pnpm** | `pnpm add <package> --global` | `pnpm add eslint --global` |
| **bun** | `bun add <package> --global` | `bun add eslint --global` |
Expand All @@ -528,7 +528,7 @@ Quick and short aliases for `swpm` and `swpx` commands.

| Package/Alias | `srg <package>` | `srg eslint` |
| -------------- | -------------------------------------------- | ----------------------------------------- |
| **npm** | `npm uninstall <package> --location=global` | `npm uninstall eslint --location=global` |
| **npm** | `npm uninstall <package> --global` | `npm uninstall eslint --global` |
| **yarn** | `yarn remove global <package>` | `yarn remove global eslint` |
| **pnpm** | `pnpm uninstall <package> --global` | `pnpm uninstall eslint --global` |
| **bun** | `bun remove <package> --global` | `bun remove eslint --global` |
Expand All @@ -548,7 +548,7 @@ Quick and short aliases for `swpm` and `swpx` commands.

| Package/Alias | `sug <package>` | `sug vite` |
| -------------- | --------------------------------- | ---------------------------- |
| **npm** | `npm add <package>@latest` | `npm add vite@latest` |
| **npm** | `npm add <package>@latest` | `npm add vite@latest` |
| **yarn** | `yarn upgrade <package> --latest` | `yarn upgrade vite --latest` |
| **yarn@berry** | `yarn up <package>` | `yarn up vite` |
| **pnpm** | `pnpm update <package> --latest` | `pnpm update vite --latest` |
Expand Down
4 changes: 2 additions & 2 deletions TEMPLATES.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,8 @@ Example

```JavaScript
args: {
'--global': '--location=global',
'-g': '--location=global',
'--save-dev': '--dev',
'-D': '-d',
}
```

Expand Down
Loading

0 comments on commit 2f773ba

Please sign in to comment.