From 183af0fdfb3f855841ea7946e092313804e452e9 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 13:11:37 +0200 Subject: [PATCH 01/27] chore: correct flutter tag for snap, test snap in CI, release 1.5.3 --- .github/workflows/ci.yaml | 1 + lib/patch_notes/patch_notes.dart | 16 +++++++++++++--- pubspec.yaml | 2 +- snap/snapcraft.yaml | 2 +- 4 files changed, 16 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 19a30d629..d241afb02 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -52,3 +52,4 @@ jobs: - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - run: flutter build linux -v + - uses: snapcore/action-build@v1 \ No newline at end of file diff --git a/lib/patch_notes/patch_notes.dart b/lib/patch_notes/patch_notes.dart index b4141df14..6d25249d9 100644 --- a/lib/patch_notes/patch_notes.dart +++ b/lib/patch_notes/patch_notes.dart @@ -238,8 +238,18 @@ const kPatchNotes20240728 = 'Hello MusicPod Users, this big update includes\n' '\n* a lot of bugfixes' '\n'; -const kRecentPatchNotesDisposed = kPatchNotes20240728disposed; -const kRecentPatchNotesTitle = kPatchNotesTitle20240728; -const kRecentPatchNotes = kPatchNotes20240728; +// 2024 08 15 +const kPatchNotes20240815disposed = 'patchNotes20240815disposed'; +const kPatchNotesTitle20240815 = 'Patch notes: 2024-08-15'; +const kPatchNotes20240815 = 'Hello MusicPod Users, this update includes\n' + '\n* search improvements' + '\n* new podcast options: reorder, sleep timer and reset progress' + '\n* a lot under the hood changes' + '\n* bugfixes' + '\n'; + +const kRecentPatchNotesDisposed = kPatchNotes20240815disposed; +const kRecentPatchNotesTitle = kPatchNotesTitle20240815; +const kRecentPatchNotes = kPatchNotes20240815; const kPatchNotesDisposed = 'kPatchNotesDisposed'; diff --git a/pubspec.yaml b/pubspec.yaml index 72464bc6a..22eee5349 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.2 +version: 1.5.3 publish_to: "none" diff --git a/snap/snapcraft.yaml b/snap/snapcraft.yaml index b4fd35aa7..83f0001f2 100644 --- a/snap/snapcraft.yaml +++ b/snap/snapcraft.yaml @@ -61,7 +61,7 @@ parts: flutter-git: source: https://github.com/flutter/flutter.git - source-tag: 3.19.5 + source-tag: 3.24.0 source-depth: 1 plugin: nil override-build: | From 469d0e8aeed6cf6e45a5f6b7fb268228be00493f Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 13:35:09 +0200 Subject: [PATCH 02/27] chore: test trigger in pubspec --- .github/workflows/ci.yaml | 3 +-- .github/workflows/snap.yaml | 33 +++++++++++++++++++++++++-------- pubspec.yaml | 2 +- 3 files changed, 27 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index d241afb02..8494d6f43 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -51,5 +51,4 @@ jobs: - run: sudo apt update - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - - run: flutter build linux -v - - uses: snapcore/action-build@v1 \ No newline at end of file + - run: flutter build linux -v \ No newline at end of file diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index b87715123..8db69ce72 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -4,12 +4,28 @@ on: push: branches: - snap - + pull_request: + branches: [main] env: FLUTTER_VERSION: '3.24.x' jobs: + check_file: + runs-on: ubuntu-latest + outputs: + has_changed: ${{ steps.check.outputs.changed }} + steps: + - uses: actions/checkout@v3 + - name: Check file + id: check + run: | + changed=$(git diff --unified=0 HEAD^ HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) + if [[ "$changed" == "3" ]]; then + echo "changed=true" >> $GITHUB_OUTPUT + else + echo "changed=false" >> $GITHUB_OUTPUT + fi build_and_publish: runs-on: ubuntu-latest steps: @@ -22,11 +38,12 @@ jobs: - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - uses: snapcore/action-build@v1 + if: ${{ needs.check_file.outputs.has_changed == 'changed' }} id: build - - uses: snapcore/action-publish@v1 - if: steps.build.outcome == 'success' - env: - SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} - with: - snap: ${{ steps.build.outputs.snap }} - release: edge + # - uses: snapcore/action-publish@v1 + # if: steps.build.outcome == 'success' + # env: + # SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} + # with: + # snap: ${{ steps.build.outputs.snap }} + # release: edge diff --git a/pubspec.yaml b/pubspec.yaml index 22eee5349..a5c5b7296 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.3 +version: 1.5.4 publish_to: "none" From 5d0a11ec072e3cf44cc987c8ac31d0620e317234 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 13:41:05 +0200 Subject: [PATCH 03/27] fix: correct git --- .github/workflows/snap.yaml | 2 +- pubspec.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 8db69ce72..ca709929a 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -20,7 +20,7 @@ jobs: - name: Check file id: check run: | - changed=$(git diff --unified=0 HEAD^ HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 pubspec.yaml | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "3" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else diff --git a/pubspec.yaml b/pubspec.yaml index a5c5b7296..22eee5349 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.4 +version: 1.5.3 publish_to: "none" From 092306c3af02b3a5f387955eeddd17213ec7304c Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 13:53:28 +0200 Subject: [PATCH 04/27] fix: git --- .github/workflows/snap.yaml | 2 +- pubspec.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index ca709929a..f7c0c31b6 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -21,7 +21,7 @@ jobs: id: check run: | changed=$(git diff --unified=0 pubspec.yaml | grep -n '^@@' | cut -d':' -f1) - if [[ "$changed" == "3" ]]; then + if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else echo "changed=false" >> $GITHUB_OUTPUT diff --git a/pubspec.yaml b/pubspec.yaml index 22eee5349..a5c5b7296 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.3 +version: 1.5.4 publish_to: "none" From 230e2e902df91b6a227f7fed08bcd0a4d8b38850 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 13:59:59 +0200 Subject: [PATCH 05/27] fix: git --- .github/workflows/snap.yaml | 3 ++- pubspec.yaml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index f7c0c31b6..17e36b851 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -26,6 +26,7 @@ jobs: else echo "changed=false" >> $GITHUB_OUTPUT fi + echo $changed build_and_publish: runs-on: ubuntu-latest steps: @@ -38,7 +39,7 @@ jobs: - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - uses: snapcore/action-build@v1 - if: ${{ needs.check_file.outputs.has_changed == 'changed' }} + if: ${{ needs.check_file.outputs.changed == 5 }} id: build # - uses: snapcore/action-publish@v1 # if: steps.build.outcome == 'success' diff --git a/pubspec.yaml b/pubspec.yaml index a5c5b7296..b12c32425 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.4 +version: 1.5.5 publish_to: "none" From b94ef137ab4911e7a0064911afbc402c2fff53f5 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:04:15 +0200 Subject: [PATCH 06/27] fix: git --- .github/workflows/snap.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 17e36b851..6929cbd98 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -20,7 +20,7 @@ jobs: - name: Check file id: check run: | - changed=$(git diff --unified=0 pubspec.yaml | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base main HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else From a0f412481a854eaef007788706b732336cb903c8 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:08:15 +0200 Subject: [PATCH 07/27] fix: git --- .github/workflows/snap.yaml | 2 +- pubspec.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 6929cbd98..e4c07f28b 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -20,7 +20,7 @@ jobs: - name: Check file id: check run: | - changed=$(git diff --unified=0 --merge-base main HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 main... pubspec.yaml | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else diff --git a/pubspec.yaml b/pubspec.yaml index b12c32425..a5c5b7296 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.5 +version: 1.5.4 publish_to: "none" From 38adffcec9e4db1d802a1a0f80052a3cf178af40 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:16:41 +0200 Subject: [PATCH 08/27] fix: git --- .github/workflows/snap.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index e4c07f28b..8c3b7c636 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -20,7 +20,7 @@ jobs: - name: Check file id: check run: | - changed=$(git diff --unified=0 main... pubspec.yaml | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 HEAD^...HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else From 7798e57896ffdce2ef76b8b9683b71d0a7d7b3b7 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:20:21 +0200 Subject: [PATCH 09/27] fix: git --- .github/workflows/snap.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 8c3b7c636..c29f2d119 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -20,7 +20,7 @@ jobs: - name: Check file id: check run: | - changed=$(git diff --unified=0 HEAD^...HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 HEAD~1...HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else From e4655077aab34f3f5a0e7f10cfefabbd6b211b67 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:24:21 +0200 Subject: [PATCH 10/27] fix: git --- .github/workflows/snap.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index c29f2d119..9e8809046 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -20,7 +20,7 @@ jobs: - name: Check file id: check run: | - changed=$(git diff --unified=0 HEAD~1...HEAD pubspec.yaml | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 main...HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else From f6616700c661a5a3d53aa4c70133783894d466dd Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:29:06 +0200 Subject: [PATCH 11/27] fix: git command --- .github/workflows/snap.yaml | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 9e8809046..e48591cca 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -11,25 +11,20 @@ env: FLUTTER_VERSION: '3.24.x' jobs: - check_file: + build_and_publish: runs-on: ubuntu-latest - outputs: - has_changed: ${{ steps.check.outputs.changed }} steps: - uses: actions/checkout@v3 - - name: Check file + - name: Check version in pubspec.yaml id: check run: | - changed=$(git diff --unified=0 main...HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 main... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else echo "changed=false" >> $GITHUB_OUTPUT fi echo $changed - build_and_publish: - runs-on: ubuntu-latest - steps: - uses: actions/checkout@v4 - uses: subosito/flutter-action@v2 with: @@ -39,7 +34,7 @@ jobs: - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - uses: snapcore/action-build@v1 - if: ${{ needs.check_file.outputs.changed == 5 }} + if: steps.check.outputs.changed == 5 id: build # - uses: snapcore/action-publish@v1 # if: steps.build.outcome == 'success' From 9491f60f538ed0bbc6c3d2e766b1e1ec597591bd Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:34:17 +0200 Subject: [PATCH 12/27] fix: actions --- .github/workflows/ci.yaml | 15 ++++++++++++++- .github/workflows/snap.yaml | 18 ++++++++---------- 2 files changed, 22 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8494d6f43..c89ee38ee 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -51,4 +51,17 @@ jobs: - run: sudo apt update - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - - run: flutter build linux -v \ No newline at end of file + - run: flutter build linux -v + - name: Check version in pubspec.yaml + id: check + run: | + changed=$(git diff --unified=0 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + if [[ "$changed" == "5" ]]; then + echo "changed=true" >> $GITHUB_OUTPUT + else + echo "changed=false" >> $GITHUB_OUTPUT + fi + echo "lines changed: $changed" + - uses: snapcore/action-build@v1 + if: steps.check.outputs.changed == 5 + id: build \ No newline at end of file diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index e48591cca..4f7c2528f 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -3,9 +3,7 @@ name: Publish Snap on: push: branches: - - snap - pull_request: - branches: [main] + - snap env: FLUTTER_VERSION: '3.24.x' @@ -36,10 +34,10 @@ jobs: - uses: snapcore/action-build@v1 if: steps.check.outputs.changed == 5 id: build - # - uses: snapcore/action-publish@v1 - # if: steps.build.outcome == 'success' - # env: - # SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} - # with: - # snap: ${{ steps.build.outputs.snap }} - # release: edge + - uses: snapcore/action-publish@v1 + if: steps.build.outcome == 'success' + env: + SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} + with: + snap: ${{ steps.build.outputs.snap }} + release: edge From d4e84de36486a6a85c123c101cac1c08831b4b91 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:40:29 +0200 Subject: [PATCH 13/27] fix: git --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index c89ee38ee..2655d47e6 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -55,7 +55,7 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - changed=$(git diff --unified=0 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base main HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else From 0d18baaff2cd496ac4b54571c34b564d98c6fe1a Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:45:14 +0200 Subject: [PATCH 14/27] test branches --- .github/workflows/snap.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 4f7c2528f..2ce9b3d82 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -16,6 +16,7 @@ jobs: - name: Check version in pubspec.yaml id: check run: | + git branch changed=$(git diff --unified=0 main... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT From 4d39d2d2f6492b17abd467bd6657711da8841043 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 14:55:38 +0200 Subject: [PATCH 15/27] test branches --- .github/workflows/snap.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 2ce9b3d82..888705a60 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -16,7 +16,7 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - git branch + echo $(git branch) changed=$(git diff --unified=0 main... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT From 827be1cb54fbd4f9bc60003d9a9c3f2e3f99f21f Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 15:04:36 +0200 Subject: [PATCH 16/27] fix --- .github/workflows/ci.yaml | 3 ++- .github/workflows/snap.yaml | 3 +-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 2655d47e6..7dd55d420 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -55,7 +55,8 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - changed=$(git diff --unified=0 --merge-base main HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + echo $(git branch) + changed=$(git diff --unified=0 --merge-base HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 888705a60..0652f5ab2 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -16,8 +16,7 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - echo $(git branch) - changed=$(git diff --unified=0 main... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else From 0d05cbe9fad405358d9f5fde44a8bb037cb72e09 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 15:12:09 +0200 Subject: [PATCH 17/27] echoeee --- .github/workflows/ci.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 7dd55d420..2f7a19aa2 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -55,7 +55,8 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - echo $(git branch) + echo "Head branch: ${GITHUB_HEAD_REF}" + echo "Base branch: ${GITHUB_BASE_REF}" changed=$(git diff --unified=0 --merge-base HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT From 65cfb6f25d8503869cc6e2d1779586e9926c1804 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 15:30:25 +0200 Subject: [PATCH 18/27] test github branch vars --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 2f7a19aa2..b5436a599 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,7 +57,7 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} ${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else From 312abc1f938a83565aa739f03f9fd6aeebc2e3aa Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 15:39:29 +0200 Subject: [PATCH 19/27] try --- .github/workflows/ci.yaml | 2 +- pubspec.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index b5436a599..6ed32d3f7 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,7 +57,7 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} ${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 ${GITHUB_BASE_REF}... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) if [[ "$changed" == "5" ]]; then echo "changed=true" >> $GITHUB_OUTPUT else diff --git a/pubspec.yaml b/pubspec.yaml index a5c5b7296..b12c32425 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.4 +version: 1.5.5 publish_to: "none" From 218e8cbf715144c075889595cfcc1833f1a51667 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 16:07:15 +0200 Subject: [PATCH 20/27] test mroe --- .github/workflows/ci.yaml | 10 +++------- .github/workflows/snap.yaml | 14 ++++++-------- 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 6ed32d3f7..c7dea1015 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,13 +57,9 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 ${GITHUB_BASE_REF}... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) - if [[ "$changed" == "5" ]]; then - echo "changed=true" >> $GITHUB_OUTPUT - else - echo "changed=false" >> $GITHUB_OUTPUT - fi + changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} ${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" - uses: snapcore/action-build@v1 - if: steps.check.outputs.changed == 5 + if: steps.check.outputs.changed == '5' id: build \ No newline at end of file diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 0652f5ab2..4ecfbb676 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -16,13 +16,11 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - changed=$(git diff --unified=0 --merge-base HEAD -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) - if [[ "$changed" == "5" ]]; then - echo "changed=true" >> $GITHUB_OUTPUT - else - echo "changed=false" >> $GITHUB_OUTPUT - fi - echo $changed + echo "Head branch: ${GITHUB_HEAD_REF}" + echo "Base branch: ${GITHUB_BASE_REF}" + changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} ${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + echo $changed >> $GITHUB_OUTPUT + echo "lines changed: $changed" - uses: actions/checkout@v4 - uses: subosito/flutter-action@v2 with: @@ -32,7 +30,7 @@ jobs: - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - uses: snapcore/action-build@v1 - if: steps.check.outputs.changed == 5 + if: steps.check.outputs.changed == '5' id: build - uses: snapcore/action-publish@v1 if: steps.build.outcome == 'success' From a3585196de5e4fec5a96ffc44f1d3e5d1f1e8e95 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 16:12:05 +0200 Subject: [PATCH 21/27] git is hard --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index c7dea1015..cca3e21f5 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,7 +57,7 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} ${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base ${GITHUB_HEAD_REF} ${GITHUB_BASE_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" - uses: snapcore/action-build@v1 From 64f32717d1908f2e52c3797617b49c640f77f397 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 16:17:51 +0200 Subject: [PATCH 22/27] git --- .github/workflows/ci.yaml | 2 +- .github/workflows/snap.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index cca3e21f5..4878b3722 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,7 +57,7 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base ${GITHUB_HEAD_REF} ${GITHUB_BASE_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" - uses: snapcore/action-build@v1 diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index 4ecfbb676..c581fba4d 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -18,7 +18,7 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} ${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" - uses: actions/checkout@v4 From b24aa06ce928e64ad87dedec0d1a910314a49899 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 16:25:22 +0200 Subject: [PATCH 23/27] gittt --- .github/workflows/ci.yaml | 2 +- .github/workflows/snap.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 4878b3722..c7ec186ca 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,7 +57,7 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base origin/${GITHUB_BASE_REF} origin/${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" - uses: snapcore/action-build@v1 diff --git a/.github/workflows/snap.yaml b/.github/workflows/snap.yaml index c581fba4d..89dbcfb3d 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/snap.yaml @@ -18,7 +18,7 @@ jobs: run: | echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base ${GITHUB_BASE_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 --merge-base HEAD HEAD^ -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" - uses: actions/checkout@v4 From d285663786cb7188c65901811496d6c9ef4cf74f Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 16:30:59 +0200 Subject: [PATCH 24/27] b --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index c7ec186ca..a101b4a72 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -55,9 +55,9 @@ jobs: - name: Check version in pubspec.yaml id: check run: | + changed=$(git diff --unified=0 main... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" - changed=$(git diff --unified=0 --merge-base origin/${GITHUB_BASE_REF} origin/${GITHUB_HEAD_REF} -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" - uses: snapcore/action-build@v1 From 319d9035f35676146159b416d33ae7deb5b5fd94 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 16:35:00 +0200 Subject: [PATCH 25/27] h --- .github/workflows/ci.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index a101b4a72..98f4fd9b7 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -55,7 +55,7 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - changed=$(git diff --unified=0 main... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) + changed=$(git diff --unified=0 HEAD... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo "Head branch: ${GITHUB_HEAD_REF}" echo "Base branch: ${GITHUB_BASE_REF}" echo $changed >> $GITHUB_OUTPUT From f204c358905c354e3ef9a2a3671705b4e0896742 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 16:59:46 +0200 Subject: [PATCH 26/27] move check to cd --- .github/workflows/{snap.yaml => cd.yaml} | 23 ++++++++++++----------- .github/workflows/ci.yaml | 13 +------------ 2 files changed, 13 insertions(+), 23 deletions(-) rename .github/workflows/{snap.yaml => cd.yaml} (73%) diff --git a/.github/workflows/snap.yaml b/.github/workflows/cd.yaml similarity index 73% rename from .github/workflows/snap.yaml rename to .github/workflows/cd.yaml index 89dbcfb3d..45a7141de 100644 --- a/.github/workflows/snap.yaml +++ b/.github/workflows/cd.yaml @@ -1,9 +1,9 @@ -name: Publish Snap +name: Build and Publish on: push: branches: - - snap + - main env: FLUTTER_VERSION: '3.24.x' @@ -16,11 +16,11 @@ jobs: - name: Check version in pubspec.yaml id: check run: | - echo "Head branch: ${GITHUB_HEAD_REF}" - echo "Base branch: ${GITHUB_BASE_REF}" changed=$(git diff --unified=0 --merge-base HEAD HEAD^ -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) echo $changed >> $GITHUB_OUTPUT echo "lines changed: $changed" + echo "Head branch: ${GITHUB_HEAD_REF}" + echo "Base branch: ${GITHUB_BASE_REF}" - uses: actions/checkout@v4 - uses: subosito/flutter-action@v2 with: @@ -32,10 +32,11 @@ jobs: - uses: snapcore/action-build@v1 if: steps.check.outputs.changed == '5' id: build - - uses: snapcore/action-publish@v1 - if: steps.build.outcome == 'success' - env: - SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} - with: - snap: ${{ steps.build.outputs.snap }} - release: edge + # Disabled until linux arm runners are available + # - uses: snapcore/action-publish@v1 + # if: steps.build.outcome == 'success' + # env: + # SNAPCRAFT_STORE_CREDENTIALS: ${{ secrets.SNAPCRAFT_STORE_CREDENTIALS }} + # with: + # snap: ${{ steps.build.outputs.snap }} + # release: edge diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 98f4fd9b7..8494d6f43 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -51,15 +51,4 @@ jobs: - run: sudo apt update - run: sudo apt install -y clang cmake curl libgtk-3-dev ninja-build pkg-config unzip libunwind-dev libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev libmpv-dev - run: flutter pub get - - run: flutter build linux -v - - name: Check version in pubspec.yaml - id: check - run: | - changed=$(git diff --unified=0 HEAD... -- 'pubspec.yaml' | grep -n '^@@' | cut -d':' -f1) - echo "Head branch: ${GITHUB_HEAD_REF}" - echo "Base branch: ${GITHUB_BASE_REF}" - echo $changed >> $GITHUB_OUTPUT - echo "lines changed: $changed" - - uses: snapcore/action-build@v1 - if: steps.check.outputs.changed == '5' - id: build \ No newline at end of file + - run: flutter build linux -v \ No newline at end of file From 4b64c695476e3a55ff52aa3067d8c6f593752f79 Mon Sep 17 00:00:00 2001 From: Feichtmeier Date: Thu, 15 Aug 2024 17:01:56 +0200 Subject: [PATCH 27/27] 3 --- pubspec.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pubspec.yaml b/pubspec.yaml index b12c32425..22eee5349 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,6 +1,6 @@ name: musicpod description: Ubuntu music, radio and podcast player. -version: 1.5.5 +version: 1.5.3 publish_to: "none"