Hi,
I want to replace _F* by _F in a xml file. what is the sed command.
I have tried sed "s/_F$/_F/g" or sed "s/_F*/_F/g" , but it does not work. thx
file content
<TAG>KC_FOU</TAG>
<TAG>KC_FABC</TAG>
<TAG>KC_FABCDG</TAG>
desire output
<TAG>KC_F</TAG>
<TAG>KC_F</TAG>
<TAG>KC_F</TAG> (6 Replies)
I need to replace (delete) a text block in a bunch of files, its a html table, almost at the end of pages but the location varies.
In Windows I used Filemonkey, but nothing like that in Unix?
There is replace from mysql, but how does it deal with newlines?
sed only works with single lines,... (6 Replies)
Our system is receiving one feed from the third party.
One of the field in the flat file is ID which id from position 19 to 27. In some cases this ID is coming as 9 zeros (000000000) or 1 right padded zero. ( 0)
For these specific records I want to replace fthis field with blank... (3 Replies)
My apologies if this has been answered in a previous post. I've been doing a lot of searching, but I haven't been able to find what I was looking for. Specifically, I am wondering if I can utilize sed and/or awk to locate two strings in a file, and replace everything between those two strings... (12 Replies)
Hi,
My requirement is to find a text and replace it with another in a XML file.
I am new to Unix,Please provide some suggestion to achieve.
Find:
<Style ss:ID="ColumnHeader1">
Replace with:
<Style ss:ID="ColumnHeader1">
<Borders>
<Border ss:Position="Bottom"... (4 Replies)
Hello everyone,
I work under Ubuntu 11.10 (c-shell)
I need a script to create a new text file whose content is the text of another text files that are in the directory $DIRMAIL at this moment.
I will show you an example:
- On the one hand, there is a directory $DIRMAIL where there are... (1 Reply)
I have a file myfile with only one value 1000.I am using it in a shell script.Each time i run the script,the file shud get incremented by 1. I have used the below code for incrementing the value-
curr=`cat myfile`
echo $curr
curr=`expr $curr + 1`
But i am not sure how to save this replaced... (2 Replies)
Hello,
I'm an starter in Bash scripting. I would like to write a script in Bash shell that replaces a specific text block (a function) by another text block in a file:
for example in my file --> $HOME/myFile.js
replacing following function between other functions in the file:
function ABC()... (6 Replies)
Hi,
I am having trouble while using 'sed' with reading files. Please help. I have 3 files. File A, file B and file C. I want to find content of file B in file A and replace it by content in file C.
Thanks a lot!!
Here is a sample of my question.
e.g. (file A: a.txt; file B: b.txt; file... (3 Replies)
Hi,
I am having a files in my directory like this:
2014 1049_file1.txt
2014 1050_file2.txt
2014 1110_file3.txt
2014 1145_file4.txt
2014 2049_file5.txt
I need to replace the above file names like this without changing the content of filename:
file1.txt
file2.txt
file3.txt... (10 Replies)
Discussion started by: rohit_shinez
10 Replies
LEARN ABOUT DEBIAN
latexml::mathparser
LaTeXML::MathParser(3pm) User Contributed Perl Documentation LaTeXML::MathParser(3pm)NAME
"LaTeXML::MathParser" - parses mathematics content
DESCRIPTION
"LaTeXML::MathParser" parses the mathematical content of a document. It uses Parse::RecDescent and a grammar "MathGrammar".
Math Representation
Needs description.
Possibile Customizations
Needs description.
Convenience functions
The following functions are exported for convenience in writing the grammar productions.
"$node = New($name,$content,%attributes);"
Creates a new "XMTok" node with given $name (a string or undef), and $content (a string or undef) (but at least one of name or content
should be provided), and attributes.
"$node = Arg($node,$n);"
Returns the $n-th argument of an "XMApp" node; 0 is the operator node.
"Annotate($node,%attributes);"
Add attributes to $node.
"$node = Apply($op,@args);"
Create a new "XMApp" node representing the application of the node $op to the nodes @args.
"$node = ApplyDelimited($op,@stuff);"
Create a new "XMApp" node representing the application of the node $op to the arguments found in @stuff. @stuff are delimited
arguments in the sense that the leading and trailing nodes should represent open and close delimiters and the arguments are seperated
by punctuation nodes. The text of these delimiters and punctuation are used to annotate the operator node with "argopen", "argclose"
and "separator" attributes.
"$node = recApply(@ops,$arg);"
Given a sequence of operators and an argument, forms the nested application "op(op(...(arg)))">.
"$node = InvisibleTimes;"
Creates an invisible times operator.
"$boole = isMatchingClose($open,$close);"
Checks whether $open and $close form a `normal' pair of delimiters, or if either is ".".
"$node = Fence(@stuff);"
Given a delimited sequence of nodes, starting and ending with open/close delimiters, and with intermediate nodes separated by
punctuation or such, attempt to guess what type of thing is represented such as a set, absolute value, interval, and so on. If nothing
specific is recognized, creates the application of "FENCED" to the arguments.
This would be a good candidate for customization!
"$node = NewFormulae(@stuff);"
Given a set of formulas, construct a "Formulae" application, if there are more than one, else just return the first.
"$node = NewList(@stuff);"
Given a set of expressions, construct a "list" application, if there are more than one, else just return the first.
"$node = LeftRec($arg1,@more);"
Given an expr followed by repeated (op expr), compose the left recursive tree. For example "a + b + c - d" would give "(- (+ a b c)
d)">
"Problem($text);"
Warn of a potential math parsing problem.
"MaybeFunction($token);"
Note the possible use of $token as a function, which may cause incorrect parsing. This is used to generate warning messages.
AUTHOR
Bruce Miller <bruce.miller@nist.gov>
COPYRIGHT
Public domain software, produced as part of work done by the United States Government & not subject to copyright in the US.
perl v5.10.1 2009-06-11 LaTeXML::MathParser(3pm)