Skip to content

Commit c960a87

Browse files
zsh funcs
1 parent 5182c61 commit c960a87

File tree

4 files changed

+8
-9
lines changed

4 files changed

+8
-9
lines changed

dot/common.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
#!/bin/bash
21

32
[[ "${DOT_COMMON:-""}" == "loaded" ]] && return 0
43
DOT_COMMON=loaded
@@ -51,9 +50,11 @@ cprint() {
5150
codes="\033["
5251
for ((i=1; i<=$#; i++))
5352
do
54-
id=${!i}
55-
# echo "${id} is ${!id}"
56-
codes="${codes}${!id}"
53+
# bash: id=${!i}
54+
id=${(P)i}
55+
56+
# bash: codes="${codes}${!id}"
57+
codes="${codes}${(P)id}"
5758

5859
if [ $i -ne $# ]; then
5960
codes="${codes};"

dot/load.sh

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
#!/bin/bash
2-
3-
# set -e
1+
#!/bin/zsh
42

53
# call to reload
64
function dot_load() {

dot/man.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/bin/bash
1+
#!/bin/zsh
22

33
SCRIPT_DIR="$( cd "$( dirname "$0" )" && pwd )"
44
. $SCRIPT_DIR/common.sh

dot/welcome.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/bin/bash
1+
#!/bin/zsh
22

33
SCRIPT_DIR="$( cd "$( dirname "$0" )" && pwd )"
44
. $SCRIPT_DIR/common.sh

0 commit comments

Comments
 (0)