https://github.com/jodersky/scala-argparse
Pragmatic command line parsing and configuration for Scala apps
https://github.com/jodersky/scala-argparse
cli cli-parser
Last synced: 12 months ago
JSON representation
Pragmatic command line parsing and configuration for Scala apps
- Host: GitHub
- URL: https://github.com/jodersky/scala-argparse
- Owner: jodersky
- License: bsd-3-clause
- Created: 2020-04-23T21:58:25.000Z (almost 6 years ago)
- Default Branch: master
- Last Pushed: 2023-04-03T16:41:28.000Z (almost 3 years ago)
- Last Synced: 2025-03-18T17:04:28.333Z (about 1 year ago)
- Topics: cli, cli-parser
- Language: Scala
- Homepage: https://jodersky.github.io/scala-argparse
- Size: 12.7 MB
- Stars: 13
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE.md
Awesome Lists containing this project
README
# scala-argparse
[](https://jodersky.github.io/scala-argparse)
[](https://discord.gg/usj9DC8FDN)
[](https://crashbox.zulipchat.com/#narrow/stream/330744-argparse)
[![latest version][scaladex-badge]][scaladex-link]
[](https://www.crashbox.io/stability.html)
[scaladex-badge]: https://index.scala-lang.org/jodersky/scala-argparse/argparse/latest.svg
[scaladex-link]: https://index.scala-lang.org/jodersky/scala-argparse/argparse
Pragmatic command line parsing for Scala applications.
## Highlights
- Simple interface, inspired by the
[argparse](https://docs.python.org/3/library/argparse.html) package from
python.
- Bash completion.
- Standalone bash completion for a super snappy user experience, even on the
JVM.
- Interactive bash completion for the most custom needs.
- Works with Scala 2 and 3, Native and JVM
## Docs
- HTML: look at the [website](https://jodersky.github.io/scala-argparse)
- source (markdown): browse the docs/ folder.
## Building
This project uses [Mill](https://github.com/com-lihaoyi/mill) to build. The
configuration is in the `build.sc` file.
### Developer
- compile main project for all supported versions of scala: `./mill argparse.__.compile`
- run all tests: `./mill __.test`
- run an example:
- `./mill examples. `
- e.g. `./mill examples.paramnamed --verbosity 5`
- note: examples use Scala Native and hence require llvm
- publish main project locally: `./mill argparse.__.publishLocal`
### Maintainer
Look at the scripts in the `ci/` directory.