Create a blog post about the new name #482
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Copyright 2023 Red Hat, Inc. | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software | |
# distributed under the License is distributed on an "AS IS" BASIS, | |
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | |
# See the License for the specific language governing permissions and | |
# limitations under the License. | |
# | |
# SPDX-License-Identifier: Apache-2.0 | |
--- | |
name: Build | |
'on': | |
workflow_call: | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build-hugo: | |
runs-on: ubuntu-latest | |
env: | |
HUGO_VERSION: 0.111.3 | |
steps: | |
- name: Checkout | |
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- name: Setup NodeJS environment | |
uses: actions/setup-node@39370e3970a6d050c480ffad4ff0ed4d3fdee5af # v4.1.0 | |
with: | |
node-version-file: 'antora/package.json' | |
cache: 'npm' | |
cache-dependency-path: 'antora/package-lock.json' | |
- name: Setup Go environment | |
uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0 | |
with: | |
go-version-file: website/go.mod | |
cache: true | |
cache-dependency-path: website/go.sum | |
- name: Install Hugo CLI | |
run: | | |
wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \ | |
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb | |
- name: Install Dart Sass Embedded | |
run: sudo snap install dart-sass-embedded | |
- name: Build documentation | |
run: npm --prefix antora ci && npm --prefix antora run build | |
- name: Build with Hugo | |
env: | |
HUGO_ENVIRONMENT: ${{ github.event_name == 'pull_request' && 'development' || 'production'}} | |
HUGO_ENV: ${{ github.event_name == 'pull_request' && 'development' || 'production'}} | |
run: | | |
hugo \ | |
--source website \ | |
--gc \ | |
--minify \ | |
--baseURL "${{ steps.pages.outputs.base_url }}/" | |
- name: Upload artifact | |
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0 | |
with: | |
path: public | |
name: website | |
pull-request-data: | |
runs-on: ubuntu-latest | |
if: github.event_name == 'pull_request' | |
steps: | |
- name: Create pull request data | |
run: | | |
mkdir pull_request | |
echo ${{ github.event.pull_request.number }} > ./pull_request/number | |
- name: Upload pull request data | |
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0 | |
with: | |
path: . | |
name: pull-request-data |