<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>bash &amp;mdash; devops</title>
    <link>https://write.rpod.club/devops/tag:bash</link>
    <description></description>
    <pubDate>Tue, 20 Oct 2026 06:23:24 +0000</pubDate>
    <item>
      <title>Неявные сокращения в bash</title>
      <link>https://write.rpod.club/devops/neiavnye-sokrashcheniia-v-bash</link>
      <description>&lt;![CDATA[bash&#xA;&#xA;&amp;&#x9;Run the previous command in the background&#x9;ls &amp;&#xA;&amp;&amp;&#x9;Logical AND&#x9;if [ &#34;$foo&#34; -ge &#34;0&#34; ] &amp;&amp; [ &#34;$foo&#34; -le &#34;9&#34;]&#xA;||&#x9;Logical OR&#x9;if [ &#34;$foo&#34; -lt &#34;0&#34; ] || [ &#34;$foo&#34; -gt &#34;9&#34; ]&#xA;^&#x9;Start of line&#x9;grep &#34;^foo&#34;&#xA;$&#x9;End of line&#x9;grep &#34;foo$&#34;&#xA;=&#x9;String equality (cf. -eq)&#x9;if [ &#34;$foo&#34; = &#34;bar&#34; ]&#xA;!&#x9;Logical NOT&#x9;if [ &#34;$foo&#34; != &#34;bar&#34; ]&#xA;$$&#x9;PID of current shell&#x9;echo &#34;my PID = $$&#34;&#xA;$!&#x9;PID of last background command&#x9;ls &amp; echo &#34;PID of ls = $!&#34;&#xA;$?&#x9;exit status of last command&#x9;ls ; echo &#34;ls returned code $?&#34;&#xA;$0&#x9;Name of current command (as called)&#x9;echo &#34;I am $0&#34;&#xA;$1&#x9;Name of current command&#39;s first parameter&#x9;echo &#34;My first argument is $1&#34;&#xA;$9&#x9;Name of current command&#39;s ninth parameter&#x9;echo &#34;My ninth argument is $9&#34;&#xA;$@&#x9;All of current command&#39;s parameters (preserving whitespace and quoting)&#x9;echo &#34;My arguments are $@&#34;&#xA;$&#x9;All of current command&#39;s parameters (not preserving whitespace and quoting)&#x9;echo &#34;My arguments are $&#34;&#xA;-eq&#x9;Numeric Equality&#x9;if [ &#34;$foo&#34; -eq &#34;9&#34; ]&#xA;-ne&#x9;Numeric Inquality&#x9;if [ &#34;$foo&#34; -ne &#34;9&#34; ]&#xA;-lt&#x9;Less Than&#x9;if [ &#34;$foo&#34; -lt &#34;9&#34; ]&#xA;-le&#x9;Less Than or Equal&#x9;if [ &#34;$foo&#34; -le &#34;9&#34; ]&#xA;-gt&#x9;Greater Than&#x9;if [ &#34;$foo&#34; -gt &#34;9&#34; ]&#xA;-ge&#x9;Greater Than or Equal&#x9;if [ &#34;$foo&#34; -ge &#34;9&#34; ]&#xA;-z&#x9;String is zero length&#x9;if [ -z &#34;$foo&#34; ]&#xA;-n&#x9;String is not zero length&#x9;if [ -n &#34;$foo&#34; ]&#xA;-nt&#x9;Newer Than&#x9;if [ &#34;$file1&#34; -nt &#34;$file2&#34; ]&#xA;-d&#x9;Is a Directory&#x9;if [ -d /bin ]&#xA;-f&#x9;Is a File&#x9;if [ -f /bin/ls ]&#xA;-r&#x9;Is a readable file&#x9;if [ -r /bin/ls ]&#xA;-w&#x9;Is a writable file&#x9;if [ -w /bin/ls ]&#xA;-x&#x9;Is an executable file&#x9;if [ -x /bin/ls ]&#xA;( ... )&#x9;Function definition&#x9;function myfunc() { echo hello }]]&gt;</description>
      <content:encoded><![CDATA[<p><a href="/devops/tag:bash" class="hashtag" rel="nofollow"><span>#</span><span class="p-category">bash</span></a></p>

<p>&amp;   Run the previous command in the background  ls &amp;
&amp;&amp;  Logical AND if [ “$foo” -ge “0” ] &amp;&amp; [ “$foo” -le “9”]
||  Logical OR  if [ “$foo” -lt “0” ] || [ “$foo” -gt “9” ]
^   Start of line   grep “^foo”
$   End of line grep “foo$”
=   String equality (cf. -eq)   if [ “$foo” = “bar” ]
!   Logical NOT if [ “$foo” != “bar” ]
$$  PID of current shell    echo “my PID = $$”
$!  PID of last background command  ls &amp; echo “PID of ls = $!”
$?  exit status of last command ls ; echo “ls returned code $?”
$0  Name of current command (as called) echo “I am $0”
$1  Name of current command&#39;s first parameter   echo “My first argument is $1”
$9  Name of current command&#39;s ninth parameter   echo “My ninth argument is $9”
$@  All of current command&#39;s parameters (preserving whitespace and quoting) echo “My arguments are $@”
$*  All of current command&#39;s parameters (not preserving whitespace and quoting) echo “My arguments are $*”
-eq Numeric Equality    if [ “$foo” -eq “9” ]
-ne Numeric Inquality   if [ “$foo” -ne “9” ]
-lt Less Than   if [ “$foo” -lt “9” ]
-le Less Than or Equal  if [ “$foo” -le “9” ]
-gt Greater Than    if [ “$foo” -gt “9” ]
-ge Greater Than or Equal   if [ “$foo” -ge “9” ]
-z  String is zero length   if [ -z “$foo” ]
-n  String is not zero length   if [ -n “$foo” ]
-nt Newer Than  if [ “$file1” -nt “$file2” ]
-d  Is a Directory  if [ -d /bin ]
-f  Is a File   if [ -f /bin/ls ]
-r  Is a readable file  if [ -r /bin/ls ]
-w  Is a writable file  if [ -w /bin/ls ]
-x  Is an executable file   if [ -x /bin/ls ]
( ... ) Function definition function myfunc() { echo hello }</p>
]]></content:encoded>
      <guid>https://write.rpod.club/devops/neiavnye-sokrashcheniia-v-bash</guid>
      <pubDate>Thu, 11 Aug 2022 06:30:10 +0000</pubDate>
    </item>
  </channel>
</rss>