Skip to content

Commit 8fc5ec1

Browse files
authored
Added alternative multi-threading (#82)
Co-authored-by: Arif Rahmadi <41944717+arifrahmd@users.noreply.github.com>
1 parent 7d3b036 commit 8fc5ec1

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

README.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1262,6 +1262,20 @@ bash -v scriptname
12621262
bash -x scriptname
12631263
```
12641264
1265+
# 5. Multi-threading
1266+
You can easily multi-threading your jobs using `&`. All those jobs will then run in the background simultaneously and you can see the processes below are running using `jobs`.
1267+
1268+
```bash
1269+
sleep 15 & sleep 5 &
1270+
```
1271+
1272+
The optional `wait` command will then wait for all the jobs to finish.
1273+
1274+
```bash
1275+
sleep 10 & sleep 5 &
1276+
wait
1277+
```
1278+
12651279
## Contribution
12661280
12671281
- Report issues [How to](https://help.github.com/articles/creating-an-issue/)

0 commit comments

Comments
 (0)