Hello there,
I need to remove carriage return characters (\n and \r) from any input file specified. This is what I am doing right now:
- dumping the file to octal format using the command 'od -c file_name
- removing and \s and \n characters using sed commands
What I need to do now is... (3 Replies)
Hi!
I'm writing a simple script which I call on using a simple html button. The script also recives a simple argument. After the script is done I immediately want to return to my html page. But I dont know how to do that!
#!/bin/sh
echo "Content-type: text/html"
echo ""
if
then echo... (1 Reply)
Hi,
I'm fairly new to UNIX, but hopefully some-one can help me with this:
I am using the following code to find files with the name "example.xml":
find . -name "example.xml" -print
that would print me a list like the example here:
./dir1/dir2/example.xml... (5 Replies)
I have a list of strings, for example:
set strLst = "file1 file2 file3 file4"
I want to log an error if some of the fields happen to begin with -, or have characters like ; : ' , ? ] { =
Which means for example setting
set ierr = 1 (2 Replies)
Hello,
Working on a ksh script and a little stumped... how can I return all characters to the left of the last delimeter per line in a file, skipping any lines without that delimeter?
ie, sample.txt:
Once_upon-a-Midnight_dreary_while
I pondered, weak_and weary
over many a quaint
and... (4 Replies)
Hello all,
I have a directory with 2000+ files. I need to look in each file for an invoice number. To identify this, i can search for the string 'BIG' and then retrieve the next 30 characters. I was thinking awk for this, but not sure how to do it. Each file contains one long string and in... (8 Replies)
Hi,
I am trying to capture logs of the script in the file as well as on the screen. I have used exec and tee command for this. While using exec command I am getting the correct output in the file but, script output is not getting displayed on the screen as it get executed.
Below is my sample... (14 Replies)
Hi,
I am trying to script the below, but I am not very good at it :(
Your help would be greatly appreciated.
1. read all files in the directory in strings
strings *.*
2. in each file, for each line that contains "ABCD", store characters located at position 521 and 522 of this line... (9 Replies)
Not sure where the problem is. I can run the script without any issue using the following command.
. /opt/app/scripts/cdc_migration.sh
But it fails with the below error when I try it this way
/opt/app/scripts/cdc_migration.sh
/opt/app/scripts/cdc_migration.sh: line 65: return: can only... (1 Reply)