<?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: screen 跟 ssh</title>
	<atom:link href="http://blog.rafan.org/archives/145/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.rafan.org/archives/145</link>
	<description>rafan? rafan!</description>
	<lastBuildDate>Wed, 03 Mar 2010 13:55:10 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=3.0-alpha</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: 在 screen 裡顯示 vi 正在編輯的檔案 [JeffHung.Blog]</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2230</link>
		<dc:creator>在 screen 裡顯示 vi 正在編輯的檔案 [JeffHung.Blog]</dc:creator>
		<pubDate>Thu, 16 Aug 2007 02:40:07 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2230</guid>
		<description>[...] 在問，怎樣在 screen 裡顯示 ssh 出去的 hostname。這個以前我有搞過類似的：在 screen 裡顯示 vi [...]</description>
		<content:encoded><![CDATA[<p>[...] 在問，怎樣在 screen 裡顯示 ssh 出去的 hostname。這個以前我有搞過類似的：在 screen 裡顯示 vi [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rafan</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2224</link>
		<dc:creator>rafan</dc:creator>
		<pubDate>Fri, 10 Aug 2007 02:48:20 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2224</guid>
		<description>呃, 我知道為甚麼 alias 沒用了 XD</description>
		<content:encoded><![CDATA[<p>呃, 我知道為甚麼 alias 沒用了 XD</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rafan</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2223</link>
		<dc:creator>rafan</dc:creator>
		<pubDate>Fri, 10 Aug 2007 02:24:31 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2223</guid>
		<description>感謝大家, 後來我用 sothat 的方法, 然後 bash 相對應的寫法是

last=${!#}

不過因為某些因素，我要寫在 .bashrc 裡面用 function 處理，可是這樣子 command alias 沒有用?</description>
		<content:encoded><![CDATA[<p>感謝大家, 後來我用 sothat 的方法, 然後 bash 相對應的寫法是</p>
<p>last=${!#}</p>
<p>不過因為某些因素，我要寫在 .bashrc 裡面用 function 處理，可是這樣子 command alias 沒有用?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: sothat</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2222</link>
		<dc:creator>sothat</dc:creator>
		<pubDate>Thu, 09 Aug 2007 19:59:12 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2222</guid>
		<description>$last:ar is better.</description>
		<content:encoded><![CDATA[<p>$last:ar is better.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: sothat</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2221</link>
		<dc:creator>sothat</dc:creator>
		<pubDate>Thu, 09 Aug 2007 19:45:33 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2221</guid>
		<description>#!/bin/tcsh -f
set last=$argv[$#argv]
screen -t &quot;&gt; &#124; $last&quot;&quot;:&quot; ssh $*
# 遠端的 prompt 也要 prompt 設好才行

Btw, 前幾天剛好在玩 vim 可以設 screen title
if $TERM == &quot;screen&quot;
    &quot; set title
    set t_ts=^[k
    set t_fs=^[\
    auto BufEnter * :set title &#124; let &amp;titlestring = &#039;vim:&#039; . expand(&#039;%&#039;)
    &quot; auto VimLeave * :set notitle
endif</description>
		<content:encoded><![CDATA[<p>#!/bin/tcsh -f<br />
set last=$argv[$#argv]<br />
screen -t &#8220;&gt; | $last&#8221;":&#8221; ssh $*<br />
# 遠端的 prompt 也要 prompt 設好才行</p>
<p>Btw, 前幾天剛好在玩 vim 可以設 screen title<br />
if $TERM == &#8220;screen&#8221;<br />
    &#8221; set title<br />
    set t_ts=^[k<br />
    set t_fs=^[\<br />
    auto BufEnter * :set title | let &amp;titlestring = &#8216;vim:&#8217; . expand(&#8216;%&#8217;)<br />
    &#8221; auto VimLeave * :set notitle<br />
endif</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: atomer</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2220</link>
		<dc:creator>atomer</dc:creator>
		<pubDate>Thu, 09 Aug 2007 07:11:01 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2220</guid>
		<description>我則是在 .bash_profile 中加

if [ &quot;x${TERM}&quot; = &quot;xscreen&quot; ]; then
    PS1=&quot;${PS1}\[33\]k\h\[33\]\\&quot;;
fi</description>
		<content:encoded><![CDATA[<p>我則是在 .bash_profile 中加</p>
<p>if [ "x${TERM}" = "xscreen" ]; then<br />
    PS1=&#8221;${PS1}\[33\]k\h\[33\]\\&#8221;;<br />
fi</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: WanCW</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2219</link>
		<dc:creator>WanCW</dc:creator>
		<pubDate>Wed, 08 Aug 2007 18:09:05 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2219</guid>
		<description>修正: title-string escape-sequence 是 &quot;ESCk&lt;title&gt;ESC\&quot;</description>
		<content:encoded><![CDATA[<p>修正: title-string escape-sequence 是 &#8220;ESCk&lt;title&gt;ESC\&#8221;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: WanCW</title>
		<link>http://blog.rafan.org/archives/145/comment-page-1#comment-2218</link>
		<dc:creator>WanCW</dc:creator>
		<pubDate>Wed, 08 Aug 2007 18:07:17 +0000</pubDate>
		<guid isPermaLink="false">http://blog.rafan.org/archives/145#comment-2218</guid>
		<description>直接利用 title-string escape-sequence (&quot;ESCkESC\&quot;) 呀。

--
我之前的作法是
寫一個 wrapper script 利用 $0 判斷 hostname,
根據 hostname 決定 title 後再利用 escape sequence 改變。
然後替常用的 host 分別建 symbolic link。</description>
		<content:encoded><![CDATA[<p>直接利用 title-string escape-sequence (&#8220;ESCkESC\&#8221;) 呀。</p>
<p>&#8211;<br />
我之前的作法是<br />
寫一個 wrapper script 利用 $0 判斷 hostname,<br />
根據 hostname 決定 title 後再利用 escape sequence 改變。<br />
然後替常用的 host 分別建 symbolic link。</p>
]]></content:encoded>
	</item>
</channel>
</rss>
