2
2
# This file is distributed under the same license as the Python package.
3
3
#
4
4
# Translators:
5
+ # Po-Chuan Chen <present90308@gmail.com>, 2023
5
6
# Dr-XYZ <dr.xyz.tw@gmail.com>, 2025
6
7
msgid ""
7
8
msgstr ""
@@ -72,7 +73,7 @@ msgid ""
72
73
"project directory, or under a container directory for lots of virtual "
73
74
"environments, such as ``~/.virtualenvs``."
74
75
msgstr ""
75
- "儲存在一個目錄中 ,通常命名為專案目錄下的 ``.venv`` 或 ``venv``,也可能是在用"
76
+ "被包含在一個目錄中 ,通常命名為專案目錄下的 ``.venv`` 或 ``venv``,也可能是在用"
76
77
"來管理多個虛擬環境的容器目錄中,例如 ``~/.virtualenvs``。"
77
78
78
79
#: ../../library/venv.rst:44
@@ -614,7 +615,7 @@ msgid ""
614
615
"method named ``create_{scm}_ignore_file``. The only value supported by "
615
616
"default is ``\" git\" `` via :meth:`create_git_ignore_file`."
616
617
msgstr ""
617
- "*scm_ignore_files*——根據可疊代物件中指定的原始碼控制系統 (SCM),建立對應的忽"
618
+ "*scm_ignore_files*——根據可疊代物件中指定的來源控制管理 (SCM),建立對應的忽"
618
619
"略檔。支援情況取決於是否有名為 ``create_{scm}_ignore_file`` 的方法。預設唯一"
619
620
"支援的值是 ``\" git\" ``,透過 :meth:`create_git_ignore_file` 方法提供支援。"
620
621
@@ -673,8 +674,8 @@ msgid ""
673
674
msgstr ""
674
675
"def create(self, env_dir):\n"
675
676
"\"\"\" \n"
676
- "Create a virtualized Pythonenvironment in a directory. \n"
677
- " env_diris the target directory to create an environment in. \n"
677
+ "在目標目錄中建立一個虛擬化的 Python環境。 \n"
678
+ " env_dir是要建立虛擬環境的目標目錄。 \n"
678
679
"\"\"\" \n"
679
680
" env_dir = os.path.abspath(env_dir)\n"
680
681
" context = self.ensure_directories(env_dir)\n"
@@ -719,15 +720,15 @@ msgid ""
719
720
"``env_dir`` - The location of the virtual environment. Used for "
720
721
"``__VENV_DIR__`` in activation scripts (see :meth:`install_scripts`)."
721
722
msgstr ""
722
- "``env_dir`` —— 虛擬環境的位置。用於啟用腳本中的 ``__VENV_DIR__``(參見 :meth:"
723
+ "``env_dir`` —— 虛擬環境的位置。用於啟用腳本中的 ``__VENV_DIR__``\\ (參見 :meth:"
723
724
"`install_scripts`)。"
724
725
725
726
#: ../../library/venv.rst:377
726
727
msgid ""
727
728
"``env_name`` - The name of the virtual environment. Used for "
728
729
"``__VENV_NAME__`` in activation scripts (see :meth:`install_scripts`)."
729
730
msgstr ""
730
- "``env_name`` —— 虛擬環境的名稱。用於啟用腳本中的 ``__VENV_NAME__``(參見 :"
731
+ "``env_name`` —— 虛擬環境的名稱。用於啟用腳本中的 ``__VENV_NAME__``\\ (參見 :"
731
732
"meth:`install_scripts`)。"
732
733
733
734
#: ../../library/venv.rst:380
@@ -736,7 +737,7 @@ msgid ""
736
737
"``__VENV_PROMPT__`` in activation scripts (see :meth:`install_scripts`)."
737
738
msgstr ""
738
739
"``prompt`` —— 啟用腳本所使用的提示字元。用於啟用腳本中的 "
739
- "``__VENV_PROMPT__``(參見 :meth:`install_scripts`)。"
740
+ "``__VENV_PROMPT__``\\ (參見 :meth:`install_scripts`)。"
740
741
741
742
#: ../../library/venv.rst:383
742
743
msgid ""
@@ -798,7 +799,7 @@ msgstr ""
798
799
msgid ""
799
800
"The attribute ``lib_path`` was added to the context, and the context object "
800
801
"was documented."
801
- msgstr "``lib_path``屬性已新增至上下文中,且上下文物件已加入文件說明 。"
802
+ msgstr "``lib_path``屬性已新增至情境中,且情境物件已加入文件說明 。"
802
803
803
804
#: ../../library/venv.rst:417
804
805
msgid "Creates the ``pyvenv.cfg`` configuration file in the environment."
@@ -970,7 +971,7 @@ msgid ""
970
971
"environment::"
971
972
msgstr ""
972
973
"以下的腳本展示了如何透過實作子類別來擴充 :class:`EnvBuilder`,並在建立的虛擬"
973
- "環境中安裝 setuptools 與 pip::"
974
+ "環境中安裝 setuptools 與 pip: ::"
974
975
975
976
#: ../../library/venv.rst:524
976
977
msgid ""
@@ -1198,28 +1199,22 @@ msgstr ""
1198
1199
"\n"
1199
1200
"class ExtendedEnvBuilder(venv.EnvBuilder):\n"
1200
1201
"\"\"\" \n"
1201
- "This builder installs setuptoolsand pip so that you can pipor \n"
1202
- " easy_installother packages into the created virtual environment. \n"
1202
+ "此建構子會安裝 setuptools和 pip,使你能夠使用 pip或 \n"
1203
+ " easy_install安裝其他套件到建立的虛擬環境中。 \n"
1203
1204
"\n"
1204
- " :param nodist: If true, setuptools and pip are not installed into the\n"
1205
- " created virtual environment.\n"
1206
- " :param nopip: If true, pip is not installed into the created\n"
1207
- " virtual environment.\n"
1208
- " :param progress: If setuptools or pip are installed, the progress of "
1209
- "the\n"
1210
- " installation can be monitored by passing a progress\n"
1211
- " callable. If specified, it is called with two\n"
1212
- " arguments: a string indicating some progress, and a\n"
1213
- " context indicating where the string is coming from.\n"
1214
- " The context argument can have one of three values:\n"
1215
- " 'main', indicating that it is called from virtualize()\n"
1216
- " itself, and 'stdout' and 'stderr', which are obtained\n"
1217
- " by reading lines from the output streams of a "
1218
- "subprocess\n"
1219
- " which is used to install the app.\n"
1205
+ " :param nodist: 若為 true,則不會安裝 setuptools 和 pip 至\n"
1206
+ " 所建立的虛擬環境中。\n"
1207
+ " :param nopip: 若為 true,則不會安裝 pip 至所建立的\n"
1208
+ " 虛擬環境中。\n"
1209
+ " :param progress: 若安裝了 setuptools 或 pip,可透過傳入 progress\n"
1210
+ " 可呼叫物件來監控安裝進度。若有指定,該可呼叫物件會接收兩個參數:\n"
1211
+ " 一個表示進度的字串,以及一個表示該字串來源的情境。\n"
1212
+ " context 參數可能有三種值:\n"
1213
+ " 'main' 表示該呼叫來自 virtualize() 本身,\n"
1214
+ " 'stdout' 與 'stderr' 則分別表示從子行程輸出資料流中\n"
1215
+ " 讀取的輸出內容,該子行程用於安裝應用程式。\n"
1220
1216
"\n"
1221
- " If a callable is not specified, default progress\n"
1222
- " information is output to sys.stderr.\n"
1217
+ " 若未指定可呼叫物件,則預設的進度資訊會輸出至 sys.stderr。\n"
1223
1218
"\"\"\" \n"
1224
1219
"\n"
1225
1220
" def __init__(self, *args, **kwargs):\n"
@@ -1231,11 +1226,9 @@ msgstr ""
1231
1226
"\n"
1232
1227
" def post_setup(self, context):\n"
1233
1228
"\"\"\" \n"
1234
- " Set up any packages which need to be pre-installed into the\n"
1235
- " virtual environment being created.\n"
1229
+ " 設定在建立虛擬環境時需預先安裝的套件。\n"
1236
1230
"\n"
1237
- " :param context: The information for the virtual environment\n"
1238
- " creation request being processed.\n"
1231
+ " :param context: 處理中的虛擬環境建立請求所需的資訊。\n"
1239
1232
"\"\"\" \n"
1240
1233
" os.environ['VIRTUAL_ENV'] = context.env_dir\n"
1241
1234
" if not self.nodist:\n"
@@ -1246,10 +1239,7 @@ msgstr ""
1246
1239
"\n"
1247
1240
" def reader(self, stream, context):\n"
1248
1241
"\"\"\" \n"
1249
- " Read lines from a subprocess' output stream and either pass to a "
1250
- "progress\n"
1251
- " callable (if specified) or write progress information to sys."
1252
- "stderr.\n"
1242
+ " 從子行程的輸出串流中讀取每一列,並將其傳遞給進度回呼函式(若有指定),或將進度資訊寫入 sys.stderr。\n"
1253
1243
"\"\"\" \n"
1254
1244
" progress = self.progress\n"
1255
1245
" while True:\n"
@@ -1319,10 +1309,9 @@ msgstr ""
1319
1309
"\n"
1320
1310
" def install_pip(self, context):\n"
1321
1311
"\"\"\" \n"
1322
- "Install pip in the virtual environment. \n"
1312
+ "在虛擬環境中安裝 pip。 \n"
1323
1313
"\n"
1324
- " :param context: The information for the virtual environment\n"
1325
- " creation request being processed.\n"
1314
+ " :param context: 處理中的虛擬環境建立請求相關資訊。\n"
1326
1315
"\"\"\" \n"
1327
1316
" url = 'https://bootstrap.pypa.io/get-pip.py'\n"
1328
1317
" self.install_script(context, 'pip', url)\n"
@@ -1404,7 +1393,7 @@ msgstr ""
1404
1393
msgid ""
1405
1394
"This script is also available for download `online <https://gist.github.com/"
1406
1395
"vsajip/4673395>`_."
1407
- msgstr "此腳本也可從 `線上 <https://gist.github.com/vsajip/4673395>`_ 下載。"
1396
+ msgstr "此腳本也可從\\ `線上 <https://gist.github.com/vsajip/4673395>`_\\ 下載。"
1408
1397
1409
1398
#: ../../library/venv.rst:14
1410
1399
msgid "Environments"