[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Lower case construction does not working properly
From: |
Michael Kazakov |
Subject: |
Lower case construction does not working properly |
Date: |
Tue, 24 Nov 2015 14:23:20 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 |
Hellol.
I have founded a bug in variable manipulation behavior of bash version
4.2.53.
Constructions ${parameter,pattern} and ${parameter,,pattern} does not
working properly:
michael@kazakov:~> VAR=COLORADO
michael@kazakov:~> echo ${VAR,c}
COLORADO
michael@kazakov:~> echo ${VAR,,o}
COLORADO
But constructions ${parameter^pattern}/${parameter^^pattern} and
${parameter,,}/${parameter,,} working fine:
michael@kazakov:~> echo ${VAR,}
cOLORADO
michael@kazakov:~> echo ${VAR,,}
colorado
VAR=colorado
michael@kazakov:~> echo ${VAR^o}
colorado
michael@kazakov:~> echo ${VAR^^o}
cOlOradO
michael@kazakov:~> echo ${VAR^^c}
Colorado
--
Michael Kazakov
Quotix
- Lower case construction does not working properly,
Michael Kazakov <=