How to mark an array in POSIX sh?

前端 未结 3 1230
你的背包
你的背包 2020-12-10 03:20

While replacing external commands in a shell script, I used an array to get rid of awk\'s NF.

Now, since I moved from bash to POSIX sh, I cannot get the

3条回答
  •  北海茫月
    2020-12-10 04:17

    You can use the following project from Github, which implements a POSIX-compliant array, which works in all shells I tried: https://github.com/makefu/array

    It is not very convenient to use, but I found it to work well for my purposes.

提交回复
热议问题