Skip to content

Commit

Permalink
Fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
adikhoff committed Oct 12, 2024
1 parent 605ada7 commit 34bd91f
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- name: Migrate to Redot
run: |
python migrate.py . _migrated
python migrate.py --tiny . _migrated
# Use dummy builder to improve performance as we don't need the generated HTML in this workflow.
- name: Sphinx build
Expand Down
20 changes: 14 additions & 6 deletions migrate.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,21 @@
"""
## Migrate files from Godot to Redot
Usage (order is important):
py migrate.py [inputdir] [outputdir] [include unimplemented]
usage: Migrate [-h] [-e] [-t] [-v] input output
example:
py migrate.py . _migrated True
Simple file migrator. Uses str.replace to map from Godot to Redot. Also converts some filenames.
Will replace specific godot strings with redot. It tries to ignore external projects and other things that can't
positional arguments:
input Input directory relative to current
output Output directory relative to current
options:
-h, --help show this help message and exit
-e, --extended Include unimplemented substitutions, don't use in production
-t, --tiny Exclude classes directory
-v, --verbose
Will replace specific godot strings with redot. It tries to ignore external projects and other things that shouldn't
change.
A distinction is made between unimplemented instances of the godot keyword (for instance references to the main
Expand Down Expand Up @@ -76,7 +84,6 @@
('Support/Godot/', 'Support/Redot/'),
('config/godot/', 'config/redot/'),
('share/godot/', 'share/redot/'),
(' godot_', ' redot_'),
('org.godotengine.Godot', 'org.redotengine.Redot'),
('godot-ios-plugins', 'redot-ios-plugins'),
('godot-syntax-themes', 'redot-syntax-themes'),
Expand Down Expand Up @@ -191,6 +198,7 @@
('Hosted by <a href="https://readthedocs.org">Read the Docs', 'Hosted by <a href="https://cloudflare.com">CloudFlare'),
('<a href="https://docs.readthedocs.io/page/privacy-policy.html">Privacy Policy</a>', ''),
('G-dot', 'Godot'),
(' godot_', ' redot_'),
]

filename_mappings = [
Expand Down

0 comments on commit 34bd91f

Please sign in to comment.