
Research
/Security News
Fake imToken Chrome Extension Steals Seed Phrases via Phishing Redirects
Mixed-script homoglyphs and a lookalike domain mimic imToken’s import flow to capture mnemonics and private keys.
@vltpkg/run
Advanced tools
Run a script defined in a package.json file (eg, vlt run and
lifecycle scripts), or an arbitrary command as if it was (eg,
vlt exec).
import { run, exec } from '@vltpkg/run'
const cwd = '/path/to/pkg'
// to run a script, as with `vlt run blah`
const runResult = await run({
// the name of the thing in package.json#scripts
event: 'build',
// the dir where the package.json lives
cwd,
// if the script is not defined in package.json#scripts, just
// ignore it and treat as success. Otherwise, treat as an
// error. Default false.
ignoreMissing: true,
// extra arguments to pass into the child process
args: ['some', 'arguments'],
// the environment variables to add, defaults to process.env.
// note that @vltpkg/run will add some of its own, as well:
// - npm_lifecycle_event: the event name
// - npm_lifecycle_script: the command in package.json#scripts
// - npm_package_json: path to the package.json file
// - VLT_* envs for all vlt configuration values that are set
env: process.env,
// set this to `true` to take over the terminal and run in the
// foreground, inheriting the parent process's stdio
// by default, the script runs in the background.
// Only one foreground:true script will be run in parallel!
foreground: true,
// the shell to run the script in. Defaults to `${SHELL}` env
// variable if set, otherwise the system specific shell,
// `cmd.exe` on windows, and `/bin/sh` on posix.
'script-shell': '/usr/bin/bash',
// pass in a @vltpkg/package-json.PackageJson instance, and
// it'll be used for reading the package.json file. Optional,
// may improve performance somewhat.
packageJson: new PackageJson(),
})
// to execute an arbitrary command, as with `vlt exec whatever`
const execResult = await exec({
// the command to execute.
command: 'do-something',
args: ['some', 'arguments'],
// other arguments all the same.
})
FAQs
Run package.json scripts and execute commands
We found that @vltpkg/run demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 6 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
/Security News
Mixed-script homoglyphs and a lookalike domain mimic imToken’s import flow to capture mnemonics and private keys.

Security News
Latio’s 2026 report recognizes Socket as a Supply Chain Innovator and highlights our work in 0-day malware detection, SCA, and auto-patching.

Company News
Join Socket for live demos, rooftop happy hours, and one-on-one meetings during BSidesSF and RSA 2026 in San Francisco.