I am trying to get the follow script to run in the background on the 'fly'. I can launch it via cron and it will run in the background. BUT when I launch it from the command line it will run in the foreground. I figure it has to do with the while loop I have, but I have no clue how I can run the... (8 Replies)
If I have a file with a bunch of various numbers in one column, how can I make a script to take each number in the file and put in into a command line?
Example:
cat number_file
2
5
8
11
13
34
55
I need a loop to extract each of these numbers and put them into a command line... (1 Reply)
I have a bunch of files named publish.php within subdirs. I need to append a line at the end of each file. I thought I could do it with find and echo like this:
find . -name publish.php -exec echo "<? include('path/to/file.php'); ?>" >> '{}' \;
but that appends the line to a file named {}... (2 Replies)
I am trying to write a script that loops through all the files in the current directory that end in '.slg.gz' and runs a parser on each file. Here is my code:
#!/bin/bash
FILES_HOME = 'dirname $0'
for i in $(ls $FILES_HOME/.slg.gz$);do
./run-feature-parser $(i) > OUTPUT.csv
done ... (1 Reply)
Hello,
i'm trying to implement the times() function and i'm programming in C.
I'm using the "struct tms" structure which consists of the fields:
The tms_utime structure member is the CPU time charged for the execution of user instructions of the calling process.
The tms_stime structure... (1 Reply)
I am having problem looping this script
I want to give the user option to decide if they want to continue after each entry but then also loop it back to beginning so they can more to content of there testcase they just created. I fam new to scripting so loops are little tricky for me.
code I... (7 Replies)
Hello Experts-
We are facing some issues in the while loop script when we use the script time to decide whether to exist from the loop or continue.
Below is the script
SrcExitLoop="FALSE"
Src_InitialStartTime=`date +%s`
Src_StartTime=`date +%s`
Src_NUM_ALERTS=0
TOTAL_ALERTS=`expr <SOME... (4 Replies)
There's probably a better way to do what I'm doing and if so, let me know an alternative.
I have a script that runs rsh for every entry in a txt file to go get the file size off the remote server. I then compare the remote size with a local size.
My script worked fine until recently when I... (2 Replies)
we have one script which we use to send mail in our environment. If we are giving correct attachment script runs fine but if we give a attachment name which is not present on server then this script go to infinite loop and causing all memory to be used. could any one please suggest me what is wrong... (2 Replies)
Discussion started by: anshu ranjan
2 Replies
LEARN ABOUT OSX
iscntrl
ISCNTRL(3) BSD Library Functions Manual ISCNTRL(3)NAME
iscntrl -- control character test
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <ctype.h>
int
iscntrl(int c);
DESCRIPTION
The iscntrl() function tests for any control character. The value of the argument must be representable as an unsigned char or the value of
EOF.
In the ASCII character set, this includes the following characters (preceded by their numeric values, in octal):
000 NUL 001 SOH 002 STX 003 ETX 004 EOT
005 ENQ 006 ACK 007 BEL 010 BS 011 HT
012 NL 013 VT 014 NP 015 CR 016 SO
017 SI 020 DLE 021 DC1 022 DC2 023 DC3
024 DC4 025 NAK 026 SYN 027 ETB 030 CAN
031 EM 032 SUB 033 ESC 034 FS 035 GS
036 RS 037 US 177 DEL
RETURN VALUES
The iscntrl() function returns zero if the character tests false and returns non-zero if the character tests true.
COMPATIBILITY
The 4.4BSD extension of accepting arguments outside of the range of the unsigned char type in locales with large character sets is considered
obsolete and may not be supported in future releases. The iswcntrl() function should be used instead.
SEE ALSO ctype(3), isalnum_l(3), iswcntrl(3), ascii(7)STANDARDS
The iscntrl() function conforms to ISO/IEC 9899:1990 (``ISO C90'').
BSD July 17, 2005 BSD