-
Notifications
You must be signed in to change notification settings - Fork 154
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8f6c951
commit 3c05a27
Showing
10 changed files
with
74 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
pip install jieba |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
.. _sphinx_chinese_search: | ||
|
||
=================== | ||
Sphinx中文搜索 | ||
=================== | ||
|
||
- 和 :ref:`mkdocs_chinese_search` 一样,采用 jieba 类库: | ||
|
||
.. literalinclude:: ../mkdocs/mkdocs_chinese_search/jieba | ||
:caption: 安装 ``jieba`` 模块 | ||
|
||
- 修改 ``conf.py`` 配置,将项目设置为中文,或者html搜索语言设置为中文: | ||
|
||
.. literalinclude:: sphinx_chinese_search/conf.py | ||
:language: python | ||
:caption: 配置Sphinx ``conf.py`` 设置项目为中文 | ||
|
||
- 可选配置: | ||
|
||
.. literalinclude:: sphinx_chinese_search/conf_jieba_dict.py | ||
:language: python | ||
:caption: 可选配置 ``jieba`` 词典路径 | ||
|
||
|
||
|
||
参考 | ||
===== | ||
|
||
- `SPHINX-DOC的中文搜索 <https://www.cnblogs.com/chunyin/p/9610857.html>`_ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
language = 'zh_CN' | ||
#html_search_language = 'zh' |
4 changes: 4 additions & 0 deletions
4
source/devops/docs/sphinx_doc/sphinx_chinese_search/conf_jieba_dict.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# A dictionary with options for the search language support, empty by default. | ||
# 'ja' uses this config value. | ||
# 'zh' user can custom change `jieba` dictionary path. | ||
# html_search_options = {'dict': '/usr/lib/jieba.txt'} # 根据需要设置jieba的词典路径 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
pip install sphinx | ||
pip install sphinx_rtd_theme | ||
pip install sphinxnotes-strike | ||
|
||
# 支持视频、YouTube和中文搜索,安装组件和配置 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# 清理容器 | ||
docker container prune | ||
# 如果要强制完成,则增加 ``-f`` 或 ``--force`` 参数 | ||
# 可以使用过滤功能: 例如清理最近24小时前的已经停止的容器 | ||
docker container prune --filter "until=24h" | ||
|
||
# 清理卷 | ||
docker volume prune | ||
# 默认是删除所有没有使用的卷,可以过滤,例如有标签keep的需要保留 | ||
docker volume prune --filter "label!=keep" | ||
|
||
# 清理网络 | ||
docker network prune | ||
# 清理24小时以上没有使用的网络 | ||
docker network prune --filter "until=24h" | ||
|
||
# 清理一切,默认不包括卷 | ||
docker system prune | ||
# 清理一切,并且包括卷也清理 | ||
docker system prune --volumes | ||
|