Skip to content

Instantly share code, notes, and snippets.

@thiagoeliasr
Created August 8, 2018 19:17
Show Gist options
  • Save thiagoeliasr/b55ced1474bb701337a521e816c6ce9c to your computer and use it in GitHub Desktop.
Save thiagoeliasr/b55ced1474bb701337a521e816c6ce9c to your computer and use it in GitHub Desktop.
One liner to get all vue-i18n $t strings to translate
echo "export default {" && grep -R '\$t(' resources/assets/js/* | sed "s/^.*(['\"]//g" | sed "s/['\"].*$//g" | sort | uniq | while read -r a; do echo " "\"$a\": \"\"; done && echo "}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment