Skip to content

Instantly share code, notes, and snippets.

@rjhilgefort
Created April 23, 2019 21:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rjhilgefort/a1ef8d3b209a08f751d67dd64e22d7d2 to your computer and use it in GitHub Desktop.
Save rjhilgefort/a1ef8d3b209a08f751d67dd64e22d7d2 to your computer and use it in GitHub Desktop.
#!/usr/bin/env node
/* eslint-disable import/no-commonjs */
;(async () => {
const util = require('util')
const child_process = require('child_process')
const { tap } = require('ramda')
const execP = util.promisify(child_process.exec)
const exec = command => execP(command).then(({ stdout, stderr }) => {})
const { log } = console
// Get args
const [, , ...args] = process.argv
await exec(`echo ${args}`)
})()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment