Skip to content

Commit

Permalink
Merge pull request NicoVogel#6 from PKief/remove-dependencies
Browse files Browse the repository at this point in the history
Remove dependencies
  • Loading branch information
NicoVogel committed Feb 28, 2020
2 parents 6822921 + a0a729a commit 3914e1b
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 74 deletions.
89 changes: 26 additions & 63 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 1 addition & 7 deletions package.json
Expand Up @@ -31,14 +31,8 @@
"url": "https://github.com/NicoVogel/docker_extension/issues"
},
"homepage": "https://github.com/NicoVogel/docker_extension#readme",
"dependencies": {
"mkdirp": "^1.0.3"
},
"dependencies": {},
"devDependencies": {
"@types/colors": "^1.2.1",
"@types/commander": "^2.12.2",
"@types/inquirer": "^6.5.0",
"@types/mkdirp": "^1.0.0",
"@types/node": "^12.7.1",
"@typescript-eslint/eslint-plugin": "^2.0.0",
"@typescript-eslint/parser": "^2.0.0",
Expand Down
7 changes: 3 additions & 4 deletions src/docker-extension.ts
Expand Up @@ -3,8 +3,7 @@
import { Caller } from './@types/model';
import { Config } from './@types/config';
import { dirname, join } from 'path';
import { readFileSync, existsSync, writeFileSync } from 'fs';
import { sync as mkdirpSync } from 'mkdirp';
import { readFileSync, existsSync, writeFileSync, mkdirSync } from 'fs';
import { spawn } from 'child_process';

const removeFirstItems = <T>(array: T[], amount: number): T[] => {
Expand Down Expand Up @@ -43,7 +42,7 @@ class HelperCaller implements Caller {
private maps: Map<string, string>,
private defaultAction: string,
private showCommand?: boolean
) {}
) { }
invoke(args: string[]): void {
let passArgs = args;
const firstArg = passArgs[0];
Expand Down Expand Up @@ -108,7 +107,7 @@ const getConfig = (processUrl: string): Config => {
);
if (existsSync(configLocation) === false) {
try {
mkdirpSync(dirname(configLocation));
mkdirSync(dirname(configLocation), { recursive: true });
writeFileSync(configLocation, JSON.stringify(defaultConfig, null, 2));
} catch (err) {
throw new Error(
Expand Down

0 comments on commit 3914e1b

Please sign in to comment.