UNPKG

@gameroom/cli

Version:

A command line tool for Gameroom

13 lines (10 loc) 453 B
const { getServiceUrlAndPort, prompt, runCommand } = require('../consoleIO') module.exports = async (options) => { let { source, destination } = options if (!source) source = await prompt('source: ') if (!destination) destination = '~/downloads' const { url, port } = await getServiceUrlAndPort('ssh', options) const command = `scp -P ${port} '${source}' infinitetoken@${url}:'${destination}'` console.log(command) runCommand(command) }