<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Remote Diff</title>
	<atom:link href="http://www.barneyb.com/barneyblog/2005/09/20/remote-diff/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/</link>
	<description>Thoughts, rants, and even some code from the mind of Barney Boisvert.</description>
	<lastBuildDate>Thu, 11 Sep 2014 09:58:12 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Bhargav Kesavan</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-462635</link>
		<dc:creator>Bhargav Kesavan</dc:creator>
		<pubDate>Fri, 31 Jan 2014 11:01:52 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-462635</guid>
		<description>I think the brackets didn&#039;t show up in my previous comment.

It&#039;s like this

rsync -nr remote_server:/home/bkesavan/test/ Local_server_dir_path</description>
		<content:encoded><![CDATA[<p>I think the brackets didn't show up in my previous comment.</p>
<p>It's like this</p>
<p>rsync -nr remote_server:/home/bkesavan/test/ Local_server_dir_path</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bhargav Kesavan</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-462634</link>
		<dc:creator>Bhargav Kesavan</dc:creator>
		<pubDate>Fri, 31 Jan 2014 11:00:39 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-462634</guid>
		<description>Thanks for your reply Barney.

I&#039;ve tried it using rsync and it&#039;s working fine for me.

I used rsync -nr :/home/bkesavan/test/ 

Thank you.</description>
		<content:encoded><![CDATA[<p>Thanks for your reply Barney.</p>
<p>I've tried it using rsync and it's working fine for me.</p>
<p>I used rsync -nr :/home/bkesavan/test/ </p>
<p>Thank you.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: barneyb</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-462493</link>
		<dc:creator>barneyb</dc:creator>
		<pubDate>Thu, 30 Jan 2014 19:17:08 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-462493</guid>
		<description>Bhargav, 

The first half of your command is trying to execute a directory via SSH, which doesn&#039;t make any sense.  That&#039;s what the error message is showing.  My script used SCP to move files locally and do a local diff.  An improvement is to use a stream (as Amit suggested above), though that only allows for one remote file (not two).  A directory can&#039;t be streamed like that, however, you&#039;ll need to walk the directory and do file-by-file comparisons unless you pull the whole directory to the local machine and do a local recursive diff.

So the short answer is &quot;no, not really&quot;.</description>
		<content:encoded><![CDATA[<p>Bhargav, </p>
<p>The first half of your command is trying to execute a directory via SSH, which doesn't make any sense.  That's what the error message is showing.  My script used SCP to move files locally and do a local diff.  An improvement is to use a stream (as Amit suggested above), though that only allows for one remote file (not two).  A directory can't be streamed like that, however, you'll need to walk the directory and do file-by-file comparisons unless you pull the whole directory to the local machine and do a local recursive diff.</p>
<p>So the short answer is "no, not really".</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bhargav Kesavan</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-462492</link>
		<dc:creator>Bhargav Kesavan</dc:creator>
		<pubDate>Thu, 30 Jan 2014 19:06:15 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-462492</guid>
		<description>Hi,

Thanks for sharing this useful information.

I&#039;m trying to do a diff between remote servers for directories.

&lt;pre&gt;ssh  &quot;/home/bkesavan&quot; &#124; diff -S /home/bkesavan/
&lt;/pre&gt;

I&#039;ve tried multipe variables there (S,s,p,q,r) etc, but I can only see the below response
bash: /home/bkesavan: is a directory

Is it achievable through diff?</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>Thanks for sharing this useful information.</p>
<p>I'm trying to do a diff between remote servers for directories.</p>
<pre>ssh  "/home/bkesavan" | diff -S /home/bkesavan/
</pre>
<p>I've tried multipe variables there (S,s,p,q,r) etc, but I can only see the below response<br />
bash: /home/bkesavan: is a directory</p>
<p>Is it achievable through diff?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Aymen</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-258758</link>
		<dc:creator>Aymen</dc:creator>
		<pubDate>Fri, 27 May 2011 10:32:05 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-258758</guid>
		<description>Nice script !
but i think it require that the two folders have the same files.

if a file exists only in local dire, what will say this script

Thanks</description>
		<content:encoded><![CDATA[<p>Nice script !<br />
but i think it require that the two folders have the same files.</p>
<p>if a file exists only in local dire, what will say this script</p>
<p>Thanks</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: The Best Place on Earth</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-221149</link>
		<dc:creator>The Best Place on Earth</dc:creator>
		<pubDate>Fri, 24 Sep 2010 00:39:13 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-221149</guid>
		<description>Recursive remote diff:

cd {local-dir}

for i in `find {subdir} -type f ` ; do echo &quot;=== $i ===&quot; ; ssh {remote-user}@{remote-host} &quot;cat {remote-dir}/$i&quot; &#124; diff - {local-dir}/$i ; done

Example:

cd ~/root-of-my-local-project-dir

for i in `find app/controllers/ -type f ` ; do echo &quot;=== $i ===&quot; ; ssh bob@foo.remote-server.com &quot;cat root-of-remote-project-dir/$i&quot; &#124; diff - ~/root-of-my-local-project-dir/$i ; done

Note: {subdir} can be &quot;.&quot; if you want everything from {local-dir}</description>
		<content:encoded><![CDATA[<p>Recursive remote diff:</p>
<p>cd {local-dir}</p>
<p>for i in `find {subdir} -type f ` ; do echo "=== $i ===" ; ssh {remote-user}@{remote-host} "cat {remote-dir}/$i" | diff &#8211; {local-dir}/$i ; done</p>
<p>Example:</p>
<p>cd ~/root-of-my-local-project-dir</p>
<p>for i in `find app/controllers/ -type f ` ; do echo "=== $i ===" ; ssh <a href="mailto:bob@foo.remote-server.com">bob@foo.remote-server.com</a> "cat root-of-remote-project-dir/$i" | diff &#8211; ~/root-of-my-local-project-dir/$i ; done</p>
<p>Note: {subdir} can be "." if you want everything from {local-dir}</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Wawrzek</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-159428</link>
		<dc:creator>Wawrzek</dc:creator>
		<pubDate>Wed, 28 Jan 2009 16:10:42 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-159428</guid>
		<description>A bit tweaked version of your script:

http://larryn.blogspot.com/2009/01/remote-diff.html</description>
		<content:encoded><![CDATA[<p>A bit tweaked version of your script:</p>
<p><a href="http://larryn.blogspot.com/2009/01/remote-diff.html" rel="nofollow">http://larryn.blogspot.com/2009/01/remote-diff.html</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Amit</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-158018</link>
		<dc:creator>Amit</dc:creator>
		<pubDate>Fri, 23 Jan 2009 23:16:43 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-158018</guid>
		<description>That was a solution suggested to me by my Perl/Unix instructor, the revered Dr. Tim Maher. The beauty of it is that it cleans up after itself.</description>
		<content:encoded><![CDATA[<p>That was a solution suggested to me by my Perl/Unix instructor, the revered Dr. Tim Maher. The beauty of it is that it cleans up after itself.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: barneyb</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-157970</link>
		<dc:creator>barneyb</dc:creator>
		<pubDate>Fri, 23 Jan 2009 19:48:41 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-157970</guid>
		<description>@Amit

That is definitely a better solution.  In my defense, when I posted this (3.5 years ago) I didn&#039;t &quot;get&quot; that `ssh` could be anything more than a secure remote interactive shell.  I&#039;ve since learned better.  : )</description>
		<content:encoded><![CDATA[<p>@Amit</p>
<p>That is definitely a better solution.  In my defense, when I posted this (3.5 years ago) I didn't "get" that `ssh` could be anything more than a secure remote interactive shell.  I've since learned better.  : )</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Amit</title>
		<link>https://www.barneyb.com/barneyblog/2005/09/20/remote-diff/comment-page-1/#comment-157966</link>
		<dc:creator>Amit</dc:creator>
		<pubDate>Fri, 23 Jan 2009 19:40:05 +0000</pubDate>
		<guid isPermaLink="false">http://barneyb.com/barneyblog/?p=120#comment-157966</guid>
		<description>The simplest way to do remote diff is as follows:
ssh {remote_host} cat {remote_file} &#124; diff {local_file} -</description>
		<content:encoded><![CDATA[<p>The simplest way to do remote diff is as follows:<br />
ssh {remote_host} cat {remote_file} | diff {local_file} -</p>
]]></content:encoded>
	</item>
</channel>
</rss>
