diff options
| author | Kévin Le Gouguec <kevin.legouguec@gmail.com> | 2016-11-04 19:02:29 +0100 |
|---|---|---|
| committer | Kévin Le Gouguec <kevin.legouguec@gmail.com> | 2016-11-05 10:25:09 +0100 |
| commit | ca252d9fce68de806735c964c92f152e55221c84 (patch) | |
| tree | d5da40d28cfdc0ea8b90d9c2a287f711afabc7b7 | |
| parent | 86bd28fcb4d760cc16b616acc7d1065d7153c852 (diff) | |
| download | dotfiles-ca252d9fce68de806735c964c92f152e55221c84.tar.xz | |
Simplify argument enumeration
| -rw-r--r-- | .bashprompt | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/.bashprompt b/.bashprompt index 873746c..1ec822c 100644 --- a/.bashprompt +++ b/.bashprompt @@ -50,14 +50,13 @@ __fontify () output+='\033[' local attributes=($@) - local nb=$# - for ((i=0; i<nb; i++)) + for ((i=0; i<$#; i++)) do a=${attributes[${i}]} output+=${codes[${a}]} - if ((i<nb-1)) + if ((i<$#-1)) then output+=';' else |
