<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></title> 
<link>http://jackxiang.com/index.php</link> 
<description><![CDATA[赢在IT，Playin' with IT,Focus on Killer Application,Marketing Meets Technology.]]></description> 
<language>zh-cn</language> 
<copyright><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></copyright>
<item>
<link>http://jackxiang.com/post//</link>
<title><![CDATA[[实践OK]shell type使用及查找定义的shell函数]]></title> 
<author>jack &lt;xdy108@126.com&gt;</author>
<category><![CDATA[Php/Js/Shell/Go]]></category>
<pubDate>Tue, 22 Oct 2019 07:58:31 +0000</pubDate> 
<guid>http://jackxiang.com/post//</guid> 
<description>
<![CDATA[ 
	type用法，查找对应命令的返回值：<br/>type cwww<br/>cwww is an alias for cd /data/www/<br/><br/>k8s里的shell代码运行：<br/><textarea name="code" class="php" rows="15" cols="100">
function h::fn_exists() &#123;
&nbsp;&nbsp;&nbsp;&nbsp;echo $&#123;1&#125;
&nbsp;&nbsp;&nbsp;&nbsp;$(type &quot;$&#123;1&#125;&quot; 2&gt;/dev/null &#124; grep -q &#039;function&#039;)
&nbsp;&nbsp;&nbsp;&nbsp;return $?
&#125;


run：
+ echo init::all
init::all
++ type init::all
++ grep -q function
+ return 1
</textarea><br/><br/>函数检测：<br/><textarea name="code" class="php" rows="15" cols="100">
g() &#123; return; &#125;
type g
g 是函数
g () 
&#123; 
&nbsp;&nbsp;&nbsp;&nbsp;return
&#125;
type g &gt; /dev/null; echo $? 
0

</textarea><br/>
]]>
</description>
</item><item>
<link>http://jackxiang.com/post//#blogcomment</link>
<title><![CDATA[[评论] [实践OK]shell type使用及查找定义的shell函数]]></title> 
<author> &lt;user@domain.com&gt;</author>
<category><![CDATA[评论]]></category>
<pubDate>Thu, 01 Jan 1970 00:00:00 +0000</pubDate> 
<guid>http://jackxiang.com/post//#blogcomment</guid> 
<description>
<![CDATA[ 
	
]]>
</description>
</item>
</channel>
</rss>