10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Please help me to use echo or printf type of command to print some value from variable within double quotes - I want to print the double quote ( " ") also.
I tried
#!/bin/bash
VALUE=some_value
echo '{"value" : "$VALUE"}'
I was expecting the above script would produce ..
{"value" :... (3 Replies)
Discussion started by: atanubanerji
3 Replies
2. Programming
Hi All,
I want to replace the commas which are not inside parenthesis,quotes
if input is
abc,,lm,(no,pq,rs),{tu,vw,xy},zs,"as,as,fr",'ab,cd,ef'
output should be
abc lm (no,pq,rs) {tu,vw,xy} zs "as,as,fr" 'ab,cd,ef'
I tried this str.replaceAll("\\(.*?\\)|(,)", " "); say my string... (3 Replies)
Discussion started by: preethy
3 Replies
3. Shell Programming and Scripting
HI Guys,
I want to echo below line in my file :-
lpd | grep AL | nawk '{print "1dLA - " $0}
How can i echo same Output (4 Replies)
Discussion started by: pareshkp
4 Replies
4. Shell Programming and Scripting
Hi All,
We need to run a Connect direct script on Unix server to send a file to Mainframe server and at mainframe end there need to run another job through Runtask with some parameters need to be passed from C:D (unix) to mainframe.
My question is I have to pass parameters like DSN and FNAME as... (2 Replies)
Discussion started by: matrix001
2 Replies
5. Shell Programming and Scripting
Consider the following script:
#!/bin/bash
exclude='Archive PST,SystemState'
IFS=$","
rsyncExclusions=$(for exclude in ${exclude}; do echo -n -e --exclude=\"${exclude}\"\ ; done)
unset IFS
echo rsync $rsyncExclusions test
rsync -avh --delete --delete-excluded "$rsyncExclusions"... (7 Replies)
Discussion started by: jelloir
7 Replies
6. Shell Programming and Scripting
I'm a beginner of c shell scripting.
How I can echo a whole line from a file with bracket in it?
Ex. Inside the file.txt
abcd efghi
This is what inside the c shell
set IN_FILE = file.txt
set GREP_KEY = 'abcd'
set IN_LINE = `grep ${GREP_KEY} ${IN_FILE}`
echo $IN_LINE
After... (7 Replies)
Discussion started by: zeahr
7 Replies
7. Shell Programming and Scripting
Hi,
I am generating html code using cshell, but i am having one problem while printing double quotes,
I need to write following code in file. where $var contains list of web address
<a href="$var">$var</a>
So i am using
echo "<a href="$var">$var</a>" > file.html
But with this " in... (4 Replies)
Discussion started by: sarbjit
4 Replies
8. Shell Programming and Scripting
I need to echo a string that has double quotes in a Perl script.
#!/usr/bin/env perl
`echo Rule123 -comment \"blah blah\" >> $filename`
I'd like to get below appended to $filename:
Rule 123 -comment "blah blah"
But instead, the double quotes are lost:
Rule 123 -comment blah bah
... (1 Reply)
Discussion started by: slchin
1 Replies
9. Shell Programming and Scripting
As the title says, echo is striping my quotes and I need them.
echo "<?xml version="1.0" encoding="ISO-8859-1"?>"
returns:
<?xml version=1.0 encoding=ISO-8859-1?>
Obviously,
echo "<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>"
returns the result I need:
<?xml version="1.0"... (3 Replies)
Discussion started by: s_becker
3 Replies
10. Shell Programming and Scripting
Hi,
Please help me to echo the following statement using single quotes
Why can't I write 's between single quotes
Thanks in advance,
Chella (3 Replies)
Discussion started by: chella
3 Replies