<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="../assets/xml/rss.xsl" media="all"?><rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>The Standard Output (windows)</title><link>http://thestandardoutput.com/</link><description></description><atom:link href="http://thestandardoutput.com/tag/windows.xml" type="application/rss+xml" rel="self"></atom:link><language>en</language><lastBuildDate>Mon, 12 Oct 2015 07:59:00 GMT</lastBuildDate><generator>https://getnikola.com/</generator><docs>http://blogs.law.harvard.edu/tech/rss</docs><item><title>Some Notes on Using Git with Cygwin on Windows</title><link>http://thestandardoutput.com/posts/some-notes-on-using-git-with-cygwin-on-windows/</link><dc:creator>Jonas Gorauskas</dc:creator><description>&lt;div&gt;&lt;p&gt;Just recently I rebuilt a system that I use for work. After I installed Cygwin
on it, I started getting some weird errors when using git with ssh to do some
source control tasks.&lt;/p&gt;
&lt;p&gt;When doing a fetch, pull or push to/from origin, or really any git command that
uses ssh to communicate, the ssh client would complain with the error:&lt;/p&gt;
&lt;pre class="code literal-block"&gt;Could not create directory '/home/jgg/.ssh'.
The authenticity of host 'github.com (204.232.175.90)' can't be established.
RSA key fingerprint is 16:27:ac:a5:76:28:2d:36:63:1b:56:4d:eb:df:a6:48.
Are you sure you want to continue connecting (yes/no)?
&lt;/pre&gt;


&lt;p&gt;Once I enter &lt;code&gt;yes&lt;/code&gt;, I get the following:&lt;/p&gt;
&lt;pre class="code literal-block"&gt;Failed to add the host to the list of known hosts (/home/ME/.ssh/known_hosts).
&lt;/pre&gt;


&lt;p&gt;This was happening everytime I was using git under cygwin and very quickly the
situation became completely unsustainable. But after doing a little research, I
found a solution that is pretty simple:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Locate the &lt;code&gt;passwd&lt;/code&gt; file, which is usually at &lt;code&gt;C:\cygwin\etc\&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Open it with your prefered editor&lt;/li&gt;
&lt;li&gt;On the line that starts with your username, change the section that reads
    &lt;code&gt;/home/ME&lt;/code&gt; to read &lt;code&gt;/cygdrive/c/path/to/home/folder/ME&lt;/code&gt; or wherever your
    home folder is.&lt;/li&gt;
&lt;li&gt;Save the changes and restart the Cygwin Terminal&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Expect to see the authenticity check one final time and see the ssh client
actually be able to write to the &lt;code&gt;known_hosts&lt;/code&gt; file.&lt;/p&gt;&lt;/div&gt;</description><category>cygwin</category><category>git</category><category>programming</category><category>windows</category><guid>http://thestandardoutput.com/posts/some-notes-on-using-git-with-cygwin-on-windows/</guid><pubDate>Fri, 24 May 2013 04:55:30 GMT</pubDate></item></channel></rss>