annotate tools/gen-bat-wrapper @ 6329:17e88be8f3ed

* src/opkg-mqtt.mk: update to v0.0.2
author John Donoghue <john.donoghue@ieee.org>
date Thu, 21 Jul 2022 13:22:40 -0400
parents 32a7bea19bb1
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
4253
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
1 #!/usr/bin/env bash
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
2
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
3 prog=$1
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
4
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
5 if [ -z $prog ]; then
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
6 echo "Missing program name" >&2
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
7 exit 1
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
8 fi
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
9
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
10 cat << EOF
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
11 @echo off
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
12 set BINPATH=%~dp0
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
13 %BINPATH%bash -c '$prog %*'
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents:
diff changeset
14 EOF