-
-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (53 loc) · 1.51 KB
/
Copy pathnimble-site.yml
File metadata and controls
53 lines (53 loc) · 1.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# SPDX-License-Identifier: MPL-2.0
name: NimblePublisher Site
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: erlef/setup-beam@54075bcc5e249e4758d363f27d099f55d843f124 # v1
with:
elixir-version: "1.15"
otp-version: "26"
- name: Fetch dependencies
run: |
cd site
mix deps.get
- name: Build site
run: |
cd site
mix site.build
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@fc324d3547104276b827a68afc52ff2a11cc49c9 # v4
with:
path: site/_site
deploy:
needs: build
# Only deploy from the default branch — never from a pull request, which
# would publish unmerged content to the live Pages site.
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
timeout-minutes: 15
permissions:
pages: write
contents: read
# Required by actions/deploy-pages for OIDC token minting.
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0