From e57b839d945fc05fe700630d7eaaa5199668b7ff Mon Sep 17 00:00:00 2001 From: XargonWan Date: Tue, 5 Nov 2024 15:30:16 +0900 Subject: [PATCH] Migrating repo to new workflow --- automation_tools/install_dependencies.sh | 31 ------------------------ update_from_upstream.sh | 4 --- workflows/build-artifacts.yml | 16 ++++++++++++ workflows/pr-from-upstream.yml | 11 +++++++++ 4 files changed, 27 insertions(+), 35 deletions(-) delete mode 100755 automation_tools/install_dependencies.sh delete mode 100755 update_from_upstream.sh create mode 100644 workflows/build-artifacts.yml create mode 100644 workflows/pr-from-upstream.yml diff --git a/automation_tools/install_dependencies.sh b/automation_tools/install_dependencies.sh deleted file mode 100755 index 3daa4ed..0000000 --- a/automation_tools/install_dependencies.sh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/bash -# This script is installing the required dependencies to correctly run the pipeline and build the flatpak - -unset pkg_mgr - -# rpm-ostree must be checked before dnf because a dnf (wrapper) command also works on rpm-ostree distros (not what we want) -for potential_pkg_mgr in apt pacman rpm-ostree dnf; do - command -v "$potential_pkg_mgr" &> /dev/null && pkg_mgr="$potential_pkg_mgr" && break -done - -case "$pkg_mgr" in - apt) - sudo apt install -y flatpak flatpak-builder p7zip-full xmlstarlet bzip2 curl jq - ;; - pacman) - sudo pacman -S --noconfirm flatpak flatpak-builder p7zip xmlstarlet bzip2 - ;; - rpm-ostree) - echo "When using a distro with rpm-ostree, you shouldn't build directly on the host. Try using a distrobox." - exit 1 - ;; - dnf) - sudo dnf install -y flatpak flatpak-builder p7zip p7zip-plugins xmlstarlet bzip2 curl - ;; - *) - echo "Package manager $pkg_mgr not supported. Please open an issue." - ;; -esac - -flatpak remote-add --user --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo -flatpak remote-add --user --if-not-exists flathub-beta https://flathub.org/beta-repo/flathub-beta.flatpakrepo diff --git a/update_from_upstream.sh b/update_from_upstream.sh deleted file mode 100755 index 95f1990..0000000 --- a/update_from_upstream.sh +++ /dev/null @@ -1,4 +0,0 @@ -#!/bin/bash - -git fetch https://github.com/flathub/org.ppsspp.PPSSPP master # Fetch the latest changes from the remote master branch -git merge FETCH_HEAD # Merge the fetched changes into your current branch \ No newline at end of file diff --git a/workflows/build-artifacts.yml b/workflows/build-artifacts.yml new file mode 100644 index 0000000..4acb600 --- /dev/null +++ b/workflows/build-artifacts.yml @@ -0,0 +1,16 @@ +name: "Build Artifacts for RetroDECK main manifest" + +on: + push: + branches: + - master + - main + workflow_call: + workflow_dispatch: + +jobs: + + build-project: + uses: RetroDECK/components-template/.github/workflows/build_artifacts.yml@main + with: + MANIFEST_FILENAME: "org.ppsspp.PPSSPP.yml" \ No newline at end of file diff --git a/workflows/pr-from-upstream.yml b/workflows/pr-from-upstream.yml new file mode 100644 index 0000000..7eaa9b4 --- /dev/null +++ b/workflows/pr-from-upstream.yml @@ -0,0 +1,11 @@ +name: "Sync with Upstream and Create PR" + +on: + workflow_call: + workflow_dispatch: + schedule: + - cron: "30 0 * * *" # Run every day at 00:30 UTC (9:30 JST) + +jobs: + upstream-sync: + uses: RetroDECK/components-template/.github/workflows/pr_from_upstream.yml@main \ No newline at end of file