New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details
Socket
Book a DemoSign in
Socket

dext-cli

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dext-cli - npm Package Compare versions

Comparing version
0.1.2
to
0.2.0
+9
-3
.editorconfig
root = true
# default
[*]
charset = utf-8
end_of_line = lf
indent_size = 2
indent_style = space
insert_final_newline = true
charset = utf-8
indent_style = space
indent_size = 2
trim_trailing_whitespace = true
# .md files shouldn't trim trailing whitespace
[*.{md}]
trim_trailing_whitespace = false
{
"extends": "airbnb/base",
"rules": {
"no-console": 0
"max-len": 0,
"no-console": 0,
}
}
+32
-7
#!/usr/bin/env node
const path = require('path');
const args = require('args');
const chalk = require('chalk');
const { api } = require('dext-core-utils');
const { api, utils } = require('dext-core-utils');
args.command(['install', 'i'], 'Install a new plugin or theme', (name, sub) => {
args.command(['install', 'i'], 'Install a new plugin or theme.', (name, sub) => {
const plugin = sub[0];
return api.install(plugin)
return api.install(plugin, utils.paths.getPluginPath(plugin))
.then(() => console.log(chalk.green(`${plugin} installed successfully!`)))

@@ -14,5 +15,5 @@ .catch(err => console.error(chalk.red(err)));

args.command(['uninstall', 'u'], 'Uninstall a plugin or theme', (name, sub) => {
args.command(['uninstall', 'u'], 'Uninstall a plugin or theme.', (name, sub) => {
const plugin = sub[0];
return api.uninstall(plugin)
return api.uninstall(plugin, utils.paths.getPluginPath(plugin))
.then(() => console.log(chalk.green(`${plugin} uninstalled successfully!`)))

@@ -22,9 +23,33 @@ .catch(err => console.error(chalk.red(err)));

args.command(['theme', 't'], 'Sets a theme', (name, sub) => {
args.command(['theme', 't'], 'Sets a theme.', (name, sub) => {
const theme = sub[0];
return api.setTheme(theme)
.then(() => console.log(chalk.green(`${theme} has been set successfully!`)))
.then(() => console.log(chalk.green(`${theme} has been set successfully!`)))
.catch(err => console.error(chalk.red(err)));
});
args.command(['link'], 'Creates a symlink for the current plugin.', () => {
const plugin = path.basename(process.cwd());
return api.createSymLink(plugin, process.cwd())
.then(data => {
console.log(chalk.green(`Linked: ${data.srcPath} -> ${data.destPath}`));
})
.catch(err => console.error(chalk.red(err)));
});
args.command(['unlink'], 'Removes the symlink for the current plugin.', () => {
const plugin = path.basename(process.cwd());
return api.removeSymLink(plugin)
.then(data => {
console.log(chalk.green(`Unlinked: ${data.destPath}`));
})
.catch(err => console.error(chalk.red(err)));
});
args.command(['config'], 'Display the raw config.', () => api.getConfig()
.then(data => {
console.log(chalk.green(JSON.stringify(data, null, 2)));
})
.catch(err => console.error(chalk.red(err))));
const flags = args.parse(process.argv);

@@ -31,0 +56,0 @@

{
"name": "dext-cli",
"version": "0.1.2",
"version": "0.2.0",
"description": "",

@@ -21,3 +21,3 @@ "main": "./cli.js",

"chalk": "^1.1.3",
"dext-core-utils": "^0.1.0"
"dext-core-utils": "^0.2.0"
},

@@ -24,0 +24,0 @@ "devDependencies": {

Sorry, the diff of this file is not supported yet