【发布时间】:2015-07-25 04:52:08
【问题描述】:
我有一个 shell 脚本来引导我的机器:https://github.com/pathikrit/mac-setup-script/blob/master/setup.sh
我有这几行代码来设置 git:
git config --global rerere.enabled true
git config --global branch.autosetuprebase always
git config --global credential.helper osxkeychain
我想将其提取到顶部的关联数组(字典/哈希图)中,并在一行代码中调用它。如何在 bash 4+ 中做到这一点?
【问题讨论】:
标签: bash shell scripting bash4