Socket
Socket
Sign inDemoInstall

cowmand

Package Overview
Dependencies
4
Maintainers
1
Versions
46
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.0 to 0.2.0

example/basic/session.json

1

dist/terminal.d.ts

@@ -6,2 +6,3 @@ import ora from 'ora';

table(...args: unknown[]): Terminal;
question(question: string): Promise<string>;
loading(text: string): {

@@ -8,0 +9,0 @@ changeText(textChange: string): void;

"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
step((generator = generator.apply(thisArg, _arguments || [])).next());
});
};
var __importDefault = (this && this.__importDefault) || function (mod) {

@@ -7,2 +16,3 @@ return (mod && mod.__esModule) ? mod : { "default": mod };

exports.terminal = void 0;
const readline_1 = require("readline");
const chalk_1 = __importDefault(require("chalk"));

@@ -24,2 +34,16 @@ const ora_1 = __importDefault(require("ora"));

},
question(question) {
return __awaiter(this, void 0, void 0, function* () {
return new Promise(resolve => {
const questionInterface = (0, readline_1.createInterface)({
input: process.stdin,
output: process.stdout
});
questionInterface.question(question, answer => {
questionInterface.close();
resolve(answer);
});
});
});
},
loading(text) {

@@ -26,0 +50,0 @@ const spinner = (0, ora_1.default)({

2

package.json
{
"name": "cowmand",
"version": "0.1.0",
"version": "0.2.0",
"description": "Fast helper to create a cli",

@@ -5,0 +5,0 @@ "tags": [

@@ -72,3 +72,4 @@ ![Cowmand][cowmand-logo]

- [ ] Terminal - Add table console
- [ ] Terminal - Add question on terminal
- [x] Terminal - Add question on terminal
- [ ] Terminal - Add option to hide a password

@@ -75,0 +76,0 @@ ****

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc