aboutsummaryrefslogtreecommitdiff
path: root/units
diff options
context:
space:
mode:
authorMaria Lisina <sekoohaka.sarisan@gmail.com>2026-03-12 08:45:26 +0300
committerMaria Lisina <sekoohaka.sarisan@gmail.com>2026-03-12 08:45:26 +0300
commit0e3f3e65419ac1a13ac49b072fcf6360117630d9 (patch)
tree3ca9aa4229d7a09ce9f6dabd3e730194652d337d /units
parent271a36b99174bb1fba16817602d7f36f996e599e (diff)
*/*: Refactor several string manipulations
Signed-off-by: Maria Lisina <sekoohaka.sarisan@gmail.com>
Diffstat (limited to 'units')
-rw-r--r--units/ib_meta.zsh4
1 files changed, 2 insertions, 2 deletions
diff --git a/units/ib_meta.zsh b/units/ib_meta.zsh
index b718c34..1d616cd 100644
--- a/units/ib_meta.zsh
+++ b/units/ib_meta.zsh
@@ -4,7 +4,7 @@
if [[ -n "${ib_file_url}" && "${ib_file_url}" != "null" ]]
then
- ib_type="$(eval ${ib_ifilename} <<< "${ib_file_url}" | cut -d '.' -f 2)"
+ ib_type="$(cut -d '?' -f 1 <<< "${ib_file_url##*.}")"
if [[ -z "${ib_sample_url}" || "${ib_sample_url}" == "null" ]]
then
@@ -26,7 +26,7 @@ then
if [[ -n "${ib_type}" ]]
then
- ib_type_text="$(tr '[:lower:]' '[:upper:]' <<< "${ib_type}")"
+ ib_type_text="${(U)ib_type}"
fi
case "${ib_type}" in