|
1 |
| -# Haskell Template |
| 1 | +# Oclis |
2 | 2 |
|
3 |
| -Opinionated template for new Haskell projects. |
| 3 | +CLI (Command Line Interface) app builder |
| 4 | +based on a simple, obvious specification file. |
4 | 5 |
|
5 | 6 |
|
6 |
| -## Used Technologies |
| 7 | +## Motivation |
7 | 8 |
|
8 |
| -- [Stack](https://docs.haskellstack.org/en/stable/README/) |
9 |
| -- [Fourmolu](https://fourmolu.github.io) |
10 |
| -- [Haskell Language Server ](https://github.com/haskell/haskell-language-server) |
11 |
| -- [Protolude](https://github.com/protolude/protolude) |
| 9 | +Building a CLI application is a repetitive task. |
| 10 | +The same code is written over and over again. |
| 11 | +But fear not, Oclis is here to help you out! |
12 | 12 |
|
13 | 13 |
|
14 | 14 | ## Usage
|
15 | 15 |
|
16 |
| -1. Clone this repository |
17 |
| -1. Rename the folder to your project name |
18 |
| -1. Replace all occurences of `haskell-template` with your project name |
19 |
| -1. Run `stack test` to build the project and run the tests |
20 |
| -1. Run `stack run` to run the project |
21 |
| -1. Run `stack install` to install the project (make it available in your PATH) |
| 16 | +1. Write a simple specification file. |
| 17 | +2. Run `oclis` to generate the CLI parsing code for the language of your choice. |
| 18 | +3. Define the handler functions for your commands. |
| 19 | +4. Done 🎉 |
| 20 | + |
| 21 | + |
| 22 | +## Related |
| 23 | + |
| 24 | +### Tools |
| 25 | + |
| 26 | +- [CLI Definition Language] - DSL for defining command line interfaces |
| 27 | + of C++ programs. |
| 28 | +- [Decli] - Declarative CLI tool builder. |
| 29 | +- [docopt] - Command-line interface description language. |
| 30 | +- [make-cli] - Declarative CLI framework for Node.js. |
| 31 | + |
| 32 | +[CLI Definition Language]: https://www.codesynthesis.com/projects/cli/ |
| 33 | +[Decli]: https://github.com/woile/decli |
| 34 | +[docopt]: http://docopt.org/ |
| 35 | +[make-cli]: https://github.com/dword-design/make-cli |
| 36 | + |
| 37 | + |
| 38 | +### Specifications |
| 39 | + |
| 40 | +- [clig.dev] - Command Line Interface Guidelines. |
| 41 | +- [GNU Table of Long Options][gtolo] |
| 42 | +- [Heroku CLI Style Guide][hcsg] |
| 43 | +- [OpenAutoComplete] - CLI autocomplete specification. |
| 44 | +- [POSIX Utility Conventions][puc] |
| 45 | + |
| 46 | +[clig.dev]: https://clig.dev |
| 47 | +[gtolo]: |
| 48 | + https://www.gnu.org/prep/standards/html_node/Option-Table.html#Option-Table |
| 49 | +[hcsg]: https://devcenter.heroku.com/articles/cli-style-guide |
| 50 | +[OpenAutoComplete]: https://github.com/openautocomplete/openautocomplete |
| 51 | +[puc]: https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap12.html |
| 52 | + |
| 53 | + |
| 54 | +### Generate GUIs From CLI |
| 55 | + |
| 56 | +- [Claui] - A GUI generator for [clap] using [egui]. |
| 57 | +- [Gooey] - Turn CLI programs into a full GUI application. |
| 58 | +- [Klask] - Automatically create GUI applications from [clap] apps. |
| 59 | + |
| 60 | +[clap]: https://github.com/clap-rs/clap |
| 61 | +[Claui]: https://github.com/grantshandy/claui |
| 62 | +[egui]: https://github.com/emilk/egui |
| 63 | +[Gooey]: https://github.com/chriskiehl/Gooey |
| 64 | +[Klask]: https://github.com/MichalGniadek/klask |
| 65 | + |
| 66 | + |
| 67 | +### Generate GUIs From Simple Code |
| 68 | + |
| 69 | +- [Streamlit] - Turns data scripts into shareable web apps. |
| 70 | + |
| 71 | +[Streamlit]: https://github.com/streamlit/streamlit |
0 commit comments