From 6776edbd1629e7bb561929c530773468d9c02e70 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=8C=81=E5=A3=AE=E6=88=90=E9=95=BF?= <2291200076@qq.com> Date: Sat, 7 Aug 2021 01:26:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0Windows=E5=B9=B3=E5=8F=B0?= =?UTF-8?q?=E4=B8=8Bdocsify-cli=E5=AE=89=E8=A3=85=E5=8F=8A=E6=9C=AC?= =?UTF-8?q?=E5=9C=B0docsify=20serve=E5=90=AF=E5=8A=A8bat=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- npm-install-docsify-cli(Windows).bat | 17 +++++++++++++++++ run-docsify-server(Windows).bat | 20 ++++++++++++++++++++ 2 files changed, 37 insertions(+) create mode 100644 npm-install-docsify-cli(Windows).bat create mode 100644 run-docsify-server(Windows).bat diff --git a/npm-install-docsify-cli(Windows).bat b/npm-install-docsify-cli(Windows).bat new file mode 100644 index 0000000..85603a9 --- /dev/null +++ b/npm-install-docsify-cli(Windows).bat @@ -0,0 +1,17 @@ +:: +:: 背Ta单词 BTadc +:: +:: 该脚本仅在Windows下有效,且需要安装npm之后才可使用 +:: +:: @version 1.0.0 +:: @auther Coding Zhang +:: @modify 2021.08.07 +:: + +@echo off + +:: 全局安装docsify-cli工具 +call npm i docsify-cli -g + +:: 按任意键继续 +pause \ No newline at end of file diff --git a/run-docsify-server(Windows).bat b/run-docsify-server(Windows).bat new file mode 100644 index 0000000..8e287a3 --- /dev/null +++ b/run-docsify-server(Windows).bat @@ -0,0 +1,20 @@ +:: +:: 背Ta单词 BTadc +:: +:: 该脚本仅在Windows下有效,且需要在npm安装docsify-cli工具之后才可使用 +:: +:: @version 1.0.0 +:: @auther Coding Zhang +:: @modify 2021.08.07 +:: + +@echo off + +:: 找到系统默认浏览器 +for /f "tokens=3,4" %%a in ('"reg query HKEY_CLASSES_ROOT\http\shell\open\command"') do (set softWareRoot=%%a %%b) + +::打开网页 +start % SoftWareRoot % http://localhost:3000 + +:: 启动docsify服务 +docsify serve docs \ No newline at end of file