Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 52 additions & 10 deletions library/glob.po
Original file line number Diff line number Diff line change
@@ -1,26 +1,27 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) 2001-2022, Python Software Foundation
# Copyright (C) 2001-2023, Python Software Foundation
# This file is distributed under the same license as the Python package.
#
# Translators:
# Matt Wang <mattwang44@gmail.com>, 2023
msgid ""
msgstr ""
"Project-Id-Version: Python 3.11\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2023-04-24 00:16+0000\n"
"PO-Revision-Date: 2018-05-23 16:02+0000\n"
"Last-Translator: Adrian Liaw <adrianliaw2000@gmail.com>\n"
"PO-Revision-Date: 2023-01-24 01:21+0800\n"
"Last-Translator: Matt Wang <mattwang44@gmail.com>\n"
"Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-"
"tw)\n"
"Language: zh_TW\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"
"X-Generator: Poedit 3.2.2\n"

#: ../../library/glob.rst:2
msgid ":mod:`glob` --- Unix style pathname pattern expansion"
msgstr ""
msgstr ":mod:`glob` --- Unix 風格的路徑名稱模式擴展"

#: ../../library/glob.rst:7
msgid "**Source code:** :source:`Lib/glob.py`"
Expand All @@ -35,6 +36,10 @@ msgid ""
"done by using the :func:`os.scandir` and :func:`fnmatch.fnmatch` functions "
"in concert, and not by actually invoking a subshell."
msgstr ""
":mod:`glob` 模組根據 Unix shell 使用的規則查找與指定模式匹配的所有路徑名稱,"
"結果以任意順序回傳。沒有波浪號 (tilde) 擴展,但是 ``*``、``?`` 和用 ``[]`` 表"
"示的字元範圍將被正確匹配。這是透過同時使用 :func:`os.scandir` 和 :func:"
"`fnmatch.fnmatch` 函式來完成的,而沒有實際調用 subshell。"

#: ../../library/glob.rst:28
msgid ""
Expand All @@ -43,16 +48,21 @@ msgid ""
"Path.glob`. (For tilde and shell variable expansion, use :func:`os.path."
"expanduser` and :func:`os.path.expandvars`.)"
msgstr ""
"請注意,以點 (``.``) 開頭的檔案只能與同樣以點開頭的模式匹配,這與 :func:"
"`fnmatch.fnmatch` 或 :func:`pathlib.Path.glob` 不同。 (對於波浪號和 shell 變"
"數擴展,請使用 :func:`os.path.expanduser` 和 :func:`os.path.expandvars`。)"

#: ../../library/glob.rst:34
msgid ""
"For a literal match, wrap the meta-characters in brackets. For example, "
"``'[?]'`` matches the character ``'?'``."
msgstr ""
"對於文本 (literal) 匹配,將元字元 (meta-character) 括在方括號中。例如,"
"``'[?]'`` 會匹配 ``'?'`` 字元。"

#: ../../library/glob.rst:39
msgid "The :mod:`pathlib` module offers high-level path objects."
msgstr ""
msgstr ":mod:`pathlib` 模組提供高階路徑物件。"

#: ../../library/glob.rst:45
msgid ""
Expand All @@ -65,6 +75,12 @@ msgid ""
"conditions is removed or added during the call of this function, whether a "
"path name for that file be included is unspecified."
msgstr ""
"回傳與 *pathname* 匹配、可能為空的路徑名稱 list,它必須是包含路徑規範的字"
"串。 *pathname* 可以是絕對的(如 :file:`/usr/src/Python-1.5/Makefile`)或相對"
"的(如 :file:`../../Tools/\\*/\\*.gif`),並且可以包含 shell 樣式的通用字元 "
"(wildcard)。已損壞的符號連接也會(如同在 shell)被包含在結果中。結果是否排序"
"取決於檔案系統 (file system)。如果在呼叫此函式期間刪除或新增滿足條件的檔案,"
"則結果不一定會包含該檔案的路徑名稱。"

#: ../../library/glob.rst:54
msgid ""
Expand All @@ -73,12 +89,16 @@ msgid ""
"func:`glob` as changing the current directory before calling it. If "
"*pathname* is relative, the result will contain paths relative to *root_dir*."
msgstr ""
"如果 *root_dir* 不是 ``None``,它應該是一個指定搜索根目錄的 :term:`path-like "
"object`。它在呼叫它之前更改當前目錄的影響與 :func:`glob` 相同。如果 "
"*pathname* 是相對的,結果將包含相對於 *root_dir* 的路徑。"

#: ../../library/glob.rst:60
msgid ""
"This function can support :ref:`paths relative to directory descriptors "
"<dir_fd>` with the *dir_fd* parameter."
msgstr ""
"此函式可以支援以 *dir_fd* 參數使用\\ :ref:`相對目錄描述器的路徑 <dir_fd>`。"

