How about using shell functions instead:
```
#!/bin/sh -e
hello () {
echo hello
}
build() {
docker build -t image .
}
push() {
docker push -t image
}
"$@"
```
If you call that minimake.sh, then you call it as:
```
./minimake.sh hello
./minimake.sh build
./minimake.sh push
```
Hallo Natanael Copa, thank you for your attention to this topic!
Sure, you can write shell scripts, functions, case-statements, but with
`mim` you eliminate unnecessary noise.
For example in the script above there are 5 Lines of 11 which do not
provide any value, but noise.
(like "$@" from the bottom of your script,
https://stackoverflow.com/questions/9994295/what-does-mean-in-a-shell-script
<https://stackoverflow.com/questions/9994295/what-does-mean-in-a-shell-script>
(174k views))
So, the USP here is that mim provides a very clear and intuitive
interface for non-experienced shell users
And for complex stuff, use mim as a wrapper and write shell scripts
underneath.
```
deploy:
scripts/deploy.sh
cleanup:
rm -rf ./dist
```
I really would love to have it in busybox/alpine and in their
descendants, if you have common tasks to use in your containers, just
COPY a Mimfile in there.
```
# postgres-container/WORKDIR/Mimfile
backup:
# make a backup, post to s3
restore:
# get from s3 & restore
```
```
$ docker exec container mim restore
```
_______________________________________________
busybox mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/busybox