UNPKG

tw-runner

Version:

Run and manage Tower Website projects with this utility.

22 lines (20 loc) 531 B
import { execSync } from 'child_process'; export default async function installGlobalDependencies() { const globalDependencies = [ 'sass', 'postcss-cli', 'postcss-preset-env', 'postcss-import', 'postcss-nested' ]; globalDependencies.forEach(dep => { try { execSync(`npm install -g ${dep}`, { stdio: 'inherit', timeout: 30000 // 30 seconds timeout }); } catch (error) { console.error(`Failed to install global dependency ${dep}:`, error.message); } }); }