improved CLI

This commit is contained in:
Jorijn van der Graaf 2024-12-29 00:51:02 +01:00
commit fbc13a9897
5 changed files with 112 additions and 66 deletions

View file

@ -55,22 +55,15 @@ int main() {
std::println("Hello World!");
}
```
Save and close, then run ``crafter-build debug``. Now you can run the ``hello-world`` executable that has appeared in the ``build`` folder
Save and close, then run ``crafter-build debug``. Now you can run the ``hello-world`` executable that has appeared in the ``bin`` folder
## CLI arguments
```bash
crafter-build <configuration>
```
builds the project with the specified configuration, using the defualt project filename ``project.json``
```bash
crafter-build <configuration> <filename>
```
builds the project with the specified configuration, using the specified project filename
``--help`` Displays this help message.
```bash
crafter-build --help
```
displays this help message
``-c`` The name of the configuration to build.
``-p`` The name of the project file.
``-o`` Overrides the output folder.