1
0
bot/scpt/t.zsh

21 lines
427 B
Bash
Raw Normal View History

2024-02-16 16:16:22 +09:00
#!/bin/zsh
f=`grep -R '$HOME/.config/atr' . |cut -d : -f 1|sort|uniq|grep -v t.zsh`
echo $f
n=`echo $f|wc -l`
for ((i=1;i<=$n;i++))
do
ff=`echo $f|awk "NR==$i"`
echo $i
echo $ff
sed 's#$HOME/.config/atr#$HOME/.config/ai#g' $ff|grep '$HOME/.config'
case $OSTYPE in
linux*)
sed -i 's#$HOME/.config/atr#$HOME/.config/ai#g' $ff
;;
darwin*)
sed -i "" 's#$HOME/.config/atr#$HOME/.config/ai#g' $ff
;;
esac
done