From faa6021461ea3b2bda233d7daa21db6ccf6f4eed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E2=98=99=E2=97=A6=20The=20Tablet=20=E2=9D=80=20GamerGirla?= =?UTF-8?q?ndCo=20=E2=97=A6=E2=9D=A7?= Date: Tue, 2 Jan 2024 18:52:03 -0500 Subject: [PATCH] add gitlab ci stuffz --- .gitlab-ci.yml | 19 +++++++++++++++++++ .gitlab/hugo.template.yml | 30 ++++++++++++++++++++++++++++++ 2 files changed, 49 insertions(+) create mode 100644 .gitlab-ci.yml create mode 100644 .gitlab/hugo.template.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000..5dad6e7 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,19 @@ +variables: + GIT_SUBMODULE_STRATEGY: recursive +include: + - file: '/action.yml' + project: 'templates/hugo-obsidian' + inputs: + index: "true" + input: content + output: assets/indices + root: . + - file: "/.gitlab/hugo.template.yml" +stages: + - index + - setup-hugo + - deploy +deploy: + stage: deploy + script: + - cp -r ${CI_PROJECT_DIR}/* ${DEPLOY_PATH} \ No newline at end of file diff --git a/.gitlab/hugo.template.yml b/.gitlab/hugo.template.yml new file mode 100644 index 0000000..72de329 --- /dev/null +++ b/.gitlab/hugo.template.yml @@ -0,0 +1,30 @@ +name: 'Hugo setup' +description: 'GitHub Actions for Hugo ⚡️ Setup Hugo quickly and build your site fast. Hugo extended and Hugo Modules are supported.' +spec: + inputs: + hugo-version: + description: 'The Hugo version to download (if necessary) and use. Example: 0.58.2' + required: false + default: 'latest' + extended: + description: 'Download (if necessary) and use Hugo extended version. Example: true' + required: false + default: 'false'recursive + HUGO_ENV: production +--- + +variables: + GIT_SUBMODULE_STRATEGY: recursive +setup-hugo: + stage: setup-hugo + image: registry.gitlab.com/pages/hugo/hugo_extended:latest + script: + - cd ${CI_PROJECT_DIR} + - hugo --minify + +# runs: +# using: 'node16' +# main: 'lib/index.js' +# branding: +# icon: 'package' +# color: 'yellow' \ No newline at end of file