Advertisement
Guest User

Untitled

a guest
Jan 12th, 2021
276
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.07 KB | None | 0 0
  1. index.js:
  2. #!/usr/bin/env node
  3.  
  4. const inquirer = require("inquirer");
  5. const chalk = require("chalk");
  6. const figlet = require("figlet");
  7. // const shell = require("shelljs");
  8.  
  9. const init = () => {
  10. console.log(
  11. chalk.green(
  12. figlet.textSync("Node JS CLI", {
  13. font: "Ghost",
  14. horizontalLayout: "default",
  15. verticalLayout: "default"
  16. })
  17. )
  18. );
  19. };
  20.  
  21. const run = async () => {
  22.  
  23. init();
  24.  
  25. };
  26.  
  27. run();
  28.  
  29.  
  30. package.json:
  31. {
  32. "name": "dayzwebservice",
  33. "version": "1.0.0",
  34. "description": "",
  35. "main": "index.js",
  36. "scripts": {
  37. "test": "echo \"Error: no test specified\" && exit 1",
  38. "start": "node index.js"
  39. },
  40. "author": "",
  41. "license": "ISC",
  42. "dependencies": {
  43. "chalk": "^4.1.0",
  44. "figlet": "^1.5.0",
  45. "inquirer": "^7.3.3",
  46. "shelljs": "^0.8.4"
  47. },
  48.  
  49. "pkg": {
  50. "scripts": [],
  51. "assets": [
  52. "node_modules/figlet/fonts/Ghost.flf"
  53. ],
  54. "targets": [
  55. "node12-linux-x64",
  56. "node12-macos-x64",
  57. "node12-win-x64"
  58. ]
  59. },
  60. "bin": "index.js"
  61. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement