Hi all!
Here is my problem :
$ more file
yougli:passwd:123456:3265:Yepa Yepo:/home/yougli:/bin/ksh
As you can see, in the field "information", there are two spaces between "Yepa" and "yepo".
My problem is :
$ PARAM='more file | cut -d":" -f5'
$ echo $PARAM
Yepa Yepo
Now i only... (2 Replies)
I am trying to take one part of my text from file and save it to variable $x
I tryed this...
x=`cut -c 6-9 $fajl`
my file looks like this
fajl:
21890001277 89386911 23638FBCDC 28EE01A1 0000 26855 124 244326
21890001277 89766911 23638FBCDC 28E021A1 0000 26557 134 684326
21890001277... (7 Replies)
Guys,
I've a problem in the "sed" command used in my shellscripts
This is the problamatic line in my shell script:
sed -e 's/${line1}/${line1_m}/g' prod_hier_1234.txt > test.txt
It doesn't do the job of replacing the string stored in variable 'line1' to 'line1_m'.
However If I replace the... (10 Replies)
Hi Guru's,
I 'm trying to execute the below given script in Unix. I am having an issue with the script. The output of the script is given below:
#!/bin/bash
File_Home="/home/essftp/Risk"
cd /home/essftp/Risk
rm -f FileList
rm -f credit_risk*
file1=`ls -lt... (4 Replies)
Hi
I have a strange problem when using cut command
when i am using the below command, it is working fine,I am getting the data in new file xyz.dat
cut -c 1-75 abc.dat > xyz.dat
when i am using the below command, I am getting the data in new file abc.dat , but empty file
cut -c 1-75... (4 Replies)
Hi!
I get a md5 hash of a file with this command:
openssl md5 /Users/me/MyLogo.png | cut -f 2 -d ' '
"cut" because I just want the hash. But there is a problem -> that doen't work with a path with spaces:
openssl md5 /Users/me/MyLogo 2.png | cut -f 2 -d ' '
The result is "2.png)=" ...... (1 Reply)
Hi,
I have used expr command to increment the date.
for e.g.,
case 1 :
echo $(date -d $(echo `expr 20010101 + 1`))
it returns
Tue Jan 2 00:00:00 IST 2001
case 2:
echo $(date -d $(echo `expr 20010101 - 1`))
it returns
date: invalid date `20010100'
please suggest me, how to... (3 Replies)
I am writing a shell script to skip couple of feilds in a flat file and as a part of this I have written the below piece of code in it.
cut -d '|' -f 1-17,19-31 $1 > filename
To add pipe at end of the line I used below command, but it adds even to header and footer as well which i... (11 Replies)
Hi Friend ,
i have one file say xyz.lst and it has content like
dn: cn=m.hariharan,cn=employee,cn=delhi circle,cn=users,dc=industowers,dc=c
dn: cn=ajay.jain,cn=employee,cn=gujarat circle,cn=users,dc=industowers,dc=com
dn: cn=ajitkumar.thakor,cn=employee,cn=gujarat... (4 Replies)
There is a text file in my project named as "mom.txt" in which i want to have contents like..................
LSCRM(Application Name):
1: This is my first application.
2: Today we did shell scripting automation for this app.
3: It was really a good fun in doing so.
4: Really good.| (Here i... (7 Replies)
Discussion started by: Abhijeet Anand
7 Replies
LEARN ABOUT SUSE
shcomp
SHCOMP(1) Korn shell utilities SHCOMP(1)NAME
shcomp - compile a shell script
SYNOPSIS
shcomp [ options ] [infile [outfile]]
DESCRIPTION
Unless -D is specified, shcomp takes a shell script, infile, and creates a binary format file, outfile, that ksh can read and execute with
the same effect as the original script.
Since aliases are processed as the script is read, alias definitions whose value requires variable expansion will not work correctly.
If -D is specified, all double quoted strings that are preceded by $ are output. These are the messages that need to be translated to
locale specific versions for internationalization.
If outfile is omitted, then the results will be written to standard output. If infile is also omitted, the shell script will be read from
standard input.
OPTIONS
[D dictionary] Generate a list of strings that need to be placed in a message catalog for internationalization. [n noexec] Displays warn-
ing messages for obsolete or non-conforming constructs. [v verbose] Displays input from infile onto standard error as it reads it.
EXIT STATUS
0
Successful completion.
>0
An error occurred.
SEE ALSO ksh(1)IMPLEMENTATION
version
shcomp (AT&T Research) 2003-03-02
author
David Korn <dgk@research.att.com>
copyright
Copyright (c) 1982-2010 AT&T Intellectual Property
license
http://www.opensource.org/licenses/cpl1.0.txt
2003-03-02 SHCOMP(1)