[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Help-bash] Brace expansions in if statement
From: |
Felipe Salvador |
Subject: |
[Help-bash] Brace expansions in if statement |
Date: |
Thu, 29 Mar 2018 20:12:21 +0200 |
User-agent: |
NeoMutt/20170113 (1.7.2) |
Hi list,
I'm trying to make bash to expand a brace expansion in a if statement.
So, I've
if [ "$GTTY" = tty{0..10} ]; then
msger=echo
else
msger=notify-send
fi
where $GTTY is $(tty | cut -d'/' -f3).
It doesn't work.
I'm reading allot of web pages, but I cannot get over.
Could you please help me?
Kind regards
--
Felipe Salvador
- [Help-bash] Brace expansions in if statement,
Felipe Salvador <=