Created
December 27, 2018 02:32
-
-
Save unixc3t/fe327befcbd6054ac5b946ffebb6389e to your computer and use it in GitHub Desktop.
get installed gems
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ ! -f "gems.sh" ];then | |
touch "gems.sh" | |
echo "#!/bin/bash" >> gems.sh | |
fi | |
temp=123 | |
for i in $(ls '.'); do | |
if [ ${i} != $(basename ${0}) ] && [ ${i} != gems.sh ];then | |
a=${i%-*} | |
if [ ${a} != ${temp} ];then | |
temp=${a} | |
echo "gem install ${a}" >> gems.sh | |
fi | |
fi | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment