Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Keep nightly notify policy in workflows

Manav Rathie037979c095e
diff --git a/.github/scripts/release-notes.mjs b/.github/scripts/release-notes.mjs
index 568ccbf012..cc3474185d 100644
--- a/.github/scripts/release-notes.mjs
+++ b/.github/scripts/release-notes.mjs
@@ -51,28 +51,17 @@ function previousBody() {
function releaseNotes(body, previous) {
const previousLines = new Set(previous.split("\n").filter(Boolean));
- if (!previousLines.size) {
- return { groupedBody: body, hasNewChanges: Boolean(body) };
- }
-
const latest = [];
const previousAgain = [];
for (const line of body.split("\n").filter(Boolean)) {
(previousLines.has(line) ? previousAgain : latest).push(line);
}
- if (!previousAgain.length) {
- return { groupedBody: body, hasNewChanges: Boolean(body) };
- }
- return {
- groupedBody: [
- latest.length ? latest.join("\n") : "",
- `Previous changes:\n${previousAgain.join("\n")}`,
- ]
- .filter(Boolean)
- .join("\n\n"),
- hasNewChanges: latest.length > 0,
- };
+ const groupedBody =
+ previousAgain.length
+ ? [latest.join("\n"), `Previous changes:\n${previousAgain.join("\n")}`].filter(Boolean).join("\n\n")
+ : body;
+ return { groupedBody, hasNewChanges: latest.length > 0 };
}
function playStoreBody(body) {
diff --git a/.github/workflows/auth-build.yml b/.github/workflows/auth-build.yml
index 4785c111e8..650b2b2219 100644
--- a/.github/workflows/auth-build.yml
+++ b/.github/workflows/auth-build.yml
@@ -769,7 +769,7 @@ jobs:
run: gh release upload "${RELEASE_TAG}" SHA256SUMS --clobber
- name: Notify Discord
- if: startsWith(github.ref_name, 'release/') || needs.build-metadata.outputs.has_new_changes == 'true'
+ if: github.event_name != 'schedule' || needs.build-metadata.outputs.has_new_changes == 'true'
continue-on-error: true
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_INTERNAL_RELEASE_WEBHOOK }}
diff --git a/.github/workflows/ensu-build.yml b/.github/workflows/ensu-build.yml
index 3fe011029d..8ad6c765f8 100644
--- a/.github/workflows/ensu-build.yml
+++ b/.github/workflows/ensu-build.yml
@@ -464,7 +464,7 @@ jobs:
git push --force origin "refs/tags/${RELEASE_TAG}"
- name: Notify Discord
- if: startsWith(github.ref_name, 'release/') || needs.build-metadata.outputs.has_new_changes == 'true'
+ if: github.event_name != 'schedule' || needs.build-metadata.outputs.has_new_changes == 'true'
continue-on-error: true
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_INTERNAL_RELEASE_WEBHOOK }}
diff --git a/.github/workflows/locker-build.yml b/.github/workflows/locker-build.yml
index 6971174e23..52e30d1c99 100644
--- a/.github/workflows/locker-build.yml
+++ b/.github/workflows/locker-build.yml
@@ -361,7 +361,7 @@ jobs:
run: gh release upload "${RELEASE_TAG}" SHA256SUMS --clobber
- name: Notify Discord
- if: startsWith(github.ref_name, 'release/') || needs.build-metadata.outputs.has_new_changes == 'true'
+ if: github.event_name != 'schedule' || needs.build-metadata.outputs.has_new_changes == 'true'
continue-on-error: true
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_INTERNAL_RELEASE_WEBHOOK }}
diff --git a/.github/workflows/photos-build.yml b/.github/workflows/photos-build.yml
index b38616c619..185521b721 100644
--- a/.github/workflows/photos-build.yml
+++ b/.github/workflows/photos-build.yml
@@ -359,7 +359,7 @@ jobs:
run: gh release upload "${RELEASE_TAG}" SHA256SUMS --clobber
- name: Notify Discord
- if: startsWith(github.ref_name, 'release/') || needs.build-metadata.outputs.has_new_changes == 'true'
+ if: github.event_name != 'schedule' || needs.build-metadata.outputs.has_new_changes == 'true'
continue-on-error: true
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_INTERNAL_RELEASE_WEBHOOK }}
diff --git a/.github/workflows/photos-desktop-build.yml b/.github/workflows/photos-desktop-build.yml
index e4f44325f0..92c30f3d42 100644
--- a/.github/workflows/photos-desktop-build.yml
+++ b/.github/workflows/photos-desktop-build.yml
@@ -216,7 +216,7 @@ jobs:
git push --force origin "refs/tags/${RELEASE_TAG}"
- name: Notify Discord
- if: startsWith(github.ref_name, 'release/') || needs.build-metadata.outputs.has_new_changes == 'true'
+ if: github.event_name != 'schedule' || needs.build-metadata.outputs.has_new_changes == 'true'
continue-on-error: true
env:
DISCORD_WEBHOOK: ${{ secrets.DISCORD_INTERNAL_RELEASE_WEBHOOK }}