Skip to content
Snippets Groups Projects

Feature to automatically generate GitLab static webpage from text (Stages changelog)

Merged Abhiraj Bishnoi requested to merge bishnoi1/stages-changelog:main into main
9 files
+ 637
1
Compare changes
  • Side-by-side
  • Inline
Files
9
.gitlab-ci.yml 0 → 100644
+ 35
0
 
typeset-html:
 
cache: {}
 
tags:
 
- public-docker
 
image:
 
name: thomasweise/docker-pandoc:3.3
 
entrypoint: ['/bin/bash', '-c', 'ln -snf /bin/bash /bin/sh && /bin/bash -c $0' ]
 
script:
 
- make -B html
 
artifacts:
 
name: "$CI_JOB_NAME-$CI_COMMIT_REF_NAME"
 
paths:
 
- stages-changelog.html
 
 
pages:
 
cache: {}
 
stage: deploy
 
tags:
 
- public-docker
 
image: alpine:latest
 
script:
 
- apk --update add git sed
 
- mkdir public
 
- cp stages-changelog.html public/index.html
 
- git checkout -f pages
 
- git reset --hard origin/pages
 
- sed -n -i -e "/<\/header>/r snippet.disclaimer.html" -e 1x -e '2,${x;p}' -e '${x;p}' public/index.html
 
- sed -i "s/HASH/"`git rev-parse --short HEAD`"/" snippet.build.html
 
- sed -n -i -e "/<\/body>/r snippet.build.html" -e 1x -e '2,${x;p}' -e '${x;p}' public/index.html
 
- sed -i '/<meta charset.*/a \ <meta name="robots" content="noindex">' public/index.html
 
artifacts:
 
paths:
 
- public
 
only:
 
- master
 
\ No newline at end of file
Loading