You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ro...@apache.org on 2024/05/02 22:42:29 UTC

(couchdb) branch fix-docs-env-win created (now 603f391c0)

This is an automated email from the ASF dual-hosted git repository.

ronny pushed a change to branch fix-docs-env-win
in repository https://gitbox.apache.org/repos/asf/couchdb.git


      at 603f391c0 Create Python virtualenv on Windows for docs

This branch includes the following new commits:

     new 603f391c0 Create Python virtualenv on Windows for docs

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



(couchdb) 01/01: Create Python virtualenv on Windows for docs

Posted by ro...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ronny pushed a commit to branch fix-docs-env-win
in repository https://gitbox.apache.org/repos/asf/couchdb.git

commit 603f391c04e4f6c640b43bb65d188082ea24d500
Author: Ronny Berndt <ro...@apache.org>
AuthorDate: Fri May 3 00:38:11 2024 +0200

    Create Python virtualenv on Windows for docs
    
    Add an equivalent setup script for Windows to
    init python dev environment for building docs.
---
 Makefile.win       |  2 +-
 src/docs/setup.bat | 11 +++++++++++
 2 files changed, 12 insertions(+), 1 deletion(-)

diff --git a/Makefile.win b/Makefile.win
index a827c0502..7123003d6 100644
--- a/Makefile.win
+++ b/Makefile.win
@@ -477,7 +477,7 @@ config.erl:
 src\docs\build:
 	@echo 'Building docs...'
 ifeq ($(with_docs), 1)
-	@cd src\docs && make.bat html && make.bat man
+	@cd src\docs && setup.bat && make.bat html && make.bat man
 endif
 
 
diff --git a/src/docs/setup.bat b/src/docs/setup.bat
new file mode 100644
index 000000000..736aba45c
--- /dev/null
+++ b/src/docs/setup.bat
@@ -0,0 +1,11 @@
+@echo off
+
+IF NOT EXIST "%CD%\.venv\Scripts\activate" (
+  DEL /S "%CD%\.venv"
+  python "-m" "venv" ".venv"
+  "%CD%\.venv\Scripts\activate.bat"
+  pip "install" "--upgrade" "pip"
+  pip "install" "-r" "requirements.txt"
+) ELSE (
+  "%CD%\.venv\Scripts\activate.bat"
+)
\ No newline at end of file