Sponsored Content
Full Discussion: Batch file update
Top Forums UNIX for Dummies Questions & Answers Batch file update Post 7954 by cfoxwell on Thursday 4th of October 2001 02:06:32 AM
Old 10-04-2001
Hmm might work, but I've forgot to say one thing..

The shell script that I can run from the command line, has $VAR1 $VAR2 $VAR3 $VAR4 inside the script. So when I run it from the unix prompt I can put in script.ksh 1 2 3 4 for example.

So that $VAR1=1 and so on. Will the example do the same ?
 

9 More Discussions You Might Find Interesting

1. IP Networking

batch file

my requirment is i have to call a batch file from a c++ program that batch file is called with the argument as print.txt print.txt is a text file which should get printed on printer (any printer) when a batch file call is made 1) how to call a batch file in c++ 2) how to print the text... (1 Reply)
Discussion started by: ramneek
1 Replies

2. Programming

batch file

what is a command to call a batch file from a c++ program when called with the argument which is a text file, then how to print that text file on a printer. please help me with code if possible (3 Replies)
Discussion started by: ramneek
3 Replies

3. UNIX for Dummies Questions & Answers

Telnet in batch file

hi how can i connect to a telnet session using the unix script... need to create a batch file which has to run daily. first it has to telnet to a IP then execute certain commands and log the session. thanks Aemu (1 Reply)
Discussion started by: aemunathan
1 Replies

4. UNIX for Advanced & Expert Users

Batch file question

EDIT: Is this wrong thread? Hi I am on an Apple Mac and I am trying to run this batch file on my Mac and was wondering if anyone could tell me what a script that will make this run and work on my Mac. I was hoping that you could tell me the script in the shell format? So here's the batch... (4 Replies)
Discussion started by: Billy5555100
4 Replies

5. Windows & DOS: Issues & Discussions

Creating a batch file..

Hello, this is my first post and i hope you can solve my problem. I need to create a batch file that will copy folder from hard drive on to usb stick on daily basis. Can you help me and write that file and explaine me what to do next. Folder's location is: c\windows\desktop\2009 Thank... (5 Replies)
Discussion started by: hule
5 Replies

6. Shell Programming and Scripting

Batch file to remove double quotes from a file

Hi I have to create a windows batch file which will read an input file and remove "double quotes" from each line of the file. For eg.If input file name is abcd.csv and contents is : "asasd,123123,213213,asd" "esfrf,dsfsdf,234324,sdfsdf" Then the batch file should remove "" from the... (11 Replies)
Discussion started by: akashtcs
11 Replies

7. UNIX for Advanced & Expert Users

batch file

Hi all I am using tru64 Unix and I want a ready batch file which makes me to change all user passwords at the same time ,instead of changing everyone separately. Please could anyone help me to do that. bye. (1 Reply)
Discussion started by: ahmedbashir
1 Replies

8. Shell Programming and Scripting

Executing a batch of files within a shell script with option to refire the individual files in batch

Hello everyone. I am new to shell scripting and i am required to create a shell script, the purpose of which i will explain below. I am on a solaris server btw. Before delving into the requirements, i will give youse an overview of what is currently in place and its purpose. ... (2 Replies)
Discussion started by: goddevil
2 Replies

9. Shell Programming and Scripting

Renaming file in batch

Hi guys, I need a script to change the file names e.g.:- below are the mentioned files, i want t0 change the last character of the name 00000.cdr with e.g bep01.smsc.191214210500-00000.cdr to bep01.smsc.191214210500-92311.cdr next file be like bep01.smsc.191214210500-92312.cdr # ls -ltr... (9 Replies)
Discussion started by: mfaizan40
9 Replies
exit(1) 							   User Commands							   exit(1)

NAME
exit, return, goto - shell built-in functions to enable the execution of the shell to advance beyond its sequence of steps SYNOPSIS
sh exit [n] return [n] csh exit [ ( expr )] goto label ksh *exit [n] *return [n] DESCRIPTION
sh exit will cause the calling shell or shell script to exit with the exit status specified by n. If n is omitted the exit status is that of the last command executed (an EOF will also cause the shell to exit.) return causes a function to exit with the return value specified by n. If n is omitted, the return status is that of the last command exe- cuted. csh exit will cause the calling shell or shell script to exit, either with the value of the status variable or with the value specified by the expression expr. The goto built-in uses a specified label as a search string amongst commands. The shell rewinds its input as much as possible and searches for a line of the form label: possibly preceded by space or tab characters. Execution continues after the indicated line. It is an error to jump to a label that occurs between a while or for built-in command and its corresponding end. ksh exit will cause the calling shell or shell script to exit with the exit status specified by n. The value will be the least significant 8 bits of the specified status. If n is omitted then the exit status is that of the last command executed. When exit occurs when executing a trap, the last command refers to the command that executed before the trap was invoked. An end-of-file will also cause the shell to exit except for a shell which has the ignoreeof option (See set below) turned on. return causes a shell function or '.' script to return to the invoking script with the return status specified by n. The value will be the least significant 8 bits of the specified status. If n is omitted then the return status is that of the last command executed. If return is invoked while not in a function or a '.' script, then it is the same as an exit. On this man page, ksh(1) commands that are preceded by one or two * (asterisks) are treated specially in the following ways: 1. Variable assignment lists preceding the command remain in effect when the command completes. 2. I/O redirections are processed after variable assignments. 3. Errors cause a script that contains them to abort. 4. Words, following a command preceded by ** that are in the format of a variable assignment, are expanded with the same rules as a vari- able assignment. This means that tilde substitution is performed after the = sign and word splitting and file name generation are not performed. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | |Availability |SUNWcsu | +-----------------------------+-----------------------------+ SEE ALSO
break(1), csh(1), ksh(1), sh(1), attributes(5) SunOS 5.10 15 Apr 1994 exit(1)
All times are GMT -4. The time now is 03:16 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy