Sponsored Content
Full Discussion: how to goto in ksh
Top Forums Shell Programming and Scripting how to goto in ksh Post 48621 by Perderabo on Thursday 11th of March 2004 02:22:50 PM
Old 03-11-2004
Try something like:
Code:
[[ -f $LOGFILE ]] && read lastjob <$LOGFILE
for xjob in job1 job2 job3 job4 job5 job6 ; do
       if [[ -z $lastjob || $lastjob = $xjob ]] ; then
            ./$xjob || {echo $xjob > $LOGFILE ; exit 1 ; }
       fi
done

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

GOTO LOOP in KORNE SHELL

All Please help to provide "goto" functionality in KORN shell script. ex: 1: Command Process some command if check some variable true goto 1 else process some other Please help to implement this example in korne... (1 Reply)
Discussion started by: DeepakXavier
1 Replies

2. Shell Programming and Scripting

Use of GOTO statement in scripts

Hey Guys.. I just want to know how to use Goto statement in shell scripts. I know the basic use of statement. Goto Label The above statement will search for some label which must be defined in the script itself as: label: I tried these combinations but I didn't work out for me and I'm... (7 Replies)
Discussion started by: vikasduhan
7 Replies

3. Shell Programming and Scripting

goto statement

I have a test script for using goto statement but its not working. please help i tried both in linux and hp-ux it's not working please help #! /bin/ksh t=`ps -ef|grep ti.sh|grep -v grep` if ; then goto start else goto stop fi start: echo "start" stop: echo "stop" (5 Replies)
Discussion started by: Krrishv
5 Replies

4. UNIX for Dummies Questions & Answers

Stuck after typing goto

uname -a returns: SMP Tue May 17 17:52:23 EDT 2005 i686 athlon i386 GNU/Linux I have many aliases beginning with "goto" so... if I type goto and then hit return (oops) A goto prompt pops up and I cant exit from it(I tried MANY key seqs) The only way to exit is to kill the term window... (2 Replies)
Discussion started by: rairey
2 Replies

5. Solaris

Goto last visted directory

Dear All, Can any one pls let me the command for how to goback to previous visited directory from the current working directory in SunOS ? In case of HP-UX; the same can be resolved through "cd -" command. Thanks in advance! Prasanth Babu. (6 Replies)
Discussion started by: prasanth_babu
6 Replies

6. Shell Programming and Scripting

Using A Goto Label?

Im trying to do something like this but I cant find any documentation. read X if then goto ThisLine fi OTHER CODE OTHER CODE Label: ThisLine echo "You entered 1" (5 Replies)
Discussion started by: Grizzly
5 Replies

7. Shell Programming and Scripting

Alternative for goto

#!/bin/sh label: echo sql poll v=`sqlplus -s <<! HR/HR set pages 0 echo off feed off select distinct status from emp where id=5; ! ` echo $v; echo it comes here after false if then echo if condition true sqlplus -l scott/tiger <<EOF select * from department; EXIT (2 Replies)
Discussion started by: kumaar1986
2 Replies

8. Shell Programming and Scripting

Goto - UNIX v6 Manual Questions

Hey :) I am trying to understand the command goto. I have some questions regarding the goto manual. 1.What does the underlined part mean? I'm not allowed to type goto in the shell? But if goto is written into a file everything is okay? 2.So if a part of my file looks like this ... goto... (8 Replies)
Discussion started by: orbit
8 Replies

9. Ubuntu

Use of goto keyword in kernel programming

I have found many source files in the kernel using goto keyword instead of just doing the actual thing. For example: if(blah) goto x; -- -- -- -- -- x: return blah-blah Is there any specific reason for writing the code like this? The first thought that came to my mind is minimizing... (0 Replies)
Discussion started by: BHASKAR JUPUDI
0 Replies

10. Shell Programming and Scripting

A dash to GOTO or a dash from GOTO, that is the question...

Well, guys I saw a question about GOTO for Python. So this gave me the inspiration to attempt a GOTO function for 'dash', (bash and ksh too). Machine: MBP OSX 10.14.3, default bash terminal, calling '#!/usr/local/bin/dash'... This is purely a fun project to see if it is possible in PURE... (3 Replies)
Discussion started by: wisecracker
3 Replies
IRCD-RATBOX(8)						  System Administration Commands					    IRCD-RATBOX(8)

NAME
ircd-ratbox - Advanced, stable and fast ircd SYNOPSIS
ircd-ratbox [-help | -version] ircd-ratbox [-basedir BASEDIR] [-configfile CONFFILE] [-logfile LOGFILE] [-pidfile PIDFILE] [-foreground] [-conftest] DESCRIPTION
ircd-ratbox is the main ircd daemon responsible for running the IRC server. It delegates specific tasks to several other daemons: resolver, ssld, bandb. OPTIONS
-help Show summary of options. -version Display version information. -basedir BASEDIR Before starting the server, enter BASEDIR directory (chdir). -configfile CONFFILE Set configuration file (defaults to /etc/ircd-ratbox/ircd.conf). -logfile LOGFILE Set main log path (defaults to /var/log/ircd-ratbox/ircd.log). -pidfile PIDFILE Set file used to store main daemon PID (defaults to /etc/ircd-ratbox/ircd.pid). -foreground Don't detach process in the background. -conftest Check configuration and exit. AUTHOR
Marc `Duck` Dequenes <Duck@DuckCorp.org> Original author. COPYRIGHT
Copyright (C) 2011 Marc Dequenes (Duck) This manual page was written for the Debian system (but may be used by others). Permission is granted to copy, distribute and/or modify this document under the terms of the GNU General Public License, Version 3 or any later version published by the Free Software Foundation. On Debian systems, the complete text of the GNU General Public License version 3 can be found in /usr/share/common-licenses/GPL-3. ircd ratbox 2011-11-07 IRCD-RATBOX(8)
All times are GMT -4. The time now is 06:52 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy