Last active
December 13, 2021 03:28
-
-
Save sebacipolat/acce47a1eda87452f72c973d86b3235b to your computer and use it in GitHub Desktop.
script
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
git clone git@gitlab.com:nx/app/version-modules.git | |
cd 'version-modules' | |
search="**$MODULE**" | |
if grep -i "$search" "./readme.md" ; then | |
sed -i "/$MODULE/c\| **$MODULE** | ![GitHub version](https://img.shields.io/badge/version-$VERSION-brightgreen) |" ./readme.md | |
else | |
newline="| **$MODULE** | ![GitHub version](https://img.shields.io/badge/version-$VERSION-brightgreen) |" | |
echo $newline >> ./readme.md | |
fi | |
git add README.md | |
git commit -m "update module" | |
git push -f |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment