{"id":21141499,"url":"https://github.com/influx6/cmdkit","last_synced_at":"2026-04-24T08:32:01.126Z","repository":{"id":138756930,"uuid":"147556586","full_name":"influx6/cmdkit","owner":"influx6","description":"Simple, battery-included,zero dependency command line library","archived":false,"fork":false,"pushed_at":"2018-09-06T10:07:01.000Z","size":25,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-14T13:14:54.177Z","etag":null,"topics":["cli","cli-library"],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/influx6.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-09-05T17:40:13.000Z","updated_at":"2024-12-25T23:49:03.000Z","dependencies_parsed_at":null,"dependency_job_id":"6d8f57cc-d972-413a-8330-6228d4461494","html_url":"https://github.com/influx6/cmdkit","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/influx6/cmdkit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/influx6%2Fcmdkit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/influx6%2Fcmdkit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/influx6%2Fcmdkit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/influx6%2Fcmdkit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/influx6","download_url":"https://codeload.github.com/influx6/cmdkit/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/influx6%2Fcmdkit/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32216168,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-24T08:24:32.376Z","status":"ssl_error","status_checked_at":"2026-04-24T08:24:26.731Z","response_time":64,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","cli-library"],"created_at":"2024-11-20T07:30:25.770Z","updated_at":"2026-04-24T08:32:01.110Z","avatar_url":"https://github.com/influx6.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"Cmdkit\n--------------\nCmdkit provides a simple commandline library with zero outside dependency, using \ninternal libraries as much as possible. It's geared towards a simple API.\n\nIf you need broader functionality then I would encourage you to use more robust libraries.\n\n## Install\n\n```\ngo get -u github.com/gokit/cmdkit\n```\n\n\n## Usage\n\n```go\nimport \"fmt\"\nimport \"github.com/gokit/cmdkit\"\n\nfunc main() {\n\tcmdkit.Run(\n\t\t\"example\", \n\t\tcmdkit.Flags(\n\t\t\tcmdkit.IntFlag(cmdkit.FlagName(\"age\")),\n\t\t\tcmdkit.StringFlag(cmdkit.FlagName(\"name\")),\n\t\t), \n\t\tcmdkit.Commands(\n\t\t\tcmdkit.Cmd(\n\t\t\t\t\"add\",\n\t\t\t\tcmdkit.Desc(\"displays a add message\"),\n\t\t\t\tcmdkit.WithAction(func(ctx cmdkit.Context) error {\n\t\t\t\t\tfmt.Printf(\"Welcome to add: %q -\u003e %d \\n\", ctx.String(\"name\"), ctx.Int(\"age\"))\n\t\t\t\t\treturn nil\n\t\t\t\t}),\n\t\t\t\tcmdkit.SubCommands(\n\t\t\t\t\tcmdkit.Cmd(\n\t\t\t\t\t\t\"broc\",\n\t\t\t\t\t\tcmdkit.Desc(\"displays a broc message\"),\n\t\t\t\t\t\tcmdkit.WithAction(func(ctx cmdkit.Context) error {\n\t\t\t\t\t\t\tfmt.Printf(\"Welcome to bro adder: %q -\u003e %d \\n\", ctx.String(\"name\"), ctx.Int(\"age\"))\n\t\t\t\t\t\t\treturn nil\n\t\t\t\t\t\t}),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t))\n}\n```\n\nThe code above produces the ff:\n\n````bash\nUsage: example [flags] [command] \n\n⡿ COMMANDS:\n\n\t⠙ add        displays a add message\n\n⡿ HELP:\n\n\tRun [command] --help to print this message\n\tRun example --flags to print all flags of all commands.\n\n⡿ Flags:\n\t\n\t⠙ age  (int)          \n\t\n\t⠙ name  (string)          \n\t\n\t⠙ help  (bool)          \n\t\n\t⠙ flags  (bool)          \n\t\n\t⠙ timeout  (time.Duration)          \n\t\n````","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finflux6%2Fcmdkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Finflux6%2Fcmdkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Finflux6%2Fcmdkit/lists"}