{"id":21382294,"url":"https://github.com/zaphar/clojure-flags","last_synced_at":"2025-10-18T16:03:40.274Z","repository":{"id":973824,"uuid":"771736","full_name":"zaphar/clojure-flags","owner":"zaphar","description":"CommandLine flag parsing library","archived":false,"fork":false,"pushed_at":"2010-07-25T22:10:06.000Z","size":108,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-07T12:07:21.455Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Clojure","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"artistic-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zaphar.png","metadata":{"files":{"readme":"README.markdown","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2010-07-13T03:35:52.000Z","updated_at":"2013-10-20T08:11:56.000Z","dependencies_parsed_at":"2022-08-16T11:40:30.233Z","dependency_job_id":null,"html_url":"https://github.com/zaphar/clojure-flags","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/zaphar/clojure-flags","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zaphar%2Fclojure-flags","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zaphar%2Fclojure-flags/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zaphar%2Fclojure-flags/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zaphar%2Fclojure-flags/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zaphar","download_url":"https://codeload.github.com/zaphar/clojure-flags/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zaphar%2Fclojure-flags/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267417664,"owners_count":24083839,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-27T02:00:11.917Z","response_time":82,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":[],"created_at":"2024-11-22T10:58:31.760Z","updated_at":"2025-10-18T16:03:35.227Z","avatar_url":"https://github.com/zaphar.png","language":"Clojure","funding_links":[],"categories":[],"sub_categories":[],"readme":"Clojure Flags\n=============\n\nUsage:\n------\n\nA commandline flag parsing library.\n\nclojure-flags allows you to:\n\n1. Specify the flags anywhere in your code.\n2. Self Document flags\n3. Type checking flags.\n\n\n   (require '[com.marzhillstudios.flags :as flags])\n  \n   (defflag :string \"string-flag\"\n            \"Documentation about the flag\")\n   (defflag :bool \"bool-flag\"\n            \"Documentation about the bool flag\")\n  \n   (defn -main [\u0026 args]\n    (flags/parse args) ; parse the command line arguments\n    (do\n      (let [string-flag-val (get-flag \"string-flag\")] ; retrieve the flag value\n        (some-fun (flags/unparsed-args)))))\n\n\nYou can define your own flag type handlers using the defflag-type function:\n\n\n    (defflag-type :type-specifier (fn [matched] (last %1)))\n\n\nThe function will get one argument which will be the vector returned\nfrom parsing the flag the last item in the vector will be the value, the\nthird item will be the flags name. You will mostly only care about the third.\n\nLeiningen\n---------\n\nclojure-flags in hosted on clojars. To use it in your project just: include\nthis [clojure-flags \"0.01.0\"] in your projects :dependencies list.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzaphar%2Fclojure-flags","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzaphar%2Fclojure-flags","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzaphar%2Fclojure-flags/lists"}