Created
January 30, 2022 15:15
-
-
Save surister/99036b618a6231ecdc2cb55845dea072 to your computer and use it in GitHub Desktop.
Simple script to automatically fix https://github.com/vuejs/vue-cli/issues/6784
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
#!/usr/bin/env python | |
__author__ = 'surister' | |
__author_contact__ = 'github/surister' | |
import pathlib | |
import sys | |
if len(sys.argv) < 2: | |
raise Exception('Expected one argument with ".../project/node_modules/@vue/" path') | |
if 'vue' not in sys.argv[1]: | |
raise ValueError('Hey, are you sure you are passing a @vue path?') | |
node_vue_path = pathlib.Path(sys.argv[1]) | |
for folder in node_vue_path.iterdir(): | |
(node_vue_path / folder / 'locales/').mkdir(exist_ok=True) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment