From 509003591eb3400a56eb67c6b4caa0ed71f9f3c6 Mon Sep 17 00:00:00 2001 From: Riccardo Belluzzo Date: Mon, 19 Feb 2024 13:51:50 +0100 Subject: [PATCH] deploy.yml workflow added --- .github/workflows/deploy.yml | 32 ++++++++++++++++++++++++++++++++ Makefile | 6 +++++- 2 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/deploy.yml diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 0000000..479fe07 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,32 @@ +name: Deploy docs + +on: + workflow_dispatch: + push: + branches: main + paths: + - 'docs/**' + - 'mkdocs.yml' + - 'Pipfile' + +jobs: + build: + runs-on: [self-hosted, linux] + steps: + + - uses: actions/checkout@v4 + + - uses: actions/setup-python@v4 + with: + python-version: '3.10' + + - run: python -m pip install build + + - name: Install poetry + run: make install-poetry + + - name: Install dependencies + run: make install-env + + - name: Build and Deploy docs + run: make deploy-docs \ No newline at end of file diff --git a/Makefile b/Makefile index 3c8b386..08738a1 100644 --- a/Makefile +++ b/Makefile @@ -12,4 +12,8 @@ linter:: poetry run pylint llm_wrapper --reports=no --output-format=colorized --fail-under=8.0 tests:: - poetry run python -m pytest -s --verbose \ No newline at end of file + poetry run python -m pytest -s --verbose + + +deploy-docs:: + poetry run mkdocs gh-deploy --force \ No newline at end of file