New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@withfig/commander

Package Overview
Dependencies
Maintainers
5
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@withfig/commander - npm Package Compare versions

Comparing version 1.0.1 to 1.1.0

2

lib/index.d.ts

@@ -0,1 +1,2 @@

/// <reference types="@withfig/autocomplete-types" />
import type { Command } from "commander";

@@ -6,2 +7,3 @@ export interface Options {

}
export declare function generateCommand(_command: Command & Record<string, any>, figSpecCommandName: string): Fig.Subcommand | undefined;
export declare function generateFigSpec(command: Command, filename: string, options?: Options): void;

7

lib/index.js

@@ -6,3 +6,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
exports.generateFigSpec = void 0;
exports.generateFigSpec = exports.generateCommand = void 0;
const fs_1 = require("fs");

@@ -93,3 +93,3 @@ const path_1 = __importDefault(require("path"));

function generateCommand(_command, figSpecCommandName) {
const { _name, _description, _aliases, commands, _args, options, _addImplicitHelpCommandL, _hasHelpOption, } = _command;
const { _name, _description, _aliases, commands, _args, options, _addImplicitHelpCommandL, _hasHelpOption, _hidden, } = _command;
if (_name === figSpecCommandName)

@@ -101,2 +101,4 @@ return undefined;

command.description = _description;
if (_hidden)
command.hidden = true;
// Subcommands

@@ -128,2 +130,3 @@ if (commands.length) {

}
exports.generateCommand = generateCommand;
function generateFigSpec(command, filename, options) {

@@ -130,0 +133,0 @@ const cwd = (options === null || options === void 0 ? void 0 : options.cwd) || process.cwd();

{
"name": "@withfig/commander",
"version": "1.0.1",
"version": "1.1.0",
"description": "Export commander command as a Fig spec",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc