Socket
Socket
Sign inDemoInstall

@antfu/ni

Package Overview
Dependencies
4
Maintainers
1
Versions
69
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.3.0 to 0.4.0

bin/nu.js

8

dist/nci.js
"use strict";
var _chunk22K7G76Djs = require('./chunk.22K7G76D.js');
var _chunkVZ7Z3SSIjs = require('./chunk.VZ7Z3SSI.js');
var _chunkVED3VBGLjs = require('./chunk.VED3VBGL.js');
var _chunk6QJ5NK4Cjs = require('./chunk.6QJ5NK4C.js');
// src/nci.ts
_chunkVED3VBGLjs.run.call(void 0, async (agent, _, hasLock) => {
return _chunk22K7G76Djs.parseNi.call(void 0, agent, ["--frozen-if-present"], hasLock);
_chunk6QJ5NK4Cjs.run.call(void 0, async (agent, _, hasLock) => {
return _chunkVZ7Z3SSIjs.parseNi.call(void 0, agent, ["--frozen-if-present"], hasLock);
}, {autoInstall: true});
"use strict";
var _chunk22K7G76Djs = require('./chunk.22K7G76D.js');
var _chunkVZ7Z3SSIjs = require('./chunk.VZ7Z3SSI.js');
var _chunkVED3VBGLjs = require('./chunk.VED3VBGL.js');
var _chunk6QJ5NK4Cjs = require('./chunk.6QJ5NK4C.js');
// src/ni.ts
_chunkVED3VBGLjs.run.call(void 0, async (agent, args, hasLock) => {
return _chunk22K7G76Djs.parseNi.call(void 0, agent, args, hasLock);
_chunk6QJ5NK4Cjs.run.call(void 0, async (agent, args, hasLock) => {
return _chunkVZ7Z3SSIjs.parseNi.call(void 0, agent, args, hasLock);
});
"use strict"; function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
var _chunkVED3VBGLjs = require('./chunk.VED3VBGL.js');
var _chunk6QJ5NK4Cjs = require('./chunk.6QJ5NK4C.js');
// src/nr.ts
var _inquirer = require('inquirer'); var _inquirer2 = _interopRequireDefault(_inquirer);
// src/commands.ts

@@ -10,3 +13,3 @@ function parseNr(agent, args) {

args.push("start");
return _chunkVED3VBGLjs.getCommand.call(void 0, agent, "run", args);
return _chunk6QJ5NK4Cjs.getCommand.call(void 0, agent, "run", args);
}

@@ -18,6 +21,6 @@

function getPackageJSON() {
const path2 = _path.resolve.call(void 0, process.cwd(), "package.json");
if (_fs2.default.existsSync(path2)) {
const path = _path.resolve.call(void 0, process.cwd(), "package.json");
if (_fs2.default.existsSync(path)) {
try {
const raw = _fs2.default.readFileSync(path2, "utf-8");
const raw = _fs2.default.readFileSync(path, "utf-8");
const data = JSON.parse(raw);

@@ -33,4 +36,3 @@ return data;

// src/nr.ts
var _inquirer = require('inquirer'); var _inquirer2 = _interopRequireDefault(_inquirer);
_chunkVED3VBGLjs.run.call(void 0, async (agent, args) => {
_chunk6QJ5NK4Cjs.run.call(void 0, async (agent, args) => {
if (args.length === 0) {

@@ -37,0 +39,0 @@ const scripts = getPackageJSON().scripts || {};

{
"name": "@antfu/ni",
"version": "0.3.0",
"version": "0.4.0",
"description": "Use the right package manager",

@@ -10,3 +10,4 @@ "author": "Anthony Fu <anthonyfu117@hotmail.com>",

"nci": "bin/nci.js",
"nr": "bin/nr.js"
"nr": "bin/nr.js",
"nu": "bin/nu.js"
},

@@ -31,6 +32,7 @@ "bugs": {

"nr": "esno src/nr.ts",
"nu": "esno src/nu.ts",
"dev": "esno src/ni.ts",
"build": "tsup src/ni.ts src/nci.ts src/nr.ts --format cjs,esm --dts",
"release": "npx bumpp --commit --push --tag && npm publish --access public",
"lint": "eslint \"{src,test}/**/*.ts\"",
"lint": "eslint \"**/*.ts\"",
"lint:fix": "npm run lint -- --fix",

@@ -41,3 +43,3 @@ "test": "c8 ava"

"find-up": "^5.0.0",
"ini": "^1.3.5",
"ini": "^1.3.8",
"inquirer": "^7.3.3",

@@ -50,26 +52,13 @@ "terminal-link": "^2.1.1"

"@types/inquirer": "^7.3.1",
"@types/node": "^14.14.6",
"ava": "^3.13.0",
"c8": "^7.3.3",
"esbuild-register": "^1.0.2",
"eslint": "^7.11.0",
"@types/node": "^14.14.20",
"ava": "^3.15.0",
"c8": "^7.4.0",
"esbuild-register": "^1.2.1",
"eslint": "^7.17.0",
"esm": "^3.2.25",
"esno": "^0.2.4",
"husky": "^4.3.0",
"lint-staged": "^10.5.1",
"rimraf": "^3.0.2",
"tsup": "^3.7.1",
"typescript": "^4.0.5"
"tsup": "^3.11.0",
"typescript": "^4.1.3"
},
"husky": {
"hooks": {
"pre-commit": "lint-staged"
}
},
"lint-staged": {
"*.{ts,js}": [
"eslint --fix",
"git add"
]
},
"eslintConfig": {

@@ -76,0 +65,0 @@ "extends": "@antfu/eslint-config-ts"

@@ -82,2 +82,21 @@ # ni

### `nu` - upgrade
```bash
nu
# npm upgrade
# yarn upgrade
# pnpm upgrade
```
```bash
nu -i
# (not available for npm)
# yarn upgrade-interactive
# pnpm upgrade -i
```
### `nci` - clean install

@@ -102,5 +121,7 @@

; default agent will be used for global installs
; and the fallback when no lock found.
defaultAgent=npm
; fallback when no lock found
defaultAgent=npm # default "prompt"
; for global installs
globalAgent=npm
```

@@ -107,0 +128,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc