print curl version again #3
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
name: "Lint my Caddyfiles" | ||
on: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/workflows/caddy_fmt.yml' | ||
- 'Caddyfile' | ||
- '**/Caddyfile' | ||
- '**/*.Caddyfile' | ||
pull_request: | ||
branches: | ||
- main | ||
paths: | ||
- '.github/workflows/caddy_fmt.yml' | ||
- 'Caddyfile' | ||
- '**/Caddyfile' | ||
- '**/*.Caddyfile' | ||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: "Check out the repo" | ||
uses: actions/checkout@v4 | ||
- name: Install curl, check version | ||
apt install -y debian-keyring debian-archive-keyring apt-transport-https curl | ||
curl --version | ||
- name: Install Caddy | ||
run: | ||
# These instructions for installing Caddy are taken from | ||
# the Caddy docs: | ||
# https://caddyserver.com/docs/install#static-binaries | ||
apt install -y debian-keyring debian-archive-keyring apt-transport-https curl | ||
curl --version | ||
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | sudo gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg | ||
curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | sudo tee /etc/apt/sources.list.d/caddy-stable.list | ||
apt update | ||
apt install caddy | ||
- name: Format my Caddyfiles | ||
run: find . -name Caddyfile -o -name '*.Caddyfile' | xargs caddy fmt --overwrite | ||
- name: Check for changes | ||
run: git diff --exit-code |