Skip to content

update objetivo-6.md #507

update objetivo-6.md

update objetivo-6.md #507

Workflow file for this run

name: Se han hecho las tareas previas al PR
on:
pull_request:
types: [opened,edited]
jobs:
get-checks:
runs-on: ubuntu-latest
steps:
- name: Comprobaciones sobre el cuerpo del PR
uses: actions/github-script@v5
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
const checklist = /\s*[-\*]\s+\[\s*([xX]?)\s*\]\s+([A-Z]*):?/gm
const body = context.payload.pull_request.body
let match = checklist.exec(body)
let warned = false
while (match != null) {
let value = match[1] ? true : false
if ( value === false ) {
core.setFailed("⚠️ No has marcado " + match[2] + " ⚠")
if ( !warned ) {
core.warning("👉 Es importante que sigáis la lista de comprobación en cada entrega" )
warned = true
}
}
match = checklist.exec(body)
}