Daemon utility for shiba(v/w)
$ npm install shiba-daemon-util --save
'use strict'
const {subjectFromFile} = require('shiba-daemon-util')
async function tryExample () {
const example01 = subjectFromFile(
'jp.realglobe.shiba.daemon.util.example01'
)
await example01.sayHi()
}
tryExample().catch((err) => console.error(err))
jp.realglobe.shiba.daemon.util.example01
#!/bin/bash
#
subject=$1
verb=$2
object1=$3
object2=$4
if [[ ${verb} == *"sayHi"* ]]
then
printf "Hi, ${object1} and ${object2}"
exit
fi
echo "Unknown verb ${verb}"
exit 1
This software is released under the MIT License.