Add Github CI templated and workflow.
This commit is contained in:
35
.github/workflows/bump-date.yml
vendored
Executable file
35
.github/workflows/bump-date.yml
vendored
Executable file
@@ -0,0 +1,35 @@
|
||||
#
|
||||
# bump-date.yml
|
||||
# Bump the distribution date once per day
|
||||
#
|
||||
|
||||
name: Bump Distribution Date
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 0 * * *'
|
||||
|
||||
jobs:
|
||||
bump_date:
|
||||
name: Bump Distribution Date
|
||||
if: github.repository == 'MarlinFirmware/Marlin'
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
|
||||
- name: Check out bugfix-2.0.x
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
ref: bugfix-2.0.x
|
||||
|
||||
- name: Bump Distribution Date
|
||||
run: |
|
||||
# Inline Bump Script
|
||||
DIST=$( date +"%Y-%m-%d" )
|
||||
eval "sed -E -i 's/(#define +STRING_DISTRIBUTION_DATE) .*$/\1 \"$DIST\"/g' Marlin/src/inc/Version.h" && \
|
||||
git config user.name "${GITHUB_ACTOR}" && \
|
||||
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" && \
|
||||
git add . && \
|
||||
git commit -m "[cron] Bump distribution date ($DIST)" && \
|
||||
git push
|
31
.github/workflows/check-pr.yml
vendored
Executable file
31
.github/workflows/check-pr.yml
vendored
Executable file
@@ -0,0 +1,31 @@
|
||||
#
|
||||
# check-pr.yml
|
||||
# Close PRs directed at release branches
|
||||
#
|
||||
|
||||
name: PR Bad Target
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- 2.0.x
|
||||
|
||||
jobs:
|
||||
bad_target:
|
||||
name: PR Bad Target
|
||||
if: github.repository == 'knutwurst/Marlin-2-0-x-Anycubic-i3-MEGA-S'
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: peter-evans/close-pull@v1
|
||||
with:
|
||||
delete-branch: false
|
||||
comment: >
|
||||
Thanks for your contribution! Unfortunately we can't accept PRs directed at release branches. We make patches to the bugfix branches and only later do we push them out as releases.
|
||||
|
||||
Please redo this PR starting with the `bugfix-2.0.x` branch and be careful to target `bugfix-2.0.x` when resubmitting the PR.
|
||||
|
||||
It may help to set your fork's default branch to `bugfix-2.0.x`.
|
||||
|
||||
See [this page](http://marlinfw.org/docs/development/getting_started_pull_requests.html) for full instructions.
|
27
.github/workflows/close-stale.yml
vendored
Executable file
27
.github/workflows/close-stale.yml
vendored
Executable file
@@ -0,0 +1,27 @@
|
||||
#
|
||||
# close-stale.yml
|
||||
# Close open issues after a period of inactivity
|
||||
#
|
||||
|
||||
name: Close Stale Issues
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: "22 1 * * *"
|
||||
|
||||
jobs:
|
||||
stale:
|
||||
name: Close Stale Issues
|
||||
if: github.repository == 'MarlinFirmware/Marlin'
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/stale@v3
|
||||
with:
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
stale-issue-message: 'This issue is stale because it has been open 30 days with no activity. Remove stale label / comment or this will be closed in 5 days.'
|
||||
days-before-stale: 30
|
||||
days-before-close: 5
|
||||
stale-issue-label: 'stale-closing-soon'
|
||||
exempt-issue-labels: 'T: Feature Request'
|
32
.github/workflows/lock-closed.yml
vendored
Executable file
32
.github/workflows/lock-closed.yml
vendored
Executable file
@@ -0,0 +1,32 @@
|
||||
#
|
||||
# lock-closed.yml
|
||||
# Lock closed issues after a period of inactivity
|
||||
#
|
||||
|
||||
name: Lock Closed Issues
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 1/13 * * *'
|
||||
|
||||
jobs:
|
||||
lock:
|
||||
name: Lock Closed Issues
|
||||
if: github.repository == 'MarlinFirmware/Marlin'
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: dessant/lock-threads@v2
|
||||
with:
|
||||
github-token: ${{ github.token }}
|
||||
process-only: 'issues'
|
||||
issue-lock-inactive-days: '60'
|
||||
issue-exclude-created-before: ''
|
||||
issue-exclude-labels: 'no-locking'
|
||||
issue-lock-labels: ''
|
||||
issue-lock-comment: >
|
||||
This issue has been automatically locked since there
|
||||
has not been any recent activity after it was closed.
|
||||
Please open a new issue for related bugs.
|
||||
issue-lock-reason: ''
|
158
.github/workflows/test-builds.yml
vendored
Executable file
158
.github/workflows/test-builds.yml
vendored
Executable file
@@ -0,0 +1,158 @@
|
||||
#
|
||||
# test-builds.yml
|
||||
# Do test builds to catch compile errors
|
||||
#
|
||||
|
||||
name: CI
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches:
|
||||
- master
|
||||
paths-ignore:
|
||||
- config/**
|
||||
- data/**
|
||||
- docs/**
|
||||
- '**/*.md'
|
||||
push:
|
||||
branches:
|
||||
- master
|
||||
paths-ignore:
|
||||
- config/**
|
||||
- data/**
|
||||
- docs/**
|
||||
- '**/*.md'
|
||||
|
||||
jobs:
|
||||
test_builds:
|
||||
name: Run All Tests
|
||||
if: github.repository == 'knutwurst/Marlin-2-0-x-Anycubic-i3-MEGA-S'
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
test-platform:
|
||||
# Knutwurst Base Environments
|
||||
|
||||
- i3_MEGA_1stgen
|
||||
- i3_MEGA_1stgen_TMC
|
||||
- i3_MEGA_1stgen_BLTOUCH_10
|
||||
- i3_MEGA_1stgen_BLTOUCH_11
|
||||
- i3_MEGA_1stgen_TMC_BLTOUCH_10
|
||||
- i3_MEGA_1stgen_TMC_BLTOUCH_11
|
||||
- i3_MEGA
|
||||
- i3_MEGA_TMC
|
||||
- i3_MEGA_BLTOUCH_10
|
||||
- i3_MEGA_BLTOUCH_11
|
||||
- i3_MEGA_TMC_BLTOUCH_10
|
||||
- i3_MEGA_TMC_BLTOUCH_11
|
||||
- i3_MEGA_S
|
||||
- i3_MEGA_S_TMC
|
||||
- i3_MEGA_S_BLTOUCH_10
|
||||
- i3_MEGA_S_BLTOUCH_11
|
||||
- i3_MEGA_S_TMC_BLTOUCH_10
|
||||
- i3_MEGA_S_TMC_BLTOUCH_11
|
||||
- i3_MEGA_S_DGUS
|
||||
- i3_MEGA_S_DGUS_TMC
|
||||
- i3_MEGA_S_DGUS_BLTOUCH_10
|
||||
- i3_MEGA_S_DGUS_BLTOUCH_11
|
||||
- i3_MEGA_S_DGUS_TMC_BLTOUCH_10
|
||||
- i3_MEGA_S_DGUS_TMC_BLTOUCH_11
|
||||
- i3_MEGA_X
|
||||
- i3_MEGA_X_TMC
|
||||
- i3_MEGA_X_BLTOUCH_10
|
||||
- i3_MEGA_X_BLTOUCH_11
|
||||
- i3_MEGA_X_TMC_BLTOUCH_10
|
||||
- i3_MEGA_X_TMC_BLTOUCH_11
|
||||
- i3_MEGA_P
|
||||
- i3_MEGA_P_TMC
|
||||
- i3_MEGA_P_BLTOUCH_10
|
||||
- i3_MEGA_P_BLTOUCH_11
|
||||
- i3_MEGA_P_TMC_BLTOUCH_10
|
||||
- i3_MEGA_P_TMC_BLTOUCH_11
|
||||
|
||||
#- DUE
|
||||
#- esp32
|
||||
#- linux_native
|
||||
#- mega2560
|
||||
#- teensy31
|
||||
#- teensy35
|
||||
#- SAMD51_grandcentral_m4
|
||||
|
||||
# Extended AVR Environments
|
||||
|
||||
#- FYSETC_F6_13
|
||||
#- mega1280
|
||||
#- rambo
|
||||
#- sanguino1284p
|
||||
#- sanguino644p
|
||||
|
||||
# Extended STM32 Environments
|
||||
|
||||
#- STM32F103RC_btt
|
||||
#- STM32F103RC_btt_USB
|
||||
#- STM32F103RE_btt
|
||||
#- STM32F103RE_btt_USB
|
||||
#- STM32F103RC_fysetc
|
||||
#- STM32F103RC_meeb
|
||||
#- jgaurora_a5s_a1
|
||||
#- STM32F103VE_longer
|
||||
#- STM32F407VE_black
|
||||
#- STM32F401VE_STEVAL
|
||||
#- BIGTREE_BTT002
|
||||
#- BIGTREE_SKR_PRO
|
||||
#- BIGTREE_GTR_V1_0
|
||||
#- mks_robin
|
||||
#- mks_robin_stm32
|
||||
#- ARMED
|
||||
#- FYSETC_S6
|
||||
#- STM32F070RB_malyan
|
||||
#- malyan_M300
|
||||
#- mks_robin_lite
|
||||
#- FLYF407ZG
|
||||
#- rumba32
|
||||
#- mks_robin_pro
|
||||
#- STM32F103RET6_creality
|
||||
#- LERDGEX
|
||||
#- mks_robin_nano35
|
||||
|
||||
# Put lengthy tests last
|
||||
|
||||
#- LPC1768
|
||||
#- LPC1769
|
||||
|
||||
# STM32 with non-STM framework. both broken for now. they should use HAL_STM32 which is working.
|
||||
|
||||
#- STM32F4
|
||||
#- STM32F7
|
||||
|
||||
# Non-working environment tests
|
||||
#- at90usb1286_cdc
|
||||
#- at90usb1286_dfu
|
||||
#- STM32F103CB_malyan
|
||||
#- mks_robin_mini
|
||||
|
||||
steps:
|
||||
|
||||
- name: Select Python 3.7
|
||||
uses: actions/setup-python@v1
|
||||
with:
|
||||
python-version: '3.7' # Version range or exact version of a Python version to use, using semvers version range syntax.
|
||||
architecture: 'x64' # optional x64 or x86. Defaults to x64 if not specified
|
||||
|
||||
- name: Install PlatformIO
|
||||
run: |
|
||||
pip install -U https://github.com/platformio/platformio-core/archive/develop.zip
|
||||
platformio update
|
||||
|
||||
- name: Check out the PR
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Run ${{ matrix.test-platform }} Tests
|
||||
run: |
|
||||
# Inline tests script
|
||||
chmod +x buildroot/bin/*
|
||||
chmod +x buildroot/tests/*
|
||||
export PATH=./buildroot/bin/:./buildroot/tests/:${PATH}
|
||||
run_tests . ${{ matrix.test-platform }}
|
22
.github/workflows/unlock-reopened.yml
vendored
Executable file
22
.github/workflows/unlock-reopened.yml
vendored
Executable file
@@ -0,0 +1,22 @@
|
||||
#
|
||||
# unlock-reopened.yml
|
||||
# Unlock an issue whenever it is re-opened
|
||||
#
|
||||
|
||||
name: "Unlock reopened issue"
|
||||
|
||||
on:
|
||||
issues:
|
||||
types: [reopened]
|
||||
|
||||
jobs:
|
||||
unlock:
|
||||
name: Unlock Reopened
|
||||
if: github.repository == 'MarlinFirmware/Marlin'
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: OSDKDev/unlock-issues@v1.1
|
||||
with:
|
||||
repo-token: "${{ secrets.GITHUB_TOKEN }}"
|
Reference in New Issue
Block a user