Created
November 12, 2019 21:47
-
-
Save shaal/63dd20c00475631680c90d473a0ab017 to your computer and use it in GitHub Desktop.
Convert all JSON files to YML in current tree
This file contains hidden or 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 | |
# | |
# Convert JSON files to YML in current tree | |
# | |
shopt -s globstar | |
for file in **/*.json; do | |
yq r "$file" > "${file%.json}.yml"; | |
rm "$file"; | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment