mirror of
https://codeberg.org/JasterV/intisync.ex.git
synced 2026-04-26 18:10:07 +00:00
chore: migrate from github actions to woodpecker
This commit is contained in:
parent
1d1f856a1e
commit
a440d2a0cf
3 changed files with 17 additions and 101 deletions
22
.github/dependabot.yml
vendored
22
.github/dependabot.yml
vendored
|
|
@ -1,22 +0,0 @@
|
|||
version: 2
|
||||
updates:
|
||||
# Specifying multiple directories for a single package ecosystem
|
||||
# is a work in progress: https://github.com/dependabot/dependabot-core/issues/2178
|
||||
- package-ecosystem: mix
|
||||
directory: "/"
|
||||
schedule:
|
||||
interval: weekly
|
||||
allow:
|
||||
- dependency-type: direct
|
||||
|
||||
- package-ecosystem: npm
|
||||
directory: "/assets"
|
||||
schedule:
|
||||
interval: weekly
|
||||
allow:
|
||||
- dependency-type: direct
|
||||
|
||||
- package-ecosystem: "github-actions"
|
||||
directory: "/"
|
||||
schedule:
|
||||
interval: weekly
|
||||
79
.github/workflows/ci.yml
vendored
79
.github/workflows/ci.yml
vendored
|
|
@ -1,79 +0,0 @@
|
|||
name: CI
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: ["main"]
|
||||
pull_request:
|
||||
branches: ["main"]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
env:
|
||||
MIX_ENV: test
|
||||
|
||||
jobs:
|
||||
ci:
|
||||
name: Run CI on OTP ${{matrix.otp}} / Elixir ${{matrix.elixir}}
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
otp: ["28.1"]
|
||||
elixir: ["1.19.2"]
|
||||
|
||||
steps:
|
||||
- name: Set up Elixir
|
||||
uses: erlef/setup-beam@v1
|
||||
with:
|
||||
elixir-version: ${{matrix.elixir}}
|
||||
otp-version: ${{matrix.otp}}
|
||||
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v5
|
||||
|
||||
# Step: Define how to cache deps. Restores existing cache if present.
|
||||
- name: Cache deps
|
||||
id: cache-deps
|
||||
uses: actions/cache@v5
|
||||
env:
|
||||
cache-name: cache-deps
|
||||
with:
|
||||
path: deps
|
||||
key: ${{ runner.os }}-${{matrix.otp}}-${{matrix.elixir}}-${{ env.cache-name }}-${{ hashFiles('./**/mix.lock') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-${{matrix.otp}}-${{matrix.elixir}}-${{ env.cache-name }}-
|
||||
|
||||
# Step: Define how to cache the `_build` directory. After the first run,
|
||||
# this speeds up tests runs a lot. This includes not re-compiling our
|
||||
# project's downloaded deps every run.
|
||||
- name: Cache compiled build
|
||||
id: cache-build
|
||||
uses: actions/cache@v5
|
||||
env:
|
||||
cache-name: cache-compiled-build
|
||||
with:
|
||||
path: _build
|
||||
key: ${{ runner.os }}-${{matrix.otp}}-${{matrix.elixir}}-${{ env.cache-name }}-${{ hashFiles('./**/mix.lock') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-${{matrix.otp}}-${{matrix.elixir}}-${{ env.cache-name }}
|
||||
${{ runner.os }}-${{matrix.otp}}-${{matrix.elixir}}-
|
||||
|
||||
- name: Install dependencies
|
||||
run: mix deps.get
|
||||
|
||||
# Step: Compile the project treating any warnings as errors.
|
||||
- name: Compiles without warnings
|
||||
run: mix compile --warnings-as-errors
|
||||
|
||||
# Step: Check that the checked in code has already been formatted.
|
||||
# This step fails if something was found unformatted.
|
||||
- name: Check Formatting
|
||||
run: mix format --check-formatted
|
||||
|
||||
# Step: Execute Credo
|
||||
- name: Run Credo
|
||||
run: mix credo
|
||||
|
||||
# Step: Execute the tests.
|
||||
- name: Run tests
|
||||
run: mix test
|
||||
17
.woodpecker/ci.yml
Normal file
17
.woodpecker/ci.yml
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
when:
|
||||
- event: [push, pull_request]
|
||||
branch: main
|
||||
|
||||
steps:
|
||||
ci:
|
||||
image: elixir:1.19.2-otp-28
|
||||
environment:
|
||||
MIX_ENV: test
|
||||
commands:
|
||||
- mix local.rebar --force
|
||||
- mix local.hex --force
|
||||
- mix deps.get
|
||||
- mix compile --warnings-as-errors
|
||||
- mix format --check-formatted
|
||||
- mix credo
|
||||
- mix test
|
||||
Loading…
Reference in a new issue