scripts

misc scripts and tools
git clone git://git.2f30.org/scripts
Log | Files | Refs

daemon (247B)


      1 #!/bin/sh
      2 
      3 # this script tries to emulate the behaviour of bsd daemon(3) call
      4 # runs a job with its std streams closed and detaches from terminal
      5 
      6 if test -z $1; then
      7     echo usage: $(basename $0) job && exit 1
      8 fi
      9 
     10 (exec "$@" &) > /dev/null 2>&1