mirror of
https://github.com/foo-dogsquared/hugo-theme-more-contentful.git
synced 2025-01-30 22:57:57 +00:00
Replace Travis CI with GitHub workflows
This commit is contained in:
parent
6ce4679dbc
commit
9e8d53bf02
19
.github/workflows/build.yml
vendored
Normal file
19
.github/workflows/build.yml
vendored
Normal file
@ -0,0 +1,19 @@
|
||||
name: "Build demo"
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
jobs:
|
||||
build:
|
||||
run-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: cachix/install-nix-action@v17
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixpkgs-unstable
|
||||
- run: nix develop -c hugo -s ./exampleSite/
|
||||
- name: Deploy to GitHub Pages
|
||||
uses: JamesIves/github-pages-deploy-action@v4.3.3
|
||||
with:
|
||||
branch: gh-pages
|
||||
folder: exampleSite/public
|
35
.travis.yml
35
.travis.yml
@ -1,35 +0,0 @@
|
||||
dist: bionic
|
||||
language: generic
|
||||
|
||||
branches:
|
||||
only:
|
||||
- master
|
||||
- demo
|
||||
|
||||
before_install:
|
||||
- sudo apt-get update
|
||||
- sudo apt-get install python3
|
||||
- sudo apt-get install ruby wget
|
||||
- wget "https://github.com/gohugoio/hugo/releases/download/v${HUGO_RELEASE}/hugo_extended_${HUGO_RELEASE}_Linux-64bit.deb"
|
||||
- sudo dpkg -i *.deb
|
||||
- sudo gem install asciidoctor
|
||||
|
||||
script:
|
||||
- curl https://api.github.com/repos/foo-dogsquared/hugo-theme-more-contentful | jq '.[0].sha' --raw-output | xargs -I{} hugo mod get "github.com/foo-dogsquared/hugo-theme-more-contentful@{}" && hugo mod tidy
|
||||
- hugo
|
||||
|
||||
env:
|
||||
global:
|
||||
- PRODUCTION=true
|
||||
- HUGO_RELEASE=0.76.0
|
||||
|
||||
deploy:
|
||||
local_dir: "./public/"
|
||||
provider: pages
|
||||
skip_cleanup: true
|
||||
github_token: $GITHUB_TOKEN # Set in the settings page of your repository, as a secure variable
|
||||
target_branch: gh-pages
|
||||
on:
|
||||
branch:
|
||||
- demo
|
||||
- master
|
@ -44,6 +44,8 @@ E.g., if there is only `_dark`, the Hugo theme will generate the light theme.
|
||||
|
||||
** If given neither, fallback themes will be used.
|
||||
|
||||
* Replace Travis CI with GitHub workflows.
|
||||
|
||||
|
||||
=== Fixed
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user