Fix translation po file not found when `make rst`
The parsed language parameters contain unstripped spaces. This will generate a wrong path. Provide a `TOOLSOPT` to allow overriding the default values of parameters of the `make_rst.py` script. The xml generated by `godot --doctool -l LANG` can be checked for errors using `make xml-check LANGARG=LANG`, which may be useful for checking errors in po files.
This commit is contained in:
parent
80de898d72
commit
ed0e6e87fd
|
@ -4,7 +4,7 @@ OUTPUTDIR = $(BASEDIR)/_build
|
||||||
TOOLSDIR = $(BASEDIR)/tools
|
TOOLSDIR = $(BASEDIR)/tools
|
||||||
JSDIR = "$(BASEDIR)/../platform/web"
|
JSDIR = "$(BASEDIR)/../platform/web"
|
||||||
LANGARG ?= en
|
LANGARG ?= en
|
||||||
LANGCMD = -l $(LANGARG)
|
TOOLSOPT ?=
|
||||||
|
|
||||||
.ONESHELL:
|
.ONESHELL:
|
||||||
|
|
||||||
|
@ -19,7 +19,10 @@ doxygen:
|
||||||
rst:
|
rst:
|
||||||
rm -rf "$(OUTPUTDIR)/rst"
|
rm -rf "$(OUTPUTDIR)/rst"
|
||||||
mkdir -p "$(OUTPUTDIR)/rst"
|
mkdir -p "$(OUTPUTDIR)/rst"
|
||||||
python3 "$(TOOLSDIR)/make_rst.py" -o "$(OUTPUTDIR)/rst" "$(LANGCMD)" $(CLASSES)
|
python3 "$(TOOLSDIR)/make_rst.py" -o "$(OUTPUTDIR)/rst" -l "$(LANGARG)" $(TOOLSOPT) $(CLASSES)
|
||||||
|
|
||||||
|
xml-check:
|
||||||
|
python3 "$(TOOLSDIR)/make_rst.py" --dry-run -l "$(LANGARG)" $(TOOLSOPT) $(CLASSES)
|
||||||
|
|
||||||
rstjs:
|
rstjs:
|
||||||
rm -rf "$(OUTPUTDIR)/rstjs"
|
rm -rf "$(OUTPUTDIR)/rstjs"
|
||||||
|
|
Loading…
Reference in New Issue