<?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>intuitive engineering &#187; Uncategorized</title>
	<atom:link href="http://dougmunsinger.com/category/uncategorized/feed" rel="self" type="application/rss+xml" />
	<link>http://dougmunsinger.com</link>
	<description>doug munsinger</description>
	<lastBuildDate>Fri, 13 Jan 2012 17:08:59 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>TERM=vt220</title>
		<link>http://dougmunsinger.com/2008/08/termvt220.html</link>
		<comments>http://dougmunsinger.com/2008/08/termvt220.html#comments</comments>
		<pubDate>Sat, 30 Aug 2008 01:41:56 +0000</pubDate>
		<dc:creator>doug</dc:creator>
				<category><![CDATA[move5]]></category>
		<category><![CDATA[shell]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[cygwin]]></category>
		<category><![CDATA[UNIX & Windows]]></category>

		<guid isPermaLink="false">http://dougmunsinger.com/?p=254</guid>
		<description><![CDATA[&#160; console2 with cygwin bash shell and ssh behind it (and a lot of other UNIX commands too, like ls, and find and grep and awk and gpg&#8230;) has turned out to be a good solution. I discovered that cygwin sets the terminal as TERM=cygwin. That plays hell with vi on SUN servers. I found [...]]]></description>
			<content:encoded><![CDATA[<p>&nbsp;</p>
<p><a href="http://sourceforge.net/projects/console/" title="console2">console2</a> with <a href="http://www.cygwin.com/" title="cygwin">cygwin</a> bash shell and ssh behind it (and a lot of other UNIX commands too, like ls, and find and grep and awk and gpg&#8230;) has turned out to be a good solution.</p>
<p>I discovered that cygwin sets the terminal as TERM=cygwin.  That plays hell with vi on SUN servers.  I found that setting &#8220;export TERM=vt220&#8243;  in .profile (this is SUN Solaris 10) resolved vi, getting the console2 window to show the display correctly, and letting the arrow keys work again.</p>
<p>A second gotcha &#8211; DON&#8217;T set ctrl-c as copy in the hot-keys.  That ctrl-c you use to break out of errant commands or scripts stops working at all, very disconcerting.  Instead map  shift-ctrl-c.  There&#8217;s an alpha feature enabling tranparency &#8211; looks cool, but isn&#8217;t stable.  Ctrl-r (history searching in bash) is mapped to renaming the tabs for console windows &#8211; you&#8217;ll set that to ctrl-alt-n as below and resolve that. </p>
<p>Here are the settings in console2 I&#8217;ve found to come very close to what I use in Konsole in KDE:</p>
<ul>
<li>base underneath is cygwin &#8211; therefore need &#8220;export TERM=vt220&#8243; in .profile to have vi behave on SUN &#8211; run on command line initially to test and to edit .profile&#8230;</li>
<li>add &#8220;c:\cygwin\bin to path in control panel -> system -> advanced -> environmental variables</li>
<li>console:</li>
<ul>
<li>shell is c:\cygwin\bin\bash.exe</li>
<li>working directory is c:\</li>
<li>buffer size Rows is 5000, columns is 0 </li>
</ul>
<li>appearance:</li>
<ul>
<li>more &#8211; set tabs to always be present (uncheck &#8220;hide single tab&#8221;)</li>
</ul>
<li>behavior:</li>
<ul>
<li>check copy on select</li>
<li>check clear selection on copy</li>
<li>select UNIX LF</li>
</ul>
<li>map hotkeys to emulate konsole</li>
<ul>
<li>shift-left for previous window</li>
<li>shift-right for next</li>
<li>ctrl-alt-n for new windows</li>
<li>ctrl-alt-s for rename</li>
<li>shift-up arrow for line up</li>
<li>shift-arrow down for line down</li>
<li>shift-page-up for page up</li>
<li>shift-page-down for page down </li>
<li>shift-ctrl-c for copy</li>
<li>ctrl-v for paste</li>
</ul>
<li>mouse:</li>
<ul>
<li>right button to paste</li>
<li>set copy on select</li>
<li>left button to select</li>
<li>copy/clear selection is &#8220;none&#8221; </li>
</ul>
<li>tabs:</li>
<ul>
<li>set shell as C:\cygwin\bin\bash.exe</li>
<li>working directory is C:\ </li>
</ul>
</ul>
<p>&nbsp;</p>
<p>&mdash; dsm </p>
<p>&nbsp;</p>
<hr/>
<p>&nbsp;</p>
<p><b>UPDATE 20080904:</b> I installed console2 on all of my windows machines (dual boot, except for work).  It worked perfectly &#8211; then a co-worker tried it out and had issues.  He searched and found that  in some instances cygwin&#8217;s bash shell refused to complete loading and never returns a command prompt.  The solution looks to be a reinstall or upgrade of cygwin, or possibly some difference in the way cygwin was installed.  </p>
<p>I laughed and said, &#8220;It works for me.&#8221;</p>
<p>He said, &#8220;You can tell when you work in an IT shop &#8211; when something fails for someone,  you always get that response &#8211; &#8220;It works for me.&#8221;"  </p>
<p>&nbsp;</p>
<h2>Update 20090329 Sunday</h2>
<p>export TERM=ansi</p>
<p>I installed eclipse with Remote System Explorer.  vt220 caused VI to fail to refresh (at least SUN&#8217;s crippled vi version).  ansi worked much better within RSE.</p>
<p>&mdash; doug</p>
<p>&nbsp;</p>
<div class="addtothis"><p>
				<table cellspacing="0" cellpadding="0" border="0" style="width: 180px; height: 30px; text-align: left; margin-left: 0px; ">
				<tbody>
				<tr>
				<td style="text-align: center;">
				<a href="http://www.stumbleupon.com/submit?url=http://dougmunsinger.com/2008/08/termvt220.html&title=TERM=vt220" rel="nofollow">
                                <img src="http://dougmunsinger.com/wp-content/plugins/addtothis/stumble.png" title="Add to Stumble Upon" alt="Stumble It!" style="border: 0px solid ; width: 28px; height: 28px;"/>
				</a>
				</td>
				<td style="text-align: center;">
				<a href="http://del.icio.us/post?url=http://dougmunsinger.com/2008/08/termvt220.html&title=TERM=vt220" rel="nofollow">
				<img src="http://dougmunsinger.com/wp-content/plugins/addtothis/delicious.png" title="Add to Del.icio.us" alt="Add to Del.cio.us" style="border: 0px solid ; width: 28px; height: 28px;"/>
				</a>
				</td>
				<td style="text-align: center;">
				<a href="http://technorati.com/faves?add=http://dougmunsinger.com/2008/08/termvt220.html" rel="nofollow">
				<img src="http://dougmunsinger.com/wp-content/plugins/addtothis/technorati.png" title="Add to Technorati" alt="Add to Technorati Favorites" style="border: 0px solid ; width: 28px; height: 28px;"/>
				</a>
				</td>
				<td style="text-align: center;">
				<a href="http://digg.com/submit?phase=2&url=http://dougmunsinger.com/2008/08/termvt220.html" rel="nofollow">
				<img src="http://dougmunsinger.com/wp-content/plugins/addtothis/digg.png" title="Add to Digg" alt="Digg It!" style="border: 0px solid ; width: 28px; height: 28px;"/>
				</a>
				</td>
				<td style="text-align: center;">
				<a href="http://dougmunsinger.com/feed/rss" rel="nofollow">
				<img src="http://dougmunsinger.com/wp-content/plugins/addtothis/feeds.png" title="Add Feed to Bookmarks" alt="RSS Feed" style="border: 0px solid ; width: 28px; height: 28px;"/>
				</a>
				</td>
				</tr>
				</tbody>
				</table>

                
		
				</p></div>]]></content:encoded>
			<wfw:commentRss>http://dougmunsinger.com/2008/08/termvt220.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

