Skip to content

Commit c710de3

Browse files
committed
Documented generate helper.
1 parent 016c7ab commit c710de3

File tree

45 files changed

+306
-170
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

45 files changed

+306
-170
lines changed

00-documentation/src/docs/helper/createProject.md renamed to 00-documentation/src/docs/development/createProject.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@ Here we focus on the first step.
1111

1212
1. We can use the same `helperCompany.scala` script, we created in the [Init Company] step.
1313
```scala
14-
cd ~/dev-myCompany
14+
cd ~/dev-mycompany
1515
./helperCompany.scala project myProject
1616
```
1717
This creates:
1818

1919
```bash
20-
dev-myCompany
20+
dev-mycompany
2121
| projects
2222
| | myProject
2323
| | | helper.scala
@@ -29,17 +29,17 @@ cd ~/projects/myProject
2929
chmod +x helper.scala
3030
```
3131

32-
1. Open the `myCompany-myProject` directory with your IDE (I use Intellij).
32+
1. Open the `mycompany-myProject` directory with your IDE (I use Intellij).
3333

3434
@:callout(info)
3535
If you haven't released `company-camundala` yet,
3636
you need to run it at least locally (`sbt publishLocal`)
3737
and set the version in the `helper.scala` manually.
3838

3939
```scala
40-
//> using dep myCompany::myCompany-camundala-helper:VERSION NOT FOUND
40+
//> using dep mycompany::mycompany-camundala-helper:VERSION NOT FOUND
4141
// replace with:
42-
//> using dep myCompany::myCompany-camundala-helper:0.1.0-SNAPSHOT
42+
//> using dep mycompany::mycompany-camundala-helper:0.1.0-SNAPSHOT
4343
```
4444

4545
@:@

00-documentation/src/docs/helper/directory.conf renamed to 00-documentation/src/docs/development/directory.conf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

22
laika.navigationOrder = [
3-
development.md
3+
intro.md
44
initCompany.md
55
createProject.md
66
projectDev.md

00-documentation/src/docs/helper/initCompany.md renamed to 00-documentation/src/docs/development/initCompany.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,14 @@ So try to stick to the conventions, whenever possible.
2525

2626
1. Create a directory for your company development:
2727
```bash
28-
mkdir ~/dev-myCompany
28+
mkdir ~/dev-mycompany
2929
```
3030

31+
Be aware that the company name (_mycompany_) must be lowercase to work properly.
32+
3133
1. Create `helperCompany.scala` in your company directory and open it.
3234
```bash
33-
cd ~/dev-myCompany
35+
cd ~/dev-mycompany
3436
touch helperCompany.scala
3537
open helperCompany.scala
3638
```

00-documentation/src/docs/helper/development.md renamed to 00-documentation/src/docs/development/intro.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Development
1+
# Introduction
22

33
## Pre-Requisites
44
**_Camundala_** is written in _**Scala**_ and provides _Scala DSLs_.
Lines changed: 198 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,198 @@
1+
# Project Development
2+
**Experimental**
3+
4+
The following chapters describe the tasks to support the project development.
5+
6+
We provide a `helper.scala` script that helps you with the most common tasks.
7+
8+
In general, you can type `./helper.scala x` to get a list of available commands.
9+
10+
And then you can type `./helper.scala <command>` to get help for a specific command.
11+
12+
The `version` is optional and defaults to `1`.
13+
14+
## update
15+
Whenever you have changes in the `company-camundala` project or in one of your dependencies,
16+
you can update the project with the following command:
17+
18+
```bash
19+
./helper.scala update
20+
```
21+
22+
This will create or update your project with the latest changes.
23+
24+
Files that contain the `DO NOT ADJUST` comment will be replaced.
25+
If you do adjust them, remove this comment.
26+
You will get a warning, but the file will not be replaced.
27+
28+
## Generate Process/-Elements
29+
To handle name conventions and to avoid errors, we generate as much as possible.
30+
31+
So it is essential, not to change the generated names.
32+
33+
The following generators are provided:
34+
35+
### process
36+
Creates a new Process.
37+
38+
Usage:
39+
```
40+
./helper.scala process <processName> [version: Int]
41+
```
42+
43+
Example:
44+
```
45+
./helper.scala process myProcess 1
46+
```
47+
48+
This creates the following files:
49+
```
50+
// the BPMN
51+
src - main -> myproject-myProcessV1.bpmn
52+
// the domain In -> Out
53+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MyProcess
54+
// the Simulation
55+
03-simulation - test -> mycompany.myproject.simulation.MyProcessSimulation
56+
// the InitWorker
57+
03-worker - main -> mycompany.myproject.worker.myProcess.v1.MyProcessWorker
58+
- test -> mycompany.myproject.worker.myProcess.v1.MyProcessWorkerTest
59+
```
60+
61+
### customTask
62+
Creates a new Custom Task.
63+
64+
Usage:
65+
```
66+
./helper.scala customTask <processName> <bpmnName> [version: Int]
67+
```
68+
69+
Example:
70+
```
71+
./helper.scala customTask myProcess MyCustomTask 1
72+
```
73+
74+
This creates the following files:
75+
```
76+
// the domain In -> Out
77+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MyCustomTask
78+
// the CustomWorker
79+
03-worker - main -> mycompany.myproject.worker.myProcess.v1.MyCustomTaskWorker
80+
- test -> mycompany.myproject.worker.myProcess.v1.MyCustomTaskWorkerTest
81+
```
82+
83+
### serviceTask
84+
Creates a new Service Task.
85+
86+
Usage:
87+
```
88+
./helper.scala serviceTask <processName> <bpmnName> [version: Int]
89+
```
90+
91+
Example:
92+
```
93+
./helper.scala serviceTask myProcess MyServiceTask 1
94+
```
95+
96+
This creates the following files:
97+
```
98+
// the domain In -> Out (ServiceIn -> ServiceOut)
99+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MyServiceTask
100+
// the ServiceWorker
101+
03-worker - main -> mycompany.myproject.worker.myProcess.v1.MyServiceTaskWorker
102+
- test -> mycompany.myproject.worker.myProcess.v1.MyServiceTaskWorkerTest
103+
```
104+
105+
### userTask
106+
Creates a new User Task.
107+
108+
Usage:
109+
```
110+
./helper.scala userTask <processName> <bpmnName> [version: Int]
111+
```
112+
113+
Example:
114+
```
115+
./helper.scala userTask myProcess MyUserTask 1
116+
```
117+
118+
This creates the following files:
119+
```
120+
// the domain In -> Out
121+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MyUserTask
122+
```
123+
124+
### decision
125+
Creates a new Decision.
126+
127+
Usage:
128+
```
129+
./helper.scala decision <processName> <bpmnName> [version: Int]
130+
```
131+
132+
Example:
133+
```
134+
./helper.scala decision myProcess MyDecision 1
135+
```
136+
137+
This creates the following files:
138+
```
139+
// the domain In -> Out
140+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MyDecision
141+
```
142+
143+
### signalEvent
144+
Creates a new Signal Event.
145+
146+
Usage:
147+
```
148+
./helper.scala signalEvent <processName> <bpmnName> [version: Int]
149+
```
150+
151+
Example:
152+
```
153+
./helper.scala signalEvent myProcess MySignalEvent 1
154+
```
155+
156+
This creates the following files:
157+
```
158+
// the domain In -> NoOutput
159+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MySignalEvent
160+
```
161+
162+
### messageEvent
163+
Creates a new Message Event.
164+
165+
Usage:
166+
```
167+
./helper.scala messageEvent <processName> <bpmnName> [version: Int]
168+
```
169+
170+
Example:
171+
```
172+
./helper.scala messageEvent myProcess MyMessageEvent 1
173+
```
174+
175+
This creates the following files:
176+
```
177+
// the domain In -> NoOutput
178+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MyMessageEvent
179+
```
180+
181+
### timerEvent
182+
Creates a new Timer Event.
183+
184+
Usage:
185+
```
186+
./helper.scala timerEvent <processName> <bpmnName> [version: Int]
187+
```
188+
189+
Example:
190+
```
191+
./helper.scala timerEvent myProcess MyTimerEvent 1
192+
```
193+
194+
This creates the following files:
195+
```
196+
// the domain NoInput -> NoOutput
197+
02-bpmn - main -> mycompany.myproject.bpmn.myProcess.v1.MyTimerEvent
198+
```

00-documentation/src/docs/directory.conf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,5 @@ laika.navigationOrder = [
77
technologies.md
88
generalConcerns.md
99
functionalityDsls
10+
development
1011
]

0 commit comments

Comments
 (0)