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

github.com/forau/gocop

Package Overview
Dependencies
Alerts
File Explorer
Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

github.com/forau/gocop

  • v0.0.0-20160604011543-1706c587ca99
  • Source
  • Go
  • Socket score

Version published
Created
Source

go-cop

Go Report Card Build Status GoDoc

GO - Command Parser

This is a library that tries to make it conveient to add commands to your go-program. It is dependant on the excilent liner library, for handling the tty, history, emacs-keys and more.

What gocop adds on top is a small parser to sugest autocomplete and invoke commands easily. History/autosugest is content aware, so default arguments with the same name will share sugestions, but you can also create custom sugestions. For example, email addresses might be sugested from an address book, or reply might be sugested from messages recived.

Status

Verion 0.0 Still in very early stage. Everything might change.

Usage

The basic usage will be to create a 'world' struct, and hook commands, and arguments onto it. Arguments can be optional or greedy.

Arguments are separated by whitespace, so if you need to send an argument with spaces or tabs, you need to eighter backslash the whitespace, or put the string in single or double quotes.

Bugs / Todo

  • Linebreak during quoted strings does not allow you to continue on next line

  • Make easier to use

  • Create examples

  • Make 'worlds' swappable, so commands can control following states.

  • and more...

FAQs

Package last updated on 04 Jun 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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