Skip to content

Instantly share code, notes, and snippets.

@jplew
Last active May 17, 2019 22:47
Show Gist options
  • Save jplew/6a76ca2a70819a7614dde8022df07d7d to your computer and use it in GitHub Desktop.
Save jplew/6a76ca2a70819a7614dde8022df07d7d to your computer and use it in GitHub Desktop.
Run an op from a gist
#!/usr/bin/env node
const boxen = require("boxen")
const logo = `
██████╗ ████████╗ ██████╗  █████╗ ██╗
██╔════╝ ╚══██╔══╝ ██╔═══██╗ ██╔══██╗ ██║
██║   ██║  ██║ ██║ ███████║ ██║
██║   ██║  ██║ ██║ ██╔══██║ ██║
╚██████╗  ██║  ╚██████╔╝ ██╗ ██║ ██║ ██║
 ╚═════╝  ╚═╝   ╚═════╝  ╚═╝ ╚═╝ ╚═╝ ╚═╝
We’re building the world’s best developer experiences.
FIND US HERE
Website: "https://cto.ai/",
NPM: "https://www.npmjs.com/package/@cto.ai/ops",
Twitter: "https://twitter.com/CTO_AI",
LinkedIn: "https://www.linkedin.com/company/cto-ai",
AngelList: "https://angel.co/cto-ai/jobs",
Instagram: "https://www.instagram.com/cto.ai"
`
function run() {
console.log(
boxen(logo, {
padding: 1,
margin: 1,
borderColor: "blue",
borderStyle: "double",
center: true
})
)
process.exit()
}
run()
{
"name": "js-from-terminal-with-npx",
"version": "1.0.0",
"bin": "./index.js",
"dependencies": {
"boxen": "^3.2.0"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment