Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 6 Jun 2009 01:13:36 +0300
From:      <relay.lists@gmail.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: Can a Bourn Shell Script put itself in the background?
Message-ID:  <20090606011336.655f0753@ilievnet.com>
In-Reply-To: <200906041406.n54E6Fts006668@dc.cis.okstate.edu>
References:  <200906041406.n54E6Fts006668@dc.cis.okstate.edu>

next in thread | previous in thread | raw e-mail | index | archive | help



=================
#!/bin/bash

# This script will sleep 
# 50 times for 1 second in
# the background


  main()
  {
    for ((i=0 ; i<=50 ;i++)) 
    do
      sleep 1
      let i++
    done
  }

  main &

# EOF
==================



-- 
Best regards,
Daniel



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090606011336.655f0753>