mirror of
https://github.com/daveallie/crosspoint-reader.git
synced 2026-02-05 07:07:38 +03:00
remove pr writer
This commit is contained in:
parent
88f8307cb1
commit
7b7337a366
38
.github/labeler.yml
vendored
38
.github/labeler.yml
vendored
@ -1,38 +0,0 @@
|
|||||||
firmware:
|
|
||||||
- changed-files:
|
|
||||||
- any-glob-to-any-file:
|
|
||||||
- src/**
|
|
||||||
- lib/**
|
|
||||||
- open-x4-sdk/**
|
|
||||||
|
|
||||||
ui:
|
|
||||||
- changed-files:
|
|
||||||
- any-glob-to-any-file:
|
|
||||||
- src/activities/**
|
|
||||||
- src/network/html/**
|
|
||||||
- docs/images/**
|
|
||||||
|
|
||||||
epub:
|
|
||||||
- changed-files:
|
|
||||||
- any-glob-to-any-file:
|
|
||||||
- lib/Epub/**
|
|
||||||
|
|
||||||
network:
|
|
||||||
- changed-files:
|
|
||||||
- any-glob-to-any-file:
|
|
||||||
- src/network/**
|
|
||||||
- src/util/UrlUtils.*
|
|
||||||
- lib/OpdsParser/**
|
|
||||||
|
|
||||||
docs:
|
|
||||||
- changed-files:
|
|
||||||
- any-glob-to-any-file:
|
|
||||||
- docs/**
|
|
||||||
- README*
|
|
||||||
- CHANGELOG*
|
|
||||||
|
|
||||||
tests:
|
|
||||||
- changed-files:
|
|
||||||
- any-glob-to-any-file:
|
|
||||||
- test/**
|
|
||||||
- scripts/**
|
|
||||||
16
.github/workflows/ci.yml
vendored
16
.github/workflows/ci.yml
vendored
@ -65,10 +65,7 @@ jobs:
|
|||||||
run: pip install --upgrade platformio
|
run: pip install --upgrade platformio
|
||||||
|
|
||||||
- name: Build CrossPoint
|
- name: Build CrossPoint
|
||||||
run: |
|
run: pio run
|
||||||
set -euo pipefail
|
|
||||||
pio run | tee pio.log
|
|
||||||
|
|
||||||
|
|
||||||
- name: Extract firmware stats
|
- name: Extract firmware stats
|
||||||
|
|
||||||
@ -84,18 +81,9 @@ jobs:
|
|||||||
if [ -n "$flash_line" ]; then echo "- ${flash_line}"; else echo "- Flash: not found"; fi
|
if [ -n "$flash_line" ]; then echo "- ${flash_line}"; else echo "- Flash: not found"; fi
|
||||||
} >> "$GITHUB_STEP_SUMMARY"
|
} >> "$GITHUB_STEP_SUMMARY"
|
||||||
|
|
||||||
# Upload both the binary and the stats/log so Stage 2 can read them without checkout.
|
|
||||||
- name: Upload firmware.bin artifact
|
- name: Upload firmware.bin artifact
|
||||||
uses: actions/upload-artifact@v6
|
uses: actions/upload-artifact@v6
|
||||||
with:
|
with:
|
||||||
name: firmware-bin
|
name: firmware.bin
|
||||||
path: .pio/build/default/firmware.bin
|
path: .pio/build/default/firmware.bin
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
|
|
||||||
- name: Upload build metadata artifact
|
|
||||||
uses: actions/upload-artifact@v6
|
|
||||||
with:
|
|
||||||
name: build-meta
|
|
||||||
path: |
|
|
||||||
pio.log
|
|
||||||
if-no-files-found: error
|
|
||||||
73
.github/workflows/pr-formatting-check.yml
vendored
73
.github/workflows/pr-formatting-check.yml
vendored
@ -6,13 +6,9 @@ on:
|
|||||||
- opened
|
- opened
|
||||||
- reopened
|
- reopened
|
||||||
- edited
|
- edited
|
||||||
- synchronize
|
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: read
|
|
||||||
statuses: write
|
statuses: write
|
||||||
pull-requests: write
|
|
||||||
issues: write
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
title-check:
|
title-check:
|
||||||
@ -25,73 +21,6 @@ jobs:
|
|||||||
egress-policy: audit
|
egress-policy: audit
|
||||||
|
|
||||||
- name: Check PR Title
|
- name: Check PR Title
|
||||||
id: title_check
|
|
||||||
uses: amannn/action-semantic-pull-request@v6
|
uses: amannn/action-semantic-pull-request@v6
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ github.token }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Comment with changelog hint on failure
|
|
||||||
if: failure()
|
|
||||||
uses: actions/github-script@v8
|
|
||||||
with:
|
|
||||||
script: |
|
|
||||||
const marker = '<!-- pr-title-check -->';
|
|
||||||
const error = `${{ steps.title_check.outputs.error_message || steps.title_check.outputs.error || '' }}`.trim();
|
|
||||||
const details = error ? `\n\n**Error:** ${error}` : '\n\n**Error:** See workflow logs.';
|
|
||||||
const body =
|
|
||||||
`${marker}\n**PR title check failed**\n\n` +
|
|
||||||
`Please use a Conventional Commit-style prefix (e.g., \`feat:\`, \`fix:\`, \`docs:\`, \`chore:\`).\n` +
|
|
||||||
`If this change should appear in release notes, ensure the title reflects the correct category.${details}`;
|
|
||||||
|
|
||||||
const { data: comments } = await github.rest.issues.listComments({
|
|
||||||
owner: context.repo.owner,
|
|
||||||
repo: context.repo.repo,
|
|
||||||
issue_number: context.issue.number,
|
|
||||||
per_page: 100,
|
|
||||||
});
|
|
||||||
|
|
||||||
const existing = comments.find((comment) => (comment.body || "").includes(marker));
|
|
||||||
|
|
||||||
if (existing) {
|
|
||||||
await github.rest.issues.updateComment({
|
|
||||||
owner: context.repo.owner,
|
|
||||||
repo: context.repo.repo,
|
|
||||||
comment_id: existing.id,
|
|
||||||
body,
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
await github.rest.issues.createComment({
|
|
||||||
owner: context.repo.owner,
|
|
||||||
repo: context.repo.repo,
|
|
||||||
issue_number: context.issue.number,
|
|
||||||
body,
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
- name: Remove failure comment on success
|
|
||||||
if: success()
|
|
||||||
uses: actions/github-script@v8
|
|
||||||
with:
|
|
||||||
script: |
|
|
||||||
const marker = '<!-- pr-title-check -->';
|
|
||||||
|
|
||||||
const { data: comments } = await github.rest.issues.listComments({
|
|
||||||
owner: context.repo.owner,
|
|
||||||
repo: context.repo.repo,
|
|
||||||
issue_number: context.issue.number,
|
|
||||||
per_page: 100,
|
|
||||||
});
|
|
||||||
|
|
||||||
const existing = comments.find((comment) => (comment.body || "").includes(marker));
|
|
||||||
if (!existing) {
|
|
||||||
core.info("No previous PR title failure comment found.");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
await github.rest.issues.deleteComment({
|
|
||||||
owner: context.repo.owner,
|
|
||||||
repo: context.repo.repo,
|
|
||||||
comment_id: existing.id,
|
|
||||||
});
|
|
||||||
|
|
||||||
core.info(`Deleted previous failure comment id=${existing.id}`);
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user