From eb028f8dbbbe85b7d5db11b04c0d3d25e97731c8 Mon Sep 17 00:00:00 2001 From: Kwangjin Lee Date: Wed, 2 Oct 2024 16:15:15 +0200 Subject: [PATCH] change branch and test --- .gitlab-ci.yml | 12 +++--------- book/installation-and-setup/creating_content.md | 2 +- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7eb347c..333f76d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,18 +2,15 @@ stages: - test - build - deploy - variables: PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip" REGISTRY_HOST: localhost:5000 TAG_LATEST: $REGISTRY_HOST/$CI_PROJECT_NAME/$CI_COMMIT_REF_NAME:latest TAG_DRAFT: $REGISTRY_HOST/$CI_PROJECT_NAME-draft/$CI_COMMIT_REF_NAME:latest GIT_SUBMODULE_STRATEGY: recursive # For submodules - cache: paths: - .cache/pip - # This job tests if the book compiles gracefully after a new addition test-build: stage: test @@ -24,13 +21,12 @@ test-build: - pip install -r requirements.txt - jupyter-book clean book/ - jupyter-book build book/ - # This job builds the Docker container build-book: stage: build image: docker rules: - - if: $CI_COMMIT_BRANCH == "publish" && $CI_PIPELINE_SOURCE == "push" + - if: $CI_COMMIT_BRANCH == "release" && $CI_PIPELINE_SOURCE == "push" variables: TAG: $TAG_LATEST - if: $CI_COMMIT_BRANCH == "main" && $CI_PIPELINE_SOURCE == "push" @@ -42,13 +38,12 @@ build-book: - if [ "$TAG" = "$TAG_LATEST" ]; then sed --in-place=".bak" '/# START DRAFT/,/# END DRAFT/{//!d}' book/_config.yml; fi - docker build -t $TAG . - docker push $TAG - # This job takes down the existing container and starts the new one deploy-book: stage: deploy image: docker rules: - - if: $CI_COMMIT_BRANCH == "publish" && $CI_PIPELINE_SOURCE == "push" + - if: $CI_COMMIT_BRANCH == "release" && $CI_PIPELINE_SOURCE == "push" before_script: - docker info - docker stop $CI_PROJECT_NAME || exit_code=$? @@ -58,7 +53,6 @@ deploy-book: environment: name: production url: https://interactivetextbooks.citg.tudelft.nl/jupyter-book-manual - # Deploy the draft version of the book deploy-draft: stage: deploy @@ -73,4 +67,4 @@ deploy-draft: - docker run -d --restart always -p 8018:8000 --name $CI_PROJECT_NAME-draft $TAG_DRAFT environment: name: draft - url: https://interactivetextbooks.citg.tudelft.nl/jupyter-book-manual-draft + url: https://interactivetextbooks.citg.tudelft.nl/jupyter-book-manual-draft \ No newline at end of file diff --git a/book/installation-and-setup/creating_content.md b/book/installation-and-setup/creating_content.md index 613f849..2fd16de 100644 --- a/book/installation-and-setup/creating_content.md +++ b/book/installation-and-setup/creating_content.md @@ -2,7 +2,7 @@ The previous sections have familiarized you with the necessary software for your user type, the basics of Git, and how to collaborate with your team using Git. Now it's time to create your own content. This section will provide an overview of the copy right laws which need to be taking into account when creating and including content at TU Delft! -# Checklist +# Checklist test text Although the focus of TeachBooks is mostly to help the teaching staff create interactive textbooks for their students, it can be attractive to spread ones wings a bit and reach a wider audience. The following section will be all about what you have to keep in mind in terms of copy right and what you should know to avoid major legal issues and make your life easier later on when/if you decide to publish your book with an open license, especially via TU Delft Open. For more information you can find everything on the [TU Delft website](https://www.tudelft.nl/library/support/copyright)