Skip to content

Commit

Permalink
fixup ci
Browse files Browse the repository at this point in the history
  • Loading branch information
mhils committed Jul 30, 2024
1 parent 627d826 commit 9e93fb9
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 36 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,18 @@ name: CI

on: [push, pull_request]

permissions:
contents: read

jobs:
build:
uses: mhils/workflows/.github/workflows/gh-pages-hugo.yml@v7
with:
deploy: false
permissions:
contents: read
id-token: write
pages: write
docs:
runs-on: ubuntu-latest
steps:
Expand Down
35 changes: 0 additions & 35 deletions build.sh

This file was deleted.

27 changes: 26 additions & 1 deletion ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,29 @@ set -o pipefail
set -o nounset
# set -o xtrace

./build.sh
cd src

# check for valid JSON
cat assets/data/publications.json | jq empty

# check for existing publication types
allowed_types=$(cat <<-MOT
blog post
media
research
talk
MOT
)
types=$(cat assets/data/publications.json | jq -r '.[].type' | sort | uniq)

if [[ ${types} != ${allowed_types} ]]; then
echo "Found invalid publication type!"
exit 1
fi

conference_missing=$(cat assets/data/publications.json | jq '.[] | select(.type =="research") | select(.conference == null)')
if [ -n "$conference_missing" ]; then
echo "Research artifact without conference!"
echo "$conference_missing"
exit 1
fi

0 comments on commit 9e93fb9

Please sign in to comment.