#: ../../library/glob.rst:66
msgid ""
Expand All @@ -87,34 +107,41 @@ msgid ""
"the pattern is followed by an :data:`os.sep` or :data:`os.altsep` then files "
"will not match."
msgstr ""
"如果 *recursive* 為真,模式 \"``**``\" 將匹配任何檔案、零個或多個目錄、子目錄"
"和目錄的符號連結。如果模式後面有 :data:`os.sep` 或 :data:`os.altsep` 那麼檔案"
"將不會被匹配。"

#: ../../library/glob.rst:71
msgid ""
"If *include_hidden* is true, \"``**``\" pattern will match hidden "
"directories."
msgstr ""
msgstr "如果 *include_hidden* 為真,\"``**``\" 模式將匹配被隱藏的目錄。"

#: ../../library/glob.rst:73 ../../library/glob.rst:96
msgid ""
"Raises an :ref:`auditing event <auditing>` ``glob.glob`` with arguments "
"``pathname``, ``recursive``."
msgstr ""
"使用引數 ``pathname``、``recursive`` 引發一個\\ :ref:`稽核事件 (auditing "
"event) <auditing>` ``glob.glob``。"

#: ../../library/glob.rst:74 ../../library/glob.rst:97
msgid ""
"Raises an :ref:`auditing event <auditing>` ``glob.glob/2`` with arguments "
"``pathname``, ``recursive``, ``root_dir``, ``dir_fd``."
msgstr ""
"使用引數 ``pathname``、``recursive``、``root_dir``、``dir_fd`` 引發一個\\ :"
"ref:`稽核事件 <auditing>` ``glob.glob/2``。"

#: ../../library/glob.rst:77
msgid ""
"Using the \"``**``\" pattern in large directory trees may consume an "
"inordinate amount of time."
msgstr ""
msgstr "在大型目錄樹中使用 \"``**``\" 模式可能會消耗過多的時間。"

#: ../../library/glob.rst:80 ../../library/glob.rst:99
msgid "Support for recursive globs using \"``**``\"."
msgstr ""
msgstr "支援以 \"``**``\" 使用遞迴 glob。"

#: ../../library/glob.rst:83 ../../library/glob.rst:102
msgid "Added the *root_dir* and *dir_fd* parameters."
Expand All @@ -129,6 +156,8 @@ msgid ""
"Return an :term:`iterator` which yields the same values as :func:`glob` "
"without actually storing them all simultaneously."
msgstr ""
"回傳一個會產生與 :func:`glob` 相同的值的 :term:`iterator` ,而不是同時存儲全"
"部的值。"

#: ../../library/glob.rst:111
msgid ""
Expand All @@ -138,6 +167,10 @@ msgid ""
"escaped, e.g. on Windows ``escape('//?/c:/Quo vadis?.txt')`` returns ``'//?/"
"c:/Quo vadis[?].txt'``."
msgstr ""
"跳脫 (escape) 所有特殊字元(``'?'``、``'*'`` 和 ``'['``)。如果你想匹配其中可"
"能包含特殊字元的任意文本字串,這將會很有用。驅動器 (drive)/UNC 共享點 "
"(sharepoints) 中的特殊字元不會被跳脫,例如在 Windows 上,``escape('//?/c:/"
"Quo vadis?.txt')`` 會回傳 ``'//?/c:/Quo vadis[?].txt'``。"

#: ../../library/glob.rst:120
msgid ""
Expand All @@ -147,18 +180,27 @@ msgid ""
"following results. Notice how any leading components of the path are "
"preserved. ::"
msgstr ""
"例如,在一個包含以下檔案的目錄::file:`1.gif`、:file:`2.txt`、:file:`card."
"gif`,和一個僅包含 :file:`3.txt` 檔案的子目錄 :file:`sub`,:func:`glob` 將產"
"生以下結果。請注意路徑的任何前導部分是如何保留的。\n"
"\n"
" ::"

#: ../../library/glob.rst:138
msgid ""
"If the directory contains files starting with ``.`` they won't be matched by "
"default. For example, consider a directory containing :file:`card.gif` and :"
"file:`.card.gif`::"
msgstr ""
"如果目錄包含以 ``.`` 開頭的檔案,則預設情況下不會去匹配到它們。例如,一個包"
"含 :file:`card.gif` 和 :file:`.card.gif` 的目錄:\n"
"\n"
"::"

#: ../../library/glob.rst:150
msgid "Module :mod:`fnmatch`"
msgstr ":mod:`fnmatch` 模組"

#: ../../library/glob.rst:151
msgid "Shell-style filename (not path) expansion"
msgstr ""
msgstr "Shell 風格檔案名(不是路徑)的擴展"