#!/usr/bin/env node

const execSync = require('child_process').execSync;
const readFileSync = require('fs').readFileSync;
const path = require('path');

const packageJson = JSON.parse(readFileSync(path.join(process.argv[2], 'package.json')));

if (!packageJson) {
  console.log('No package.json found at the path specified. Exiting...');
  process.exit(0);
}

let packages = [];
let command = 'npm i ';

const devDeps = packageJson['devDependencies'];

for (const key in devDeps) {
  if (key.indexOf('eslint') !== -1) {
    command += `${key}@` + devDeps[key] + ' ';
  }
}

execSync(command);

@@ -357,27 +357,8 @@
 %0A%7D%0A%0A
-let packages = %5B%5D;%0A
 let 

Remove unused variable