mirror of
https://codeberg.org/Codeberg-CI/examples.git
synced 2025-08-03 20:06:00 -04:00
Migrate from depricated syntax to current (#60)
like https://codeberg.org/Codeberg-CI/examples/pulls/59 It addresses deprecation's upcoming in v2.8.0 now Reviewed-on: https://codeberg.org/Codeberg-CI/examples/pulls/60
This commit is contained in:
parent
0b4e537b2c
commit
4f535b51bf
@ -6,11 +6,11 @@ steps:
|
||||
image: golang
|
||||
environment:
|
||||
# Needed if you want to cross-compile and package the binary in a container.
|
||||
- CGO_ENABLED=0
|
||||
CGO_ENABLED: 0
|
||||
# Select your target OS:
|
||||
- GOOS=linux
|
||||
GOOS: linux
|
||||
# Select your target architecture:
|
||||
- GOARCH=amd64
|
||||
GOARCH: amd64
|
||||
commands:
|
||||
- go get
|
||||
- go build
|
||||
|
@ -36,10 +36,13 @@ steps:
|
||||
|
||||
publish:
|
||||
image: bitnami/git
|
||||
# Must be set in Woodpecker configuration
|
||||
secrets: [mail, codeberg_token]
|
||||
environment:
|
||||
- HUGO_OUTPUT=public
|
||||
HUGO_OUTPUT: public
|
||||
# secrets must be set in Woodpecker configuration
|
||||
MAIL:
|
||||
from_secret: mail
|
||||
CODEBERG_TOKEN:
|
||||
from_secret: codeberg_token
|
||||
commands:
|
||||
# Git configuration
|
||||
- git config --global user.email $MAIL
|
||||
|
@ -25,7 +25,12 @@ steps:
|
||||
event: [push, pull_request]
|
||||
# Use the official jekyll build container
|
||||
image: jekyll/jekyll
|
||||
secrets: [cbtoken, cbmail]
|
||||
environment:
|
||||
# secrets must be set in Woodpecker configuration
|
||||
CBMAIL:
|
||||
from_secret: cbmail
|
||||
CBTOKEN:
|
||||
from_secret: cbtoken
|
||||
commands:
|
||||
# Avoid permission denied errors
|
||||
- chmod -R a+w .
|
||||
|
@ -27,9 +27,13 @@ steps:
|
||||
|
||||
publish:
|
||||
image: bitnami/git
|
||||
secrets: [mail, codeberg_token]
|
||||
environment:
|
||||
- MDBOOK_OUTPUT=book
|
||||
MDBOOK_OUTPUT: book
|
||||
# secrets must be set in Woodpecker configuration
|
||||
MAIL:
|
||||
from_secret: mail
|
||||
CODEBERG_TOKEN:
|
||||
from_secret: codeberg_token
|
||||
commands:
|
||||
- git config --global user.email $MAIL
|
||||
- git config --global user.name "Woodpecker CI"
|
||||
|
@ -27,7 +27,18 @@ steps:
|
||||
event: [push, pull_request]
|
||||
# Use the official jekyll build container
|
||||
image: node
|
||||
secrets: [cbtoken, cbmail, cbusername, sourcerepo, destrepo]
|
||||
environment:
|
||||
# secrets must be set in Woodpecker configuration
|
||||
CBTOKEN:
|
||||
from_secret: cbtoken
|
||||
CBMAIL:
|
||||
from_secret: cbmail
|
||||
CBUSERNAME:
|
||||
from_secret: cbusername
|
||||
SOURCEREPO:
|
||||
from_secret: sourcerepo
|
||||
DESTREPO:
|
||||
from_secret: destrepo
|
||||
commands:
|
||||
# Avoid permission denied errors
|
||||
- chmod -R a+w .
|
||||
|
@ -26,7 +26,10 @@ steps:
|
||||
|
||||
publish:
|
||||
image: bitnami/git:2
|
||||
secrets: [cbtoken]
|
||||
environment:
|
||||
# secrets must be set in Woodpecker configuration
|
||||
CBTOKEN:
|
||||
from_secret: cbtoken
|
||||
commands:
|
||||
# config git to commit and push changes
|
||||
- git config --global --add safe.directory $CI_WORKSPACE/public
|
||||
|
@ -13,7 +13,11 @@ steps:
|
||||
when:
|
||||
event: [push, pull_request]
|
||||
image: rocker/r-base
|
||||
secrets: [github_pat]
|
||||
environment:
|
||||
# secrets must be set in Woodpecker configuration
|
||||
# GitHub personal access token (PAT) used for authenticating API requests to avoid rate limiting
|
||||
GITHUB_PAT:
|
||||
from_secret: github_pat
|
||||
commands:
|
||||
- R -q -s -e 'install.packages("pak", repos = sprintf("https://r-lib.github.io/p/pak/stable/%s/%s/%s", .Platform$pkgType, R.Version()$os, R.Version()$arch))'
|
||||
- R -q -e 'options(Ncpus = 4)'
|
||||
|
@ -6,7 +6,7 @@ steps:
|
||||
check:
|
||||
image: eldesh/smlnj
|
||||
environment:
|
||||
- SML_FOLDER=src
|
||||
SML_FOLDER: src
|
||||
commands:
|
||||
- find $SML_FOLDER -name *.sml | xargs sml
|
||||
when:
|
||||
|
@ -25,8 +25,8 @@ steps:
|
||||
event: [push, pull_request]
|
||||
image: dxjoke/tectonic-docker
|
||||
environment:
|
||||
- TEX_FOLDER=docs
|
||||
- TEX_FILENAME=report
|
||||
TEX_FOLDER: docs
|
||||
TEX_FILENAME: report
|
||||
commands:
|
||||
- tectonic -r 1 $TEX_FOLDER/$TEX_FILENAME.tex
|
||||
deploy:
|
||||
@ -35,12 +35,16 @@ steps:
|
||||
event: [push, pull_request]
|
||||
image: alpine/git
|
||||
environment:
|
||||
- TEX_FOLDER=docs
|
||||
- TEX_FILENAME=report
|
||||
- OUT_REPO_NAME=pages
|
||||
- PDF_FOLDER=archive
|
||||
- PDF_FILENAME=project
|
||||
secrets: [cbtoken, cbmail]
|
||||
TEX_FOLDER: docs
|
||||
TEX_FILENAME: report
|
||||
OUT_REPO_NAME: pages
|
||||
PDF_FOLDER: archive
|
||||
PDF_FILENAME: project
|
||||
# secrets must be set in Woodpecker configuration
|
||||
CBTOKEN:
|
||||
from_secret: cbtoken
|
||||
CBMAIL:
|
||||
from_secret: cbmail
|
||||
commands:
|
||||
# Avoid permission denied errors
|
||||
- chmod -R a+w .
|
||||
|
@ -25,19 +25,23 @@ steps:
|
||||
event: [push, pull_request]
|
||||
image: 123marvin123/typst
|
||||
environment:
|
||||
- TYPST_FOLDER=docs
|
||||
- TYPST_FILENAME=report
|
||||
TYPST_FOLDER: docs
|
||||
TYPST_FILENAME: report
|
||||
commands:
|
||||
- typst $TYPST_FOLDER/$TYPST_FILENAME.typ
|
||||
deploy:
|
||||
image: alpine/git
|
||||
environment:
|
||||
- TYPST_FOLDER=docs
|
||||
- TYPST_FILENAME=report
|
||||
- OUT_REPO_NAME=pages
|
||||
- PDF_FOLDER=archive
|
||||
- PDF_FILENAME=project
|
||||
secrets: [cbtoken, cbmail]
|
||||
TYPST_FOLDER: docs
|
||||
TYPST_FILENAME: report
|
||||
OUT_REPO_NAME: pages
|
||||
PDF_FOLDER: archive
|
||||
PDF_FILENAME: project
|
||||
# secrets must be set in Woodpecker configuration
|
||||
CBTOKEN:
|
||||
from_secret: cbtoken
|
||||
CBMAIL:
|
||||
from_secret: cbmail
|
||||
commands:
|
||||
# Avoid permission denied errors
|
||||
- chmod -R a+w .
|
||||
|
@ -32,13 +32,18 @@ steps:
|
||||
|
||||
publish:
|
||||
image: bitnami/git
|
||||
secrets: [mail, codeberg_token]
|
||||
environment:
|
||||
# secrets must be set in Woodpecker configuration
|
||||
TOKEN:
|
||||
from_secret: cbtoken
|
||||
MAIL:
|
||||
from_secret: cbmail
|
||||
commands:
|
||||
# Configure Git
|
||||
- git config --global user.email $MAIL
|
||||
- git config --global user.name "Woodpecker CI"
|
||||
# Clone the output branch
|
||||
- git clone --branch pages https://$CODEBERG_TOKEN@codeberg.org/$CI_REPO.git $CI_REPO_NAME
|
||||
- git clone --branch pages https://$TOKEN@codeberg.org/$CI_REPO.git $CI_REPO_NAME
|
||||
# Enter the output branch
|
||||
- cd $CI_REPO_NAME
|
||||
# Remove old files
|
||||
|
Loading…
x
Reference in New Issue
Block a user