Skip to content

Commit 1250257

Browse files
docs: Add Chinese doc translation.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: kaizhi-singtown <kaizhi@singtown.com>
1 parent d9a89df commit 1250257

171 files changed

Lines changed: 48691 additions & 79 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@ tests/ports/unix/ffi_lib.so
1919
# Python cache files
2020
__pycache__/
2121

22+
# Compiled translation files
23+
docs/**/*.mo
24+
2225
# Customized Makefile/project overrides
2326
GNUmakefile
2427
user.props

docs/conf.py

Lines changed: 89 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,16 @@
7979
#
8080
# We don't follow "The short X.Y version" vs "The full version, including alpha/beta/rc tags"
8181
# breakdown, so use the same version identifier for both to avoid confusion.
82-
version = release = '1.26'
82+
version = release = "1.26"
8383

8484
# The language for content autogenerated by Sphinx. Refer to documentation
8585
# for a list of supported languages.
8686
# language = None
8787

88+
# -- Options for i18n output ----------------------------------------------
89+
locale_dirs = ["locale"]
90+
gettext_compact = False
91+
8892
# There are two options for replacing |today|: either, you set today to some
8993
# non-false value, then it is used:
9094
# today = ''
@@ -93,81 +97,88 @@
9397

9498
# List of patterns, relative to source directory, that match files and
9599
# directories to ignore when looking for source files.
96-
exclude_patterns = ['build', '.venv', "esp32", "esp8266", "pyboard", "wipy",
97-
"develop/cmodules.rst",
98-
"develop/compiler.rst",
99-
"develop/extendingmicropython.rst",
100-
"develop/gettingstarted.rst",
101-
"develop/index.rst",
102-
"develop/library.rst",
103-
"develop/maps.rst",
104-
"develop/memorymgt.rst",
105-
"develop/natmod.rst",
106-
"develop/optimizations.rst",
107-
"develop/porting.rst",
108-
"develop/publiccapi.rst",
109-
"develop/qstr.rst",
110-
"develop/writingtests.rst",
111-
"library/btree.rst",
112-
"library/esp.rst",
113-
"library/espnow.rst",
114-
"library/esp32.rst",
115-
"library/framebuf.rst",
116-
"library/rp2.rst",
117-
"library/rp2.DMA.rst",
118-
"library/rp2.Flash.rst",
119-
"library/rp2.PIO.rst",
120-
"library/rp2.StateMachine.rst",
121-
"library/wm8960.rst",
122-
"library/zephyr.rst",
123-
"library/zephyr.DiskAccess.rst",
124-
"library/zephyr.FlashArea.rst",
125-
"library/zephyr.zsensor.rst",
126-
"library/lcd160cr.rst",
127-
"library/machine.ADCWiPy.rst",
128-
"library/machine.Counter.rst",
129-
"library/machine.Encoder.rst",
130-
"library/machine.SD.rst",
131-
"library/machine.SDCard.rst",
132-
"library/machine.TimerWiPy.rst",
133-
"library/machine.USBDevice.rst",
134-
"library/network.CC3K.rst",
135-
"library/network.WIZNET5K.rst",
136-
"library/network.WLANWiPy.rst",
137-
"library/neopixel.rst",
138-
"library/pyb.Accel.rst",
139-
"library/pyb.LCD.rst",
140-
"library/pyb.Switch.rst",
141-
"library/wipy.rst",
142-
"mimxrt/general.rst",
143-
"mimxrt/pinout.rst",
144-
"mimxrt/tutorial/intro.rst",
145-
"mimxrt/quickref.rst",
146-
"renesas-ra/general.rst",
147-
"renesas-ra/quickref.rst",
148-
"renesas-ra/tutorial/index.rst",
149-
"renesas-ra/tutorial/intro.rst",
150-
"renesas-ra/tutorial/program_in_flash.rst",
151-
"renesas-ra/tutorial/reset.rst",
152-
"renesas-ra/tutorial/troubleshooting.rst",
153-
"renesas-ra/tutorial/using_peripheral.rst",
154-
"rp2/general.rst",
155-
"rp2/quickref.rst",
156-
"rp2/tutorial/intro.rst",
157-
"rp2/tutorial/pio.rst",
158-
"rp2/tutorial/reset.rst",
159-
"samd/general.rst",
160-
"samd/quickref.rst",
161-
"samd/pinout.rst",
162-
"samd/tutorial/intro.rst",
163-
"unix/quickref.rst",
164-
"zephyr/general.rst",
165-
"zephyr/quickref.rst",
166-
"zephyr/tutorial/index.rst",
167-
"zephyr/tutorial/intro.rst",
168-
"zephyr/tutorial/pins.rst",
169-
"zephyr/tutorial/repl.rst",
170-
"zephyr/tutorial/storage.rst"]
100+
exclude_patterns = [
101+
"build",
102+
".venv",
103+
"esp32",
104+
"esp8266",
105+
"pyboard",
106+
"wipy",
107+
"develop/cmodules.rst",
108+
"develop/compiler.rst",
109+
"develop/extendingmicropython.rst",
110+
"develop/gettingstarted.rst",
111+
"develop/index.rst",
112+
"develop/library.rst",
113+
"develop/maps.rst",
114+
"develop/memorymgt.rst",
115+
"develop/natmod.rst",
116+
"develop/optimizations.rst",
117+
"develop/porting.rst",
118+
"develop/publiccapi.rst",
119+
"develop/qstr.rst",
120+
"develop/writingtests.rst",
121+
"library/btree.rst",
122+
"library/esp.rst",
123+
"library/espnow.rst",
124+
"library/esp32.rst",
125+
"library/framebuf.rst",
126+
"library/rp2.rst",
127+
"library/rp2.DMA.rst",
128+
"library/rp2.Flash.rst",
129+
"library/rp2.PIO.rst",
130+
"library/rp2.StateMachine.rst",
131+
"library/wm8960.rst",
132+
"library/zephyr.rst",
133+
"library/zephyr.DiskAccess.rst",
134+
"library/zephyr.FlashArea.rst",
135+
"library/zephyr.zsensor.rst",
136+
"library/lcd160cr.rst",
137+
"library/machine.ADCWiPy.rst",
138+
"library/machine.Counter.rst",
139+
"library/machine.Encoder.rst",
140+
"library/machine.SD.rst",
141+
"library/machine.SDCard.rst",
142+
"library/machine.TimerWiPy.rst",
143+
"library/machine.USBDevice.rst",
144+
"library/network.CC3K.rst",
145+
"library/network.WIZNET5K.rst",
146+
"library/network.WLANWiPy.rst",
147+
"library/neopixel.rst",
148+
"library/pyb.Accel.rst",
149+
"library/pyb.LCD.rst",
150+
"library/pyb.Switch.rst",
151+
"library/wipy.rst",
152+
"mimxrt/general.rst",
153+
"mimxrt/pinout.rst",
154+
"mimxrt/tutorial/intro.rst",
155+
"mimxrt/quickref.rst",
156+
"renesas-ra/general.rst",
157+
"renesas-ra/quickref.rst",
158+
"renesas-ra/tutorial/index.rst",
159+
"renesas-ra/tutorial/intro.rst",
160+
"renesas-ra/tutorial/program_in_flash.rst",
161+
"renesas-ra/tutorial/reset.rst",
162+
"renesas-ra/tutorial/troubleshooting.rst",
163+
"renesas-ra/tutorial/using_peripheral.rst",
164+
"rp2/general.rst",
165+
"rp2/quickref.rst",
166+
"rp2/tutorial/intro.rst",
167+
"rp2/tutorial/pio.rst",
168+
"rp2/tutorial/reset.rst",
169+
"samd/general.rst",
170+
"samd/quickref.rst",
171+
"samd/pinout.rst",
172+
"samd/tutorial/intro.rst",
173+
"unix/quickref.rst",
174+
"zephyr/general.rst",
175+
"zephyr/quickref.rst",
176+
"zephyr/tutorial/index.rst",
177+
"zephyr/tutorial/intro.rst",
178+
"zephyr/tutorial/pins.rst",
179+
"zephyr/tutorial/repl.rst",
180+
"zephyr/tutorial/storage.rst",
181+
]
171182

172183
# The reST default role (used for this markup: `text`) to use for all
173184
# documents.
@@ -210,7 +221,6 @@
210221
import sphinx_rtd_theme
211222

212223
html_theme = "sphinx_rtd_theme"
213-
html_theme_path = [sphinx_rtd_theme.get_html_theme_path(), "."]
214224
except:
215225
html_theme = "default"
216226
html_theme_path = ["."]
@@ -234,12 +244,12 @@
234244

235245
# The name of an image file (relative to this directory) to place at the top
236246
# of the sidebar.
237-
html_logo = '../../openmv-media/logos/openmv-logo-white/web-logo-sticky.png'
247+
html_logo = "../../openmv-media/logos/openmv-logo-white/web-logo-sticky.png"
238248

239249
# The name of an image file (within the static path) to use as favicon of the
240250
# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
241251
# pixels large.
242-
html_favicon = '../../openmv-media/icons/openmv-icon/openmv.ico'
252+
html_favicon = "../../openmv-media/icons/openmv-icon/openmv.ico"
243253

244254
# Add any paths that contain custom static files (such as style sheets) here,
245255
# relative to this directory. They are copied after the builtin static files,

0 commit comments

Comments
 (0)