
<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title> &#187; find and replace</title>
	<atom:link href="https://www.nikeshshk.com.np/tag/find-and-replace/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.nikeshshk.com.np</link>
	<description></description>
	<lastBuildDate>Tue, 04 Nov 2025 10:25:45 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=4.2.4</generator>
	<item>
		<title>Find and replace text within a file using commands on Linux</title>
		<link>https://www.nikeshshk.com.np/news/find-and-replace-text-within-a-file-using-commands-on-linux/</link>
		<comments>https://www.nikeshshk.com.np/news/find-and-replace-text-within-a-file-using-commands-on-linux/#comments</comments>
		<pubDate>Thu, 23 Jul 2015 05:15:56 +0000</pubDate>
		<dc:creator><![CDATA[admin]]></dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[News]]></category>
		<category><![CDATA[find and replace]]></category>

		<guid isPermaLink="false">http://www.nikeshshk.com.np/?p=834</guid>
		<description><![CDATA[How can I find and replace specific words in a text file using command line? cd /path/to/your/folder/nikeshshakya sed -i &#8216;s/original/new/g&#8217; file.txt Explanation: sed = Stream EDitor -i = in-place (i.e. save back to the original file) The command string: s = the substitute command original = a regular expression describing the word to replace (or just the word itself) new = the text to replace it with g = global (i.e. replace all and not just the first occurrence) file.txt = the file name Or to make replace on all files on folder cd /path/to/your/folder/nikeshshakya sed -i &#8216;s/foo/bar/g&#8217; *]]></description>
				<content:encoded><![CDATA[<p>How can I find and replace specific words in a text file using command line?</p>
<p>cd /path/to/your/folder/nikeshshakya<br />
sed -i &#8216;s/original/new/g&#8217; file.txt<br />
<code>Explanation:</p>
<p>sed = Stream EDitor<br />
-i = in-place (i.e. save back to the original file)<br />
The command string:</p>
<p>s = the substitute command<br />
original = a regular expression describing the word to replace (or just the word itself)<br />
new = the text to replace it with<br />
g = global (i.e. replace all and not just the first occurrence)<br />
file.txt = the file name</code></p>
<p>Or to make replace on all files on folder<br />
cd /path/to/your/folder/nikeshshakya<br />
sed -i &#8216;s/foo/bar/g&#8217; *</p>
]]></content:encoded>
			<wfw:commentRss>https://www.nikeshshk.com.np/news/find-and-replace-text-within-a-file-using-commands-on-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
