diff --git a/rebuild.sh b/rebuild.sh
new file mode 100755
index 0000000..319b303
--- /dev/null
+++ b/rebuild.sh
@@ -0,0 +1,13 @@
+cat << EOF >/usr/local/lib/python3.6/site-packages/sphinx_rtd_theme/comments.html
+
+
+
+EOF
+
+rm -rf build/ && sphinx-multiversion source build/html && cp -rf build/html/master/* build/html/
diff --git a/requirements.txt b/requirements.txt
index 2058b9e..2a34b8d 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -1,22 +1,21 @@
alabaster==0.7.12
argh==0.26.2
-Babel==2.7.0
+Babel==2.9.1
certifi==2019.6.16
chardet==3.0.4
docutils==0.14
-idna==2.8
imagesize==1.1.0
-Jinja2==2.10.1
+Jinja2==2.11.3
livereload==2.6.1
MarkupSafe==1.1.1
packaging==19.0
pathtools==0.1.2
port-for==0.3.1
-Pygments==2.4.2
+Pygments==2.7.4
pyparsing==2.4.0
pytz==2019.1
-PyYAML==5.1.1
-requests==2.22.0
+PyYAML==6.0.1
+#requests==2.32.3
six==1.12.0
snowballstemmer==1.9.0
Sphinx==2.1.2
@@ -29,7 +28,7 @@ sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.2
sphinxcontrib-serializinghtml==1.1.3
tornado==6.0.3
-urllib3==1.25.3
+#urllib3==2.2.2
watchdog==0.9.0
sphinxcontrib-disqus==1.1.0
sphinxcontrib-applehelp==1.0.1
@@ -39,3 +38,4 @@ sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.2
sphinxcontrib-serializinghtml==1.1.3
sphinx-sitemap==2.2.0
+sphinx-multiversion==0.2.4
diff --git a/source/.DS_Store b/source/.DS_Store
deleted file mode 100644
index 30e1782..0000000
Binary files a/source/.DS_Store and /dev/null differ
diff --git a/source/_templates/versions.html b/source/_templates/versions.html
new file mode 100644
index 0000000..31a1257
--- /dev/null
+++ b/source/_templates/versions.html
@@ -0,0 +1,27 @@
+{%- if current_version %}
+
+
+ Other Versions
+ v: {{ current_version.name }}
+
+
+
+ {%- if versions.tags %}
+
+ - Tags
+ {%- for item in versions.tags %}
+ - {{ item.name }}
+ {%- endfor %}
+
+ {%- endif %}
+ {%- if versions.branches %}
+
+ - Branches
+ {%- for item in versions.branches %}
+ - {{ item.name }}
+ {%- endfor %}
+
+ {%- endif %}
+
+
+{%- endif %}
diff --git a/source/aboutme.rst b/source/aboutme.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_01.rst b/source/c01/c01_01.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_02.rst b/source/c01/c01_02.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_03.rst b/source/c01/c01_03.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_04.rst b/source/c01/c01_04.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_05.rst b/source/c01/c01_05.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_06.rst b/source/c01/c01_06.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_07.rst b/source/c01/c01_07.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_08.rst b/source/c01/c01_08.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_09.rst b/source/c01/c01_09.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_10.rst b/source/c01/c01_10.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_11.rst b/source/c01/c01_11.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_12.rst b/source/c01/c01_12.rst
old mode 100755
new mode 100644
diff --git a/source/c01/c01_13.rst b/source/c01/c01_13.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_01.rst b/source/c02/c02_01.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_02.rst b/source/c02/c02_02.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_03.rst b/source/c02/c02_03.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_04.rst b/source/c02/c02_04.rst
old mode 100755
new mode 100644
index 38e5da5..408c43a
--- a/source/c02/c02_04.rst
+++ b/source/c02/c02_04.rst
@@ -339,7 +339,8 @@ Queue.task_done(),说明队列这个任务已经结束了。
当队列内部的任务计数器归于零时,调用 Queue.join() 就不会再阻塞了。
-要理解这个过程,请参考 http://pythontime.iswbm.com/en/latest/c02/c02_06.html
+要理解这个过程,请参考
+http://pythontime.iswbm.com/en/latest/c02/c02_06.html
里自定义线程池的的例子。
4. 消息队列的先进先出
diff --git a/source/c02/c02_05.rst b/source/c02/c02_05.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_06.rst b/source/c02/c02_06.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_07.rst b/source/c02/c02_07.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_08.rst b/source/c02/c02_08.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_09.rst b/source/c02/c02_09.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_10.rst b/source/c02/c02_10.rst
old mode 100755
new mode 100644
diff --git a/source/c02/c02_11.rst b/source/c02/c02_11.rst
old mode 100755
new mode 100644
diff --git a/source/c03/c03_01.rst b/source/c03/c03_01.rst
old mode 100755
new mode 100644
diff --git a/source/c03/c03_02.rst b/source/c03/c03_02.rst
old mode 100755
new mode 100644
diff --git a/source/c03/c03_03.rst b/source/c03/c03_03.rst
old mode 100755
new mode 100644
diff --git a/source/c03/c03_04.rst b/source/c03/c03_04.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_01.rst b/source/c04/c04_01.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_02.rst b/source/c04/c04_02.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_03.rst b/source/c04/c04_03.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_04.rst b/source/c04/c04_04.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_05.rst b/source/c04/c04_05.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_06.rst b/source/c04/c04_06.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_07.rst b/source/c04/c04_07.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_08.rst b/source/c04/c04_08.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_09.rst b/source/c04/c04_09.rst
old mode 100755
new mode 100644
diff --git a/source/c04/c04_10.rst b/source/c04/c04_10.rst
old mode 100755
new mode 100644
diff --git a/source/c05/c05_01.rst b/source/c05/c05_01.rst
old mode 100755
new mode 100644
diff --git a/source/c05/c05_02.rst b/source/c05/c05_02.rst
old mode 100755
new mode 100644
diff --git a/source/c05/c05_03.rst b/source/c05/c05_03.rst
old mode 100755
new mode 100644
diff --git a/source/c06/c06_01.rst b/source/c06/c06_01.rst
old mode 100755
new mode 100644
diff --git a/source/c06/c06_02.rst b/source/c06/c06_02.rst
old mode 100755
new mode 100644
diff --git a/source/c06/c06_03.rst b/source/c06/c06_03.rst
old mode 100755
new mode 100644
diff --git a/source/c06/c06_04.rst b/source/c06/c06_04.rst
old mode 100755
new mode 100644
diff --git a/source/c06/c06_05.rst b/source/c06/c06_05.rst
old mode 100755
new mode 100644
diff --git a/source/c06/c06_06.rst b/source/c06/c06_06.rst
old mode 100755
new mode 100644
diff --git a/source/c07/c07_01.rst b/source/c07/c07_01.rst
old mode 100755
new mode 100644
diff --git a/source/c07/c07_02.rst b/source/c07/c07_02.rst
old mode 100755
new mode 100644
diff --git a/source/c07/c07_03.rst b/source/c07/c07_03.rst
old mode 100755
new mode 100644
diff --git a/source/c07/c07_04.rst b/source/c07/c07_04.rst
old mode 100755
new mode 100644
diff --git a/source/c07/c07_05.rst b/source/c07/c07_05.rst
old mode 100755
new mode 100644
diff --git a/source/c07/c07_06.rst b/source/c07/c07_06.rst
old mode 100755
new mode 100644
diff --git a/source/c07/c07_07.rst b/source/c07/c07_07.rst
old mode 100755
new mode 100644
diff --git a/source/c08/c08_01.rst b/source/c08/c08_01.rst
old mode 100755
new mode 100644
diff --git a/source/c08/c08_02.rst b/source/c08/c08_02.rst
old mode 100755
new mode 100644
diff --git a/source/c08/c08_03.md b/source/c08/c08_03.md
index 18a1d18..ef1e329 100644
--- a/source/c08/c08_03.md
+++ b/source/c08/c08_03.md
@@ -87,7 +87,8 @@ virt-install --name ubuntu-16.04 \
- listen='0.0.0.0'>
+
+
diff --git a/source/c08/c08_03.rst b/source/c08/c08_03.rst
old mode 100755
new mode 100644
index 758198f..f456eb5
--- a/source/c08/c08_03.rst
+++ b/source/c08/c08_03.rst
@@ -99,7 +99,8 @@
- listen='0.0.0.0'>
+
+
diff --git a/source/c08/c08_16.md b/source/c08/c08_16.md
index ad70dbe..eb9283b 100644
--- a/source/c08/c08_16.md
+++ b/source/c08/c08_16.md
@@ -246,8 +246,6 @@ $ nova meta b1575f81-0a33-4872-995e-2c2dd48d52c8 set __system__vif_inbound_avera
$ nova meta b1575f81-0a33-4872-995e-2c2dd48d52c8 set __system__vif_inbound_average=12500 __system__vif_inbound_burst=10000 __system__vif_outbound_average=12500 __system__vif_outbound_burst=10000
```
-
-
## 3. 带宽单位换算
带宽,英文名 Bandwidth,在不同领域的含义各不相同,而在网络服务中,带宽是指单位时间内的流经数据量。
diff --git a/source/chapters/p01.rst b/source/chapters/p01.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p02.rst b/source/chapters/p02.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p03.rst b/source/chapters/p03.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p04.rst b/source/chapters/p04.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p05.rst b/source/chapters/p05.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p06.rst b/source/chapters/p06.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p07.rst b/source/chapters/p07.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p08.rst b/source/chapters/p08.rst
old mode 100755
new mode 100644
diff --git a/source/chapters/p10.rst b/source/chapters/p10.rst
old mode 100755
new mode 100644
diff --git a/source/conf.py b/source/conf.py
old mode 100755
new mode 100644
index fdcb6f7..d15ed1c
--- a/source/conf.py
+++ b/source/conf.py
@@ -28,7 +28,7 @@
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
-extensions = ['chinese_search','sphinx.ext.mathjax', 'sphinx_sitemap']
+extensions = ['chinese_search','sphinx.ext.mathjax', 'sphinx_sitemap', 'sphinx_multiversion']
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
@@ -127,28 +127,25 @@
sys.path.append(os.path.abspath(_exts))
html_js_files = [
- 'js/readmore.js',
+# 'js/readmore.js',
'js/baidutongji.js',
]
-# General configuration.
-with open("/home/docs/checkouts/readthedocs.org/user_builds/pythoncodingtime/envs/latest/lib/python3.7/site-packages/sphinxcontrib/disqus.py", "r") as file:
- content = file.read()
- content=content.replace("sphinx.application", "sphinx.errors")
-
-with open("/home/docs/checkouts/readthedocs.org/user_builds/pythoncodingtime/envs/latest/lib/python3.7/site-packages/sphinxcontrib/disqus.py", "w") as file:
- file.write(content)
author = '王炳明'
-copyright = '2020, Python编程时光'
+copyright = '2020-2024, Python编程时光'
exclude_patterns = ['_build']
-extensions = ['sphinxcontrib.disqus'] # Add to this list.
master_doc = 'index'
project = 'Python编程时光'
-release = '1.0'
-version = '1.0'
# Options for extensions.
-disqus_shortname = 'iswbm' # Add this line to conf.py.
-html_baseurl = 'http://pythontime.iswbm.com'
+html_baseurl = 'https://magic.iswbm.com'
html_extra_path = ["robots.txt"]
+
+html_sidebars = {
+ '**': [
+ 'versioning.html',
+ ],
+}
+smv_latest_version = 'master'
+sitemap_url_scheme = "{link}"
diff --git a/source/index.rst b/source/index.rst
old mode 100755
new mode 100644
diff --git a/source/lc01/1-10.rst b/source/lc01/1-10.rst
old mode 100755
new mode 100644
diff --git a/source/leetcode/leetcode.rst b/source/leetcode/leetcode.rst
old mode 100755
new mode 100644
diff --git a/source/preface.rst b/source/preface.rst
old mode 100755
new mode 100644
diff --git a/source/roadmap.rst b/source/roadmap.rst
old mode 100755
new mode 100644