blob: bc7b8bc11502bfa9656c9988b7854ffb27b88184 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
|
> [!NOTE]
>
> You are using `mling` to create your `mingling` project. Before proceeding, please fill in your project information.
## Question 1: Fill in your project information
Use `snake-case` style to fill in the project name. It will serve as your `crate` name:
```name
my-cli
```
Describe your `program` in one sentence:
```description
This is a command-line program
```
## Question 2: Which Mingling version do you need?
> [!TIP]
>
> You must select **EXACTLY ONE** option
- [x] `ver:0.2` Based on the `Mingling@0.2.x` template
## Question 3: What is your project layout style?
> [!TIP]
>
> You must select **EXACTLY ONE** option
- [x] `base:flat` Flat mode (Simple)
```
# The most basic mode
./main.rs
./foo.rs
./bar.rs
./globals.rs
```
- [ ] `base:modularity` Modular mode
```
├─ module1/ # Stores private concepts internally
│ ├── mod.rs # Command registration
│ ├── chains/ # Core logic
│ └── renderers/ # Result rendering
├─ module2/
│ ├── mod.rs # Command registration
│ ├── chains/ # Core logic
│ └── renderers/ # Result rendering
├─ global/ # Stores public concepts in the global directory
│ ├── errors/ # Global Errors
│ ├── setups/ # Setups
│ └── resources/ # Global Resources
└─ main.rs
```
- [ ] `base:command` Command mode
```
# Stores all commands
├─ commands/ # Organizes subcommands by hierarchy
│ ├── remote/add.rs # "remote add"
│ ├── remote/rm.rs # "remote rm"
│ ├── remote.rs # Not a command,
│ │ but a local implementation for
│ │ the remote series of commands
│ ├── foo.rs # "foo"
│ └── bar.rs # "bar"
├─ errors/ # Global Errors
├─ resources/ # Global Resources
├─ setups/ # Setups
└─ main.rs
```
## Question 4: What additional features do you need to enable?
> [!TIP]
>
> All of the following options are **OPTIONAL**
**Pre:**
- [x] `exec:git_init` Initialize this project as a git repository (requires `git` to be installed)
**Features:**
- [x] `feat:extra_macros` Extra macro support
- [x] `feat:dispatch_tree` Compile-time dispatch tree (solidify all commands)
- [ ] `feat:structural_renderer` Structural renderer (JSON/YAML) for feature output
- [ ] `feat:comp` Dynamic completion system
- [ ] `feat:clap` Clap support
- [ ] `feat:parser` Mingling Picker parser support
- [ ] `feat:async` Async support
**Implementations:**
- [ ] `impl:exit_code` Introduce exit code control
- [ ] `impl:fallback` Fallback functionality when no command is given
---
After filling in the above, execute the following command to create the project:
```
~# mling gen
```
|