| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 484140e commit ff5c6dc
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,7 +1,7 @@ | |||
| 1 | 1 | #!/usr/bin/env python | |
| 2 | 2 | ||
| 3 | + import ast | ||
| 3 | 4 | import errno | |
| 4 | - import json | ||
| 5 | 5 | import os | |
| 6 | 6 | import re | |
| 7 | 7 | import shutil | |
@@ -20,9 +20,7 @@ def abspath(*args): | |||
| 20 | 20 | ||
| 21 | 21 | def load_config(): | |
| 22 | 22 | s = open('config.gypi').read() | |
| 23 | - s = re.sub(r'#.*?\n', '', s) # strip comments | ||
| 24 | - s = re.sub(r'\'', '"', s) # convert quotes | ||
| 25 | - return json.loads(s) | ||
| 23 | + return ast.literal_eval(s) | ||
| 26 | 24 | ||
| 27 | 25 | def try_unlink(path): | |
| 28 | 26 | try: | |
| Back | FazBrowse Home | New Git URL |
0 commit comments