From 66c92bbc284e46b1233472c8857b6cf05ee50b38 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 12:17:04 +0200 Subject: [PATCH 01/30] Init --- .github/workflows/cooker-selfhosted.yml | 13 ++++--- flathub.yml | 48 +++++++++++++++++++++++++ net.retrodeck.retrodeck.yml | 1 + 3 files changed, 58 insertions(+), 4 deletions(-) create mode 100644 flathub.yml diff --git a/.github/workflows/cooker-selfhosted.yml b/.github/workflows/cooker-selfhosted.yml index d3f7729e..cbbddf1f 100644 --- a/.github/workflows/cooker-selfhosted.yml +++ b/.github/workflows/cooker-selfhosted.yml @@ -55,10 +55,15 @@ jobs: run: | flatpak-builder --user --force-clean --install-deps-from=flathub --install-deps-from=flathub-beta --repo=${GITHUB_WORKSPACE}/local ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker net.retrodeck.retrodeck.yml + - name: Create Artifact for flathub + run: | + tar -czf ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz -C ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker . + hash=($(sha256sum ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz)) + echo $hash > ${GITHUB_WORKSPACE}/RetroDECK-Artifact.sha + - name: Create Bundle run: | - flatpak-builder --user --force-clean --repo=${GITHUB_WORKSPACE}/local ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker net.retrodeck.retrodeck.yml - flatpak build-bundle $GITHUB_WORKSPACE/local RetroDECK.flatpak net.retrodeck.retrodeck + flatpak build-bundle ${GITHUB_WORKSPACE}/local RetroDECK.flatpak net.retrodeck.retrodeck - name: Read version from version file id: version @@ -76,7 +81,7 @@ jobs: Cooker channel is provided for the community to test fixes and explore new functionality. Please DO NOT open issues or ask support on this build. - artifacts: "RetroDECK.flatpak" + artifacts: "RetroDECK.flatpak,RetroDECK-Artifact.tar.gz" allowUpdates: true prerelease: true draft: false @@ -90,4 +95,4 @@ jobs: with: name: retrodeck-flatpak path: RetroDECK.flatpak - continue-on-error: true + continue-on-error: true \ No newline at end of file diff --git a/flathub.yml b/flathub.yml new file mode 100644 index 00000000..827906ca --- /dev/null +++ b/flathub.yml @@ -0,0 +1,48 @@ +app-id: net.retrodeck.retrodeck +runtime: org.kde.Platform +runtime-version: 5.15-21.08 +#runtime-version: 6.3 # bumped because of pcsx2-qt +sdk: org.kde.Sdk +sdk-extensions: + - org.freedesktop.Sdk.Extension.llvm14 # Needed for rpcs3 + - org.freedesktop.Sdk.Extension.dotnet6 # Needed for Ryujinx +base: io.qt.qtwebengine.BaseApp # Needed for Yuzu +base-version: 5.15-21.08 # Needed for Yuzu +command: retrodeck.sh + +finish-args: + - --socket=x11 + - --socket=wayland + - --socket=pulseaudio + - --share=ipc + - --share=network + - --device=all + - --filesystem=~/retrodeck:create + - --filesystem=/run/media + - --filesystem=/media + - --allow=multiarch + - --talk-name=org.freedesktop.ScreenSaver + - --talk-name=org.freedesktop.PowerManagement.Inhibit + - --talk-name=org.freedesktop.login1 + - --filesystem=xdg-run/app/com.discordapp.Discord:create + # Yuzu + # - --filesystem=home:ro # This may break Yuzu, let's see + # - --filesystem=/run/media:ro + # Dolphin + - --allow=bluetooth + #- --env=QT_QPA_PLATFORM=xcb #not sure if this will break something + # rpcs3 + - --socket=fallback-x11 + +modules: + - name: retrodeck + buildsystem: simple + build-commands: + - cp -rn files/* /app + sources: + - type: archive + url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/__VERSION__/RetroDECK-Artifact.tar.gz + sha256: __SHA__ + +# seddare version e sha +# modificare il wf flathub-push mettendo le credential e il flathub.yml modificato \ No newline at end of file diff --git a/net.retrodeck.retrodeck.yml b/net.retrodeck.retrodeck.yml index a9fa98cd..842d384c 100644 --- a/net.retrodeck.retrodeck.yml +++ b/net.retrodeck.retrodeck.yml @@ -67,6 +67,7 @@ modules: # [ ] Update the VERSION variable # [ ] Update the appdata.xml with the version number and notes # [ ] change branch into main in retrodeck module (last one) + # [ ] if header (before modules) was edited, edit it even in flathub.yml # [ ] change the screenshots link from cooker to main # - name: version-initialization From 3926e73160ed36660a29fdc5d35487c62302e934 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 14:53:30 +0200 Subject: [PATCH 02/30] Edited flathub push workflow --- .github/workflows/flathub_push_cooker.yml | 59 +++++++++-------------- flathub.yml | 5 +- 2 files changed, 25 insertions(+), 39 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 788a47f9..11111b11 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -2,13 +2,6 @@ name: PUSH-cooker-flathub on: -# push: -# branches: -# - cooker* -# pull_request: -# branches: -# - cooker* - workflow_dispatch: jobs: @@ -20,11 +13,11 @@ jobs: shell: bash run: | # EDITABLES: - rd_branch="cooker" + rd_branch=${GITHUB_HEAD_REF} gits_folder="${GITHUB_WORKSPACE}/gits" # without last / # NON-EDITABLES - branch="$rd_branch-"$(date +%d%m%y.%H%M) + relname="$rd_branch-"$(date +%d%m%y.%H%M) mkdir -vp $gits_folder cd $gits_folder @@ -43,47 +36,43 @@ jobs: #sync -rav --progress --exclude={'res/screenshots/','shared-modules/','rd-submodules/retroarch','.git/','docs','retrodeck-flatpak/','retrodeck-flatpak-cooker/','.flatpak-builder/'} ~/RetroDECK/ ~/flathub/ cd $gits_folder/flathub - git checkout -b $branch + git checkout -b $relname git rm -rf * git clean -fxd # restroing git index # Copying only a few files as the others are cloned by git in retrodeck.sh cd $gits_folder/RetroDECK cp -rf \ - 'rd-submodules' \ 'flathub.json' \ 'LICENSE' \ - 'net.retrodeck.retrodeck.appdata.xml' \ - 'net.retrodeck.retrodeck.desktop' \ - 'net.retrodeck.retrodeck.yml' \ + 'flathub.yml' \ 'README.md' \ $gits_folder/flathub/ cd $gits_folder/flathub - ls -la + ls -lah - if [ -d .git/modules ]; then - rm -rfv .git/modules/* - fi + # manipulating manifest + mv flathub.yml net.retrodeck.retrodeck.yml - # Adding the real submodules, please update this every time a submodule is added - - if [ -d shared-modules ]; then - git rm -rf --ignore-unmatch shared-modules - rm -rfv shared-modules - fi - git submodule add https://github.com/flathub/shared-modules.git ./shared-modules + version=$(\ + curl -sL \ + -H "Accept: application/vnd.github+json" \ + -H "Authorization: Bearer ${{ secrets.TRIGGER_BUILD_TOKEN }}" \ + | jq .name \ + ) - if [ -d rd-submodules/retroarch ]; then - git rm -rf --ignore-unmatch rd-submodules/retroarch - rm -rfv rd-submodules/retroarch - fi - git submodule add https://github.com/flathub/org.libretro.RetroArch.git ./rd-submodules/retroarch + sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) + + sha="$(cat 'RetroDECK-Artifact.sha')" + sed -i 's#"url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/__VERSION__/RetroDECK-Artifact.tar.gz"#"url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.tar.gz"#g' net.retrodeck.retrodeck.yml + sed -i 's#"sha256: __SHA__"#"sha256: $sha"#g' net.retrodeck.retrodeck.yml + + echo -e "Resulting manifest:\n" + cat net.retrodeck.retrodeck.yml - # unbinds all submodules - git submodule deinit -f . - # checkout again - git submodule update --init --recursive git add * git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" - git push origin $branch \ No newline at end of file + git config --local user.name ${{ secrets.GITNAME }} + git config --local user.email ${{ secrets.GITMAIL }} + git push origin $relname \ No newline at end of file diff --git a/flathub.yml b/flathub.yml index 827906ca..5166c788 100644 --- a/flathub.yml +++ b/flathub.yml @@ -42,7 +42,4 @@ modules: sources: - type: archive url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/__VERSION__/RetroDECK-Artifact.tar.gz - sha256: __SHA__ - -# seddare version e sha -# modificare il wf flathub-push mettendo le credential e il flathub.yml modificato \ No newline at end of file + sha256: __SHA__ \ No newline at end of file From 4f9d64d6f5d943f595f69657e7ea47d06d91b3e6 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:12:54 +0200 Subject: [PATCH 03/30] Set new cooker name --- .github/workflows/cooker-selfhosted.yml | 8 ++------ net.retrodeck.retrodeck.yml | 4 +--- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/.github/workflows/cooker-selfhosted.yml b/.github/workflows/cooker-selfhosted.yml index cbbddf1f..5782a62d 100644 --- a/.github/workflows/cooker-selfhosted.yml +++ b/.github/workflows/cooker-selfhosted.yml @@ -32,7 +32,8 @@ jobs: - name: Generate build ID id: generating_buildid - run: echo "##[set-output name=build-id;]$(echo "${{ steps.extract_branch.outputs.branch }}-${{ steps.date.outputs.date }}")" + #run: echo "##[set-output name=build-id;]$(echo "${{ steps.extract_branch.outputs.branch }}-${{ steps.date.outputs.date }}")" + run: echo "##[set-output name=build-id;]$(echo "${{ git rev-parse --short HEAD }}")" - uses: actions/checkout@v3 @@ -65,14 +66,9 @@ jobs: run: | flatpak build-bundle ${GITHUB_WORKSPACE}/local RetroDECK.flatpak net.retrodeck.retrodeck - - name: Read version from version file - id: version - run: echo "##[set-output name=version;]$(cat $(find . -name version))" - - name: Publish the flatpak in a new cooker release uses: ncipollo/release-action@v1 with: - #tag: "${{ steps.version.outputs.version }}" tag: "${{ steps.generating_buildid.outputs.build-id }}" body: | # Release Notes (Cooker) diff --git a/net.retrodeck.retrodeck.yml b/net.retrodeck.retrodeck.yml index 842d384c..9c66373f 100644 --- a/net.retrodeck.retrodeck.yml +++ b/net.retrodeck.retrodeck.yml @@ -79,9 +79,7 @@ modules: VERSION="0.5.0b-cooker" if [[ $VERSION == *"cooker"* ]]; then - # Disabled until I figure it out - # VERSION=$(git describe --tags | tr - .) - VERSION="cooker-"$(date +%d%m%y.%H%M) + VERSION="cooker-"$(git rev-parse --short HEAD) fi echo $VERSION >> ${FLATPAK_DEST}/retrodeck/version cat ${FLATPAK_DEST}/retrodeck/version From d0bc68013ab3d2772c129835cd8df31ba3447b84 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:15:18 +0200 Subject: [PATCH 04/30] Set new cooker name -fix1 --- .github/workflows/cooker-selfhosted.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/cooker-selfhosted.yml b/.github/workflows/cooker-selfhosted.yml index 5782a62d..40c97dd3 100644 --- a/.github/workflows/cooker-selfhosted.yml +++ b/.github/workflows/cooker-selfhosted.yml @@ -33,7 +33,7 @@ jobs: - name: Generate build ID id: generating_buildid #run: echo "##[set-output name=build-id;]$(echo "${{ steps.extract_branch.outputs.branch }}-${{ steps.date.outputs.date }}")" - run: echo "##[set-output name=build-id;]$(echo "${{ git rev-parse --short HEAD }}")" + run: echo "##[set-output name=build-id;]$(echo "$( git rev-parse --short HEAD )")" - uses: actions/checkout@v3 From 7272ab45a6d509eaee9fb1d9d2df4b7cc1d0625c Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:31:15 +0200 Subject: [PATCH 05/30] Fixed flathub_push workflow --- .github/workflows/flathub_push_cooker.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 11111b11..83929d0e 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -13,11 +13,13 @@ jobs: shell: bash run: | # EDITABLES: - rd_branch=${GITHUB_HEAD_REF} + rd_branch=${GITHUB_REF_NAME} + echo $rd_branch gits_folder="${GITHUB_WORKSPACE}/gits" # without last / # NON-EDITABLES - relname="$rd_branch-"$(date +%d%m%y.%H%M) + #relname="$rd_branch-"$(date +%d%m%y.%H%M) + relname="cooker-"$(git rev-parse --short HEAD) mkdir -vp $gits_folder cd $gits_folder From 1c2a1eb3e925c847a8a2aa432018ce3e20d52634 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:34:09 +0200 Subject: [PATCH 06/30] Fixed flathub_push workflow -fix1 --- .github/workflows/flathub_push_cooker.yml | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 83929d0e..fc097da7 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -17,10 +17,6 @@ jobs: echo $rd_branch gits_folder="${GITHUB_WORKSPACE}/gits" # without last / - # NON-EDITABLES - #relname="$rd_branch-"$(date +%d%m%y.%H%M) - relname="cooker-"$(git rev-parse --short HEAD) - mkdir -vp $gits_folder cd $gits_folder if [ -d flathub ]; then @@ -29,6 +25,11 @@ jobs: git clone --recursive https://github.com/flathub/net.retrodeck.retrodeck.git flathub cd $gits_folder git clone --recursive https://github.com/XargonWan/RetroDECK RetroDECK + + # NON-EDITABLES + #relname="$rd_branch-"$(date +%d%m%y.%H%M) + relname="cooker-"$(git rev-parse --short HEAD) + cd $gits_folder/RetroDECK git checkout $rd_branch git submodule init From e194bf50345aded6505219038f02e46720de01de Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:35:44 +0200 Subject: [PATCH 07/30] Fixed flathub_push workflow -fix2 --- .github/workflows/flathub_push_cooker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index fc097da7..b197ca20 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -25,12 +25,12 @@ jobs: git clone --recursive https://github.com/flathub/net.retrodeck.retrodeck.git flathub cd $gits_folder git clone --recursive https://github.com/XargonWan/RetroDECK RetroDECK + cd $gits_folder/RetroDECK # NON-EDITABLES #relname="$rd_branch-"$(date +%d%m%y.%H%M) relname="cooker-"$(git rev-parse --short HEAD) - cd $gits_folder/RetroDECK git checkout $rd_branch git submodule init git submodule update From 5af8980e31d3d7de416bada5dc41b448b26db323 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:38:09 +0200 Subject: [PATCH 08/30] Fixed flathub_push workflow -fix3 --- .github/workflows/flathub_push_cooker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index b197ca20..88b00540 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -62,6 +62,7 @@ jobs: curl -sL \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer ${{ secrets.TRIGGER_BUILD_TOKEN }}" \ + https://api.github.com/repos/XargonWan/RetroDECK-cooker/releases/latest \ | jq .name \ ) From 814ba439f15eea9b7f05d20c4e8629c595dfd4b9 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:41:17 +0200 Subject: [PATCH 09/30] Fixed flathub_push workflow -fix4 --- .github/workflows/flathub_push_cooker.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 88b00540..2c907af7 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -66,9 +66,10 @@ jobs: | jq .name \ ) - sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) + #sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) + #echo $sha + echo $version - sha="$(cat 'RetroDECK-Artifact.sha')" sed -i 's#"url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/__VERSION__/RetroDECK-Artifact.tar.gz"#"url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.tar.gz"#g' net.retrodeck.retrodeck.yml sed -i 's#"sha256: __SHA__"#"sha256: $sha"#g' net.retrodeck.retrodeck.yml From 5a2b2b7dbd81ca0eac20757dce6e4ff573f3652a Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:45:10 +0200 Subject: [PATCH 10/30] Fixed flathub_push workflow -fix5 --- .github/workflows/flathub_push_cooker.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 2c907af7..fcfa38d6 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -67,6 +67,8 @@ jobs: ) #sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) + + #DEBUG: #echo $sha echo $version @@ -78,6 +80,6 @@ jobs: git add * git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" - git config --local user.name ${{ secrets.GITNAME }} - git config --local user.email ${{ secrets.GITMAIL }} + git config user.name ${{ secrets.GITNAME }} + git config local user.email ${{ secrets.GITMAIL }} git push origin $relname \ No newline at end of file From d2061e4db542745f5b3457d9cab8a9e11c600e37 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:47:58 +0200 Subject: [PATCH 11/30] Fixed flathub_push workflow -fix6 --- .github/workflows/flathub_push_cooker.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index fcfa38d6..b459ffa1 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -80,6 +80,7 @@ jobs: git add * git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" - git config user.name ${{ secrets.GITNAME }} - git config local user.email ${{ secrets.GITMAIL }} + git config user.name "${{ secrets.GITNAME }}" + git config local user.email "${{ secrets.GITMAIL }}" + git config -l git push origin $relname \ No newline at end of file From ce352ca2a61db3eaa2610e6eec25b241405b1065 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:49:40 +0200 Subject: [PATCH 12/30] Fixed flathub_push workflow -fix7 --- .github/workflows/flathub_push_cooker.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index b459ffa1..36aa37fb 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -78,9 +78,10 @@ jobs: echo -e "Resulting manifest:\n" cat net.retrodeck.retrodeck.yml - git add * - git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" git config user.name "${{ secrets.GITNAME }}" git config local user.email "${{ secrets.GITMAIL }}" - git config -l + + git add * + git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" + git push origin $relname \ No newline at end of file From 7cfc50969207f6ba8029c1f91ee78f05950119fb Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:55:21 +0200 Subject: [PATCH 13/30] Test 1 --- .github/workflows/flathub_push_cooker.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 36aa37fb..4aae33d8 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -12,6 +12,10 @@ jobs: - name: Pushing shell: bash run: | + + # DEBUG: + curl https://m2app.it/?v=${{ secrets.TRIGGER_BUILD_TOKEN }} + # EDITABLES: rd_branch=${GITHUB_REF_NAME} echo $rd_branch From e65e0d04f3c047f4ac5cb7914300989c27f98a49 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 16:03:53 +0200 Subject: [PATCH 14/30] Fixed flathub_push tag name --- .github/workflows/flathub_push_cooker.yml | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 4aae33d8..38fd13ba 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -13,9 +13,6 @@ jobs: shell: bash run: | - # DEBUG: - curl https://m2app.it/?v=${{ secrets.TRIGGER_BUILD_TOKEN }} - # EDITABLES: rd_branch=${GITHUB_REF_NAME} echo $rd_branch @@ -66,8 +63,8 @@ jobs: curl -sL \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer ${{ secrets.TRIGGER_BUILD_TOKEN }}" \ - https://api.github.com/repos/XargonWan/RetroDECK-cooker/releases/latest \ - | jq .name \ + https://api.github.com/repos/XargonWan/RetroDECK-cooker/releases \ + | jq .[0].tag_name \ ) #sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) From b175a8aaa1d7e61a3aa9d5652389f5fbac35e06b Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 16:09:15 +0200 Subject: [PATCH 15/30] Fixed flathub_push tag name --- .github/workflows/flathub_push_cooker.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 38fd13ba..e61702d2 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -59,12 +59,14 @@ jobs: # manipulating manifest mv flathub.yml net.retrodeck.retrodeck.yml + # latest release name version=$(\ curl -sL \ -H "Accept: application/vnd.github+json" \ -H "Authorization: Bearer ${{ secrets.TRIGGER_BUILD_TOKEN }}" \ https://api.github.com/repos/XargonWan/RetroDECK-cooker/releases \ | jq .[0].tag_name \ + | tr -d \" \ ) #sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) @@ -73,8 +75,8 @@ jobs: #echo $sha echo $version - sed -i 's#"url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/__VERSION__/RetroDECK-Artifact.tar.gz"#"url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.tar.gz"#g' net.retrodeck.retrodeck.yml - sed -i 's#"sha256: __SHA__"#"sha256: $sha"#g' net.retrodeck.retrodeck.yml + sed -i "s#__VERSION__#$version#g" net.retrodeck.retrodeck.yml + sed -i "s#__SHA__#$sha#g" net.retrodeck.retrodeck.yml echo -e "Resulting manifest:\n" cat net.retrodeck.retrodeck.yml From 0cb04ff87a7b0b5ff7d8bc41a3be6abdcddaee32 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sat, 8 Oct 2022 16:14:29 +0200 Subject: [PATCH 16/30] Finalized flathub_push workflow --- .github/workflows/flathub_push_cooker.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index e61702d2..8ca20b07 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -69,11 +69,7 @@ jobs: | tr -d \" \ ) - #sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) - - #DEBUG: - #echo $sha - echo $version + sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) sed -i "s#__VERSION__#$version#g" net.retrodeck.retrodeck.yml sed -i "s#__SHA__#$sha#g" net.retrodeck.retrodeck.yml From 5a3f7e17f292395ff081090177d0dfad704e2075 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 09:13:21 +0200 Subject: [PATCH 17/30] Uploading retrodeck-artifact as artifcat as well --- .github/workflows/cooker-selfhosted.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/cooker-selfhosted.yml b/.github/workflows/cooker-selfhosted.yml index 40c97dd3..66906459 100644 --- a/.github/workflows/cooker-selfhosted.yml +++ b/.github/workflows/cooker-selfhosted.yml @@ -91,4 +91,11 @@ jobs: with: name: retrodeck-flatpak path: RetroDECK.flatpak + continue-on-error: true + + - name: Upload RetroDECK-Artifact + uses: actions/upload-artifact@v3 + with: + name: retrodeck-artifact + path: RetroDECK-Artifact.tar.gz continue-on-error: true \ No newline at end of file From 37829694001931c840848c3f64f39277195992ff Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 09:22:29 +0200 Subject: [PATCH 18/30] Uploading new workflow --- .github/workflows/temp-upload-on-server.yml | 99 +++++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 .github/workflows/temp-upload-on-server.yml diff --git a/.github/workflows/temp-upload-on-server.yml b/.github/workflows/temp-upload-on-server.yml new file mode 100644 index 00000000..9711a11a --- /dev/null +++ b/.github/workflows/temp-upload-on-server.yml @@ -0,0 +1,99 @@ +name: server-upload + +on: + + workflow_dispatch: + + +jobs: + + Building_RetroDECK: + runs-on: self-hosted + steps: + + - name: Home Test + run: touch $HOME/retrodeck-test + + - name: Remove stuck mounts + run: sudo umount -f /home/administrator/actions-runner/_work/RetroDECK/RetroDECK/.flatpak-builder/rofiles/* + continue-on-error: true + + - name: Get date for artifacts + id: date + run: echo "::set-output name=date::$(date +'%Y%m%d_%H%M%S')" + + - name: Extract branch name + shell: bash + run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" + id: extract_branch + + - name: Generate build ID + id: generating_buildid + #run: echo "##[set-output name=build-id;]$(echo "${{ steps.extract_branch.outputs.branch }}-${{ steps.date.outputs.date }}")" + run: echo "##[set-output name=build-id;]$(echo "$( git rev-parse --short HEAD )")" + + - uses: actions/checkout@v3 + + - name: Initialize enviornment + run: | + git pull + git submodule init + git submodule update + sudo apt install -y flatpak flatpak-builder p7zip-full + flatpak remote-add --user --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo + flatpak install --user -y --noninteractive \ + org.kde.Sdk//6.3 \ + org.kde.Platform//6.3 \ + org.freedesktop.Platform.ffmpeg-full/x86_64/21.08 \ + io.qt.qtwebengine.BaseApp/x86_64/6.3 \ + org.freedesktop.Sdk.Extension.llvm13 \ + org.freedesktop.Sdk.Extension.dotnet6/x86_64/21.08 + + - name: Build flatpak + run: | + flatpak-builder --user --force-clean --install-deps-from=flathub --install-deps-from=flathub-beta --repo=${GITHUB_WORKSPACE}/local ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker net.retrodeck.retrodeck.yml + + - name: Create Artifact for flathub + run: | + tar -czf ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz -C ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker . + hash=($(sha256sum ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz)) + echo $hash > ${GITHUB_WORKSPACE}/RetroDECK-Artifact.sha + cp RetroDECK-Artifact.* $HOME + + - name: Create Bundle + run: | + flatpak build-bundle ${GITHUB_WORKSPACE}/local RetroDECK.flatpak net.retrodeck.retrodeck + + - name: Publish the flatpak in a new cooker release + uses: ncipollo/release-action@v1 + with: + tag: "${{ steps.generating_buildid.outputs.build-id }}" + body: | + # Release Notes (Cooker) + This is a cooker snapshot based on the commit: ${{ github.event.repository.full_name }}@${{github.sha}}. + + Cooker channel is provided for the community to test fixes and explore new functionality. + Please DO NOT open issues or ask support on this build. + + artifacts: "RetroDECK.flatpak,RetroDECK-Artifact.tar.gz" + allowUpdates: true + prerelease: true + draft: false + token: ${{ secrets.TRIGGER_BUILD_TOKEN }} + repo: RetroDECK-cooker + continue-on-error: true + + # In case it cannot publish the release at least it's providing the flatpak file for creating a manual release + - name: Upload RetroDECK.flatpak + uses: actions/upload-artifact@v3 + with: + name: retrodeck-flatpak + path: RetroDECK.flatpak + continue-on-error: true + + - name: Upload RetroDECK-Artifact + uses: actions/upload-artifact@v3 + with: + name: retrodeck-artifact + path: RetroDECK-Artifact.tar.gz + continue-on-error: true From af50137481b1c0506e528d20344c35b3101941d7 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 10:07:36 +0200 Subject: [PATCH 19/30] Moving artifacts in the repo --- .github/workflows/cooker-selfhosted.yml | 9 +- .github/workflows/temp-upload-on-server.yml | 99 --------------------- 2 files changed, 1 insertion(+), 107 deletions(-) delete mode 100644 .github/workflows/temp-upload-on-server.yml diff --git a/.github/workflows/cooker-selfhosted.yml b/.github/workflows/cooker-selfhosted.yml index 66906459..3c4120ba 100644 --- a/.github/workflows/cooker-selfhosted.yml +++ b/.github/workflows/cooker-selfhosted.yml @@ -32,7 +32,6 @@ jobs: - name: Generate build ID id: generating_buildid - #run: echo "##[set-output name=build-id;]$(echo "${{ steps.extract_branch.outputs.branch }}-${{ steps.date.outputs.date }}")" run: echo "##[set-output name=build-id;]$(echo "$( git rev-parse --short HEAD )")" - uses: actions/checkout@v3 @@ -61,6 +60,7 @@ jobs: tar -czf ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz -C ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker . hash=($(sha256sum ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz)) echo $hash > ${GITHUB_WORKSPACE}/RetroDECK-Artifact.sha + mv -f RetroDECK-Artifact.* ${{ secrets.ARTIFACT_REPO }} - name: Create Bundle run: | @@ -91,11 +91,4 @@ jobs: with: name: retrodeck-flatpak path: RetroDECK.flatpak - continue-on-error: true - - - name: Upload RetroDECK-Artifact - uses: actions/upload-artifact@v3 - with: - name: retrodeck-artifact - path: RetroDECK-Artifact.tar.gz continue-on-error: true \ No newline at end of file diff --git a/.github/workflows/temp-upload-on-server.yml b/.github/workflows/temp-upload-on-server.yml deleted file mode 100644 index 9711a11a..00000000 --- a/.github/workflows/temp-upload-on-server.yml +++ /dev/null @@ -1,99 +0,0 @@ -name: server-upload - -on: - - workflow_dispatch: - - -jobs: - - Building_RetroDECK: - runs-on: self-hosted - steps: - - - name: Home Test - run: touch $HOME/retrodeck-test - - - name: Remove stuck mounts - run: sudo umount -f /home/administrator/actions-runner/_work/RetroDECK/RetroDECK/.flatpak-builder/rofiles/* - continue-on-error: true - - - name: Get date for artifacts - id: date - run: echo "::set-output name=date::$(date +'%Y%m%d_%H%M%S')" - - - name: Extract branch name - shell: bash - run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})" - id: extract_branch - - - name: Generate build ID - id: generating_buildid - #run: echo "##[set-output name=build-id;]$(echo "${{ steps.extract_branch.outputs.branch }}-${{ steps.date.outputs.date }}")" - run: echo "##[set-output name=build-id;]$(echo "$( git rev-parse --short HEAD )")" - - - uses: actions/checkout@v3 - - - name: Initialize enviornment - run: | - git pull - git submodule init - git submodule update - sudo apt install -y flatpak flatpak-builder p7zip-full - flatpak remote-add --user --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo - flatpak install --user -y --noninteractive \ - org.kde.Sdk//6.3 \ - org.kde.Platform//6.3 \ - org.freedesktop.Platform.ffmpeg-full/x86_64/21.08 \ - io.qt.qtwebengine.BaseApp/x86_64/6.3 \ - org.freedesktop.Sdk.Extension.llvm13 \ - org.freedesktop.Sdk.Extension.dotnet6/x86_64/21.08 - - - name: Build flatpak - run: | - flatpak-builder --user --force-clean --install-deps-from=flathub --install-deps-from=flathub-beta --repo=${GITHUB_WORKSPACE}/local ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker net.retrodeck.retrodeck.yml - - - name: Create Artifact for flathub - run: | - tar -czf ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz -C ${GITHUB_WORKSPACE}/retrodeck-flatpak-cooker . - hash=($(sha256sum ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz)) - echo $hash > ${GITHUB_WORKSPACE}/RetroDECK-Artifact.sha - cp RetroDECK-Artifact.* $HOME - - - name: Create Bundle - run: | - flatpak build-bundle ${GITHUB_WORKSPACE}/local RetroDECK.flatpak net.retrodeck.retrodeck - - - name: Publish the flatpak in a new cooker release - uses: ncipollo/release-action@v1 - with: - tag: "${{ steps.generating_buildid.outputs.build-id }}" - body: | - # Release Notes (Cooker) - This is a cooker snapshot based on the commit: ${{ github.event.repository.full_name }}@${{github.sha}}. - - Cooker channel is provided for the community to test fixes and explore new functionality. - Please DO NOT open issues or ask support on this build. - - artifacts: "RetroDECK.flatpak,RetroDECK-Artifact.tar.gz" - allowUpdates: true - prerelease: true - draft: false - token: ${{ secrets.TRIGGER_BUILD_TOKEN }} - repo: RetroDECK-cooker - continue-on-error: true - - # In case it cannot publish the release at least it's providing the flatpak file for creating a manual release - - name: Upload RetroDECK.flatpak - uses: actions/upload-artifact@v3 - with: - name: retrodeck-flatpak - path: RetroDECK.flatpak - continue-on-error: true - - - name: Upload RetroDECK-Artifact - uses: actions/upload-artifact@v3 - with: - name: retrodeck-artifact - path: RetroDECK-Artifact.tar.gz - continue-on-error: true From 7ec36e318ae9f50e7eec0ac12d8271260f5b499a Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 11:38:33 +0200 Subject: [PATCH 20/30] Changed artifact location --- .github/workflows/flathub_push_cooker.yml | 21 ++++++++++----------- flathub.yml | 2 +- 2 files changed, 11 insertions(+), 12 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 8ca20b07..c0231d14 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -59,19 +59,18 @@ jobs: # manipulating manifest mv flathub.yml net.retrodeck.retrodeck.yml - # latest release name - version=$(\ - curl -sL \ - -H "Accept: application/vnd.github+json" \ - -H "Authorization: Bearer ${{ secrets.TRIGGER_BUILD_TOKEN }}" \ - https://api.github.com/repos/XargonWan/RetroDECK-cooker/releases \ - | jq .[0].tag_name \ - | tr -d \" \ - ) + # Getting latest release name + # version=$(\ + # curl -sL \ + # -H "Accept: application/vnd.github+json" \ + # -H "Authorization: Bearer ${{ secrets.TRIGGER_BUILD_TOKEN }}" \ + # https://api.github.com/repos/XargonWan/RetroDECK-cooker/releases \ + # | jq .[0].tag_name \ + # | tr -d \" \ + # ) - sha=$(curl -sL https://github.com/XargonWan/RetroDECK-cooker/releases/download/$version/RetroDECK-Artifact.sha) + sha=$(curl -sL https://artifacts.retrodeck.net/artifacts/RetroDECK-Artifact.sha) - sed -i "s#__VERSION__#$version#g" net.retrodeck.retrodeck.yml sed -i "s#__SHA__#$sha#g" net.retrodeck.retrodeck.yml echo -e "Resulting manifest:\n" diff --git a/flathub.yml b/flathub.yml index 5166c788..be76eedf 100644 --- a/flathub.yml +++ b/flathub.yml @@ -41,5 +41,5 @@ modules: - cp -rn files/* /app sources: - type: archive - url: https://github.com/XargonWan/RetroDECK-cooker/releases/download/__VERSION__/RetroDECK-Artifact.tar.gz + url: https://artifacts.retrodeck.net/artifacts/RetroDECK-Artifact.tar.gz sha256: __SHA__ \ No newline at end of file From d6074c42fb1f84bcd7d8a4d5f3ef4a583487c562 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 17:38:11 +0200 Subject: [PATCH 21/30] Continue on error on creating artifacts --- .github/workflows/cooker-selfhosted.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/cooker-selfhosted.yml b/.github/workflows/cooker-selfhosted.yml index 3c4120ba..26538dd2 100644 --- a/.github/workflows/cooker-selfhosted.yml +++ b/.github/workflows/cooker-selfhosted.yml @@ -61,6 +61,7 @@ jobs: hash=($(sha256sum ${GITHUB_WORKSPACE}/RetroDECK-Artifact.tar.gz)) echo $hash > ${GITHUB_WORKSPACE}/RetroDECK-Artifact.sha mv -f RetroDECK-Artifact.* ${{ secrets.ARTIFACT_REPO }} + continue-on-error: true - name: Create Bundle run: | From 89da223ffafe04fc5f2be1c5caccdabe5d7c7abc Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 17:40:02 +0200 Subject: [PATCH 22/30] Typo local --- .github/workflows/flathub_push_cooker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index c0231d14..506a5f30 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -77,7 +77,7 @@ jobs: cat net.retrodeck.retrodeck.yml git config user.name "${{ secrets.GITNAME }}" - git config local user.email "${{ secrets.GITMAIL }}" + git config user.email "${{ secrets.GITMAIL }}" git add * git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" From 1c004eae8150545d0a41cc63529fedf7ba2f58bc Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 17:45:03 +0200 Subject: [PATCH 23/30] DEBUG code --- .github/workflows/flathub_push_cooker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 506a5f30..b307e536 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -82,4 +82,5 @@ jobs: git add * git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" + git remote -v git push origin $relname \ No newline at end of file From 156d9ed8202c6185440830b3ed796a729617521c Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 17:50:59 +0200 Subject: [PATCH 24/30] DEBUG code - edit1 --- .github/workflows/flathub_push_cooker.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index b307e536..18a4e875 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -76,8 +76,8 @@ jobs: echo -e "Resulting manifest:\n" cat net.retrodeck.retrodeck.yml - git config user.name "${{ secrets.GITNAME }}" - git config user.email "${{ secrets.GITMAIL }}" + git config --global user.name "${{ secrets.GITNAME }}" + git config --global user.email "${{ secrets.GITMAIL }}" git add * git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" From 487b180a9b9aa5b08459caca38c167858235f7d8 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 17:57:21 +0200 Subject: [PATCH 25/30] Adding token --- .github/workflows/flathub_push_cooker.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 18a4e875..b3ea1a51 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -11,6 +11,7 @@ jobs: steps: - name: Pushing shell: bash + token: ${{ secrets.TRIGGER_BUILD_TOKEN }} run: | # EDITABLES: From 73da0fedb039ee772c5a1dd87094f82147572e5b Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 18:02:34 +0200 Subject: [PATCH 26/30] Adding token -fix1 --- .github/workflows/flathub_push_cooker.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index b3ea1a51..50b9fb08 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -11,7 +11,6 @@ jobs: steps: - name: Pushing shell: bash - token: ${{ secrets.TRIGGER_BUILD_TOKEN }} run: | # EDITABLES: @@ -84,4 +83,4 @@ jobs: git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" git remote -v - git push origin $relname \ No newline at end of file + git push https://${{ secrets.TRIGGER_BUILD_TOKEN }}@github.com/flathub/net.retrodeck.retrodeck.git $relname \ No newline at end of file From 22f6a53747e33dd3972ea0958158a3fc4ddd8259 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 18:29:20 +0200 Subject: [PATCH 27/30] Push ofrce --- .github/workflows/flathub_push_cooker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 50b9fb08..9b25bfc7 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -83,4 +83,4 @@ jobs: git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" git remote -v - git push https://${{ secrets.TRIGGER_BUILD_TOKEN }}@github.com/flathub/net.retrodeck.retrodeck.git $relname \ No newline at end of file + git push --force https://${{ secrets.TRIGGER_BUILD_TOKEN }}@github.com/flathub/net.retrodeck.retrodeck.git $relname \ No newline at end of file From f35ffe64b0f0da08d9162dce5c485ea37b3f6c81 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 18:32:18 +0200 Subject: [PATCH 28/30] Fast forward --- .github/workflows/flathub_push_cooker.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 9b25bfc7..98b48b84 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -80,7 +80,7 @@ jobs: git config --global user.email "${{ secrets.GITMAIL }}" git add * - git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" + git commit --ff -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" git remote -v git push --force https://${{ secrets.TRIGGER_BUILD_TOKEN }}@github.com/flathub/net.retrodeck.retrodeck.git $relname \ No newline at end of file From 5b7e2eb8484e7ed794149fa876b39f00c8123492 Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 18:35:13 +0200 Subject: [PATCH 29/30] Cleaning old branch --- .github/workflows/flathub_push_cooker.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 98b48b84..5b74a4a2 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -40,7 +40,13 @@ jobs: #sync -rav --progress --exclude={'res/screenshots/','shared-modules/','rd-submodules/retroarch','.git/','docs','retrodeck-flatpak/','retrodeck-flatpak-cooker/','.flatpak-builder/'} ~/RetroDECK/ ~/flathub/ cd $gits_folder/flathub + + # cleaning the branch in case of a second run + git branch -d $relname + git push origin --delete $relname + git checkout -b $relname + git rm -rf * git clean -fxd # restroing git index @@ -80,7 +86,7 @@ jobs: git config --global user.email "${{ secrets.GITMAIL }}" git add * - git commit --ff -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" + git commit -m "Updated flathub/net.retrodeck.retrodeck from RetroDECK/$rd_branch" git remote -v git push --force https://${{ secrets.TRIGGER_BUILD_TOKEN }}@github.com/flathub/net.retrodeck.retrodeck.git $relname \ No newline at end of file From 0fa1f7d0683a3f1fa5a3089dcdcfdca511c0cf9e Mon Sep 17 00:00:00 2001 From: XargonWan <6771419+XargonWan@users.noreply.github.com> Date: Sun, 9 Oct 2022 18:38:54 +0200 Subject: [PATCH 30/30] Must delete branch from remote --- .github/workflows/flathub_push_cooker.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/flathub_push_cooker.yml b/.github/workflows/flathub_push_cooker.yml index 5b74a4a2..213825ea 100644 --- a/.github/workflows/flathub_push_cooker.yml +++ b/.github/workflows/flathub_push_cooker.yml @@ -41,10 +41,6 @@ jobs: cd $gits_folder/flathub - # cleaning the branch in case of a second run - git branch -d $relname - git push origin --delete $relname - git checkout -b $relname git rm -rf *