Skip to content

Commit cfc47ec

Browse files
add ksh support
1 parent 875f2ea commit cfc47ec

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

β€ŽREADME.mdβ€Ž

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# ColorEchoForShell
2-
Make echo colorful with easier method. In [bash](https://www.gnu.org/software/bash/), [sh](https://en.wikipedia.org/wiki/Bourne_shell), [fish](http://fishshell.com/) and [zsh](http://www.zsh.org/).
2+
Make echo colorful with easier method. In [bash](https://www.gnu.org/software/bash/), [sh](https://en.wikipedia.org/wiki/Bourne_shell), [fish](http://fishshell.com/), [ksh](http://www.kornshell.com/) and [zsh](http://www.zsh.org/).
33

44
## Installation
55

@@ -10,7 +10,7 @@ Make echo colorful with easier method. In [bash](https://www.gnu.org/software/ba
1010

1111
## Usage
1212

13-
* echo.`StyleColor` (if you are using `sh`, there is no `.` dot symbol)
13+
* echo.`StyleColor` (if you are using `ksh`/`sh`, there is no `.` dot symbol)
1414

1515
### Examples
1616

β€Žgenerator.shβ€Ž

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
dist=dist/ColorEcho
44
table=table.txt
55

6-
for shell in sh bash fish
6+
for shell in sh bash fish ksh
77
do
88
if [ "$shell" = "bash" ]; then
99
fn='function '
@@ -14,6 +14,15 @@ do
1414
endIf='fi'
1515
brackets=
1616
para='@'
17+
elif [ "$shell" = "ksh" ];then
18+
fn='function '
19+
dot=
20+
echo='/bin/echo'
21+
startSym='{'
22+
endSym='}'
23+
endIf='fi'
24+
brackets=
25+
para='@'
1726
elif [ "$shell" = "fish" ];then
1827
fn='function '
1928
dot='.'

0 commit comments

Comments
Β (0)