Sponsored Content
Top Forums Shell Programming and Scripting invoke unix variable in SED command Post 302420277 by vjayraghavan on Tuesday 11th of May 2010 07:38:09 AM
Old 05-11-2010
Thatz working!! Thanks a lot for your help!!
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Need a sed command that uses variable

Hi , Seen some of wonderful posts. Please have look at my problem. I have a text file ketkee.txt , which look like below. GATES := apple mango banana XMLCHECK := red blue green pink My requiement is to find the line that has XMLCHECK in it. and append two variables followed by a space... (2 Replies)
Discussion started by: ketkeep
2 Replies

2. Shell Programming and Scripting

Insert a line including Variable & Carriage Return / sed command as Variable

I want to instert Category:XXXXX into the 2. line something like this should work, but I have somewhere the wrong sytanx. something with the linebreak goes wrong: sed "2i\\${n}Category:$cat\n" Sample: Titel Blahh Blahh abllk sdhsd sjdhf Blahh Blah Blahh Blahh Should look like... (2 Replies)
Discussion started by: lowmaster
2 Replies

3. UNIX for Dummies Questions & Answers

sed insert command and variable expansion/command substitution

I know this script is crummy, but I was just messing around.. how do I get sed's insert command to allow variable expansion to show the filename? #!/bin/bash filename=`echo $0` /usr/bin/sed '/#include/ { i\ the filename is `$filename` }' $1 exit 0 (8 Replies)
Discussion started by: glev2005
8 Replies

4. UNIX and Linux Applications

how to invoke the mail from unix ?

How to send mail to users from linux machine when ceratin task finished ? (1 Reply)
Discussion started by: saku
1 Replies

5. Shell Programming and Scripting

Using sed command replace date variable in unix

I need to use a shell script, using sed command how to replace date variable value in following format. 04/18/2012 11:38:55 Because the sed is treating the '/' as a parameter instead of the value of a variable, and hence there is the message as sed: command garbled: s/insert/04/18/2012... (9 Replies)
Discussion started by: jannusuresh
9 Replies

6. Shell Programming and Scripting

sed command to take variable

I have file File1.txt in which i have to replace a text using sed command File1.txt contents EURAMOUNTTOBEREPLACED I have a AIX shell script for replacing the text AMOUNTTOBEREPLACED Contents of the shell script sum=27 sed 's/AMOUNTTOBEREPLACED/"$sum"/g' File1.txt >> temp mv temp... (5 Replies)
Discussion started by: bk_12345
5 Replies

7. Shell Programming and Scripting

sed command with variable

Hi, I want to insert some text in the begning of each line. But issue is the text that i want to insert is stored into one variable. so my command look like constr="`date | awk '{print $3"-"$2"-"$6}'`",MXGBTST1" " sed 's/^/\$constr/g' alert_temp.csv but sed command instead of taking... (3 Replies)
Discussion started by: ranvijaidba
3 Replies

8. Shell Programming and Scripting

Using a variable in sed command

Hi All, Can I use a variable (using this variable as a counter) in sed cmd? something like below sed -n '${COUNT}p' But it's not working. Pls help. Thanks. Regards, Amee export COUNT=1 export COUNTER=`cat ${BINPATH}/$ALLOC_FILE.clean_1 | wc -l | tr -d " "` while ... (3 Replies)
Discussion started by: Amee5
3 Replies

9. UNIX for Beginners Questions & Answers

Variable in sed command

Hi All, How can i use a variable in a sed command ? I cant seem to get it to work as at present its just printing $i at the start of every line rather than the variable $1. sed -e "s/^/\$i,|/" Any help would be appreciated. (3 Replies)
Discussion started by: mutley2202
3 Replies

10. Shell Programming and Scripting

Using a variable in sed command

Hi All, Please help me with the below problem if then $a=" " fi echo "ABC1abc" | sed 's/a/'$a'/' The required output is : ABC abc But I am getting the below error: sed: -e expression #1, char 4: unterminated `s' command Please help. (6 Replies)
Discussion started by: rahulsk
6 Replies
JABLICATOR(1)						      General Commands Manual						     JABLICATOR(1)

NAME
jablicator - Share package collection choice across machines SYNOPSIS
jablicator [--root <path>] DESCRIPTION
jablicator generates an "apt-get"-able package. The package itself is empty. However it has a dependency for every non-required Debian package that is on the machine. This program will create and populate two directories dists and pool in your working directory. You can then move them to a web accessible location. This utility is designed to reduce software distribution and maintenance costs by reducing redundant system administration. For example, I have spent a lot of time finding and vetting image processing software from Debian's large package collection. With this utility, my image processing colleague down the hall can easily benefit from the fruit of my labor. There are many replication techniques in Debian. This one has the advantage of using the apt and dpkg infrastructure. A disadvantage is the possibility of packages changing out from under you in the Debian distribution (especially in testing or unstable). That means that jabli- cator output can grow stale over time if it is not regenerated. SECURITY
The packages produced by this program contain a lot of information, including a list of the Debian packages installed on the machine and a listing of apt-get sources. Some system administrators consider sharing such information a security risk. FILES
/etc/apt/sources.list OPTIONS
--root <path> Being able to pull in package selections from another install can be helpful, in the cases of a non-functional system, or reading from a hard drive install under Knoppix. In other words, source from a root filesystem that is not mounted at the root. This is a rare situation and most users should not use this option. SEE ALSO
dpkg(8) apt-get(8). AUTHOR
Jeff Breidenbach <jab@debian.org>. THANKS
Tom Parks, Cliff Weinstein, Burkhard Perkens-Golomb. Debian/GNU Linux September 2001 JABLICATOR(1)
All times are GMT -4. The time now is 07:31 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy