diff --git a/.github/workflows/build-package.yml b/.github/workflows/build-package.yml index 854bb9c..e3eb3f4 100644 --- a/.github/workflows/build-package.yml +++ b/.github/workflows/build-package.yml @@ -3,13 +3,16 @@ name: Build Package # Controls when the workflow will run on: workflow_dispatch: - + push: #branches: [ "master", "main", "*" ] branches: [ "*" ] - pull_request: + #pull_request: #branches: [ "master", "main", "*" ] - branches: [ "*" ] + #branches: [ "*" ] + +# The job only calls the build repository's API with its own token. +permissions: {} # A workflow run is made up of one or more jobs that can run sequentially or in parallel jobs: @@ -22,6 +25,12 @@ jobs: steps: - name: Send Hooks BigLinux Build Package shell: bash + # Passed through the environment: a branch name expanded into the script + # could close its quotes and run commands with the token. + env: + WEBHOOK_TOKEN: ${{ secrets.WEBHOOK_TOKEN }} + REPOSITORY: ${{ github.repository }} + BRANCH: ${{ github.ref_name }} run: | - curl -X POST -H "Accept: application/json" -H "Authorization: token ${{ secrets.WEBHOOK_TOKEN }}" --data '{"event_type": "${{ github.repository }}", "client_payload": { "branch": "${{ github.ref_name }}", "url": "https://github.com/${{ github.repository }}", "version": "1.2.3"}}' https://api.github.com/repos/BigLinux-Package-Build/build-package/dispatches - curl -X POST -H "Accept: application/json" -H "Authorization: token ${{ secrets.WEBHOOK_TOKEN }}" --data '{"event_type": "${{ github.repository }}", "client_payload": { "branch": "${{ github.ref_name }}", "url": "https://github.com/${{ github.repository }}"}}' https://api.github.com/repos/BigLinux-Package-Build/build-package-ARM/dispatches + curl -X POST -H "Accept: application/json" -H "Authorization: token $WEBHOOK_TOKEN" --data "$(jq -n --arg repository "$REPOSITORY" --arg branch "$BRANCH" '{event_type: $repository, client_payload: {branch: $branch, url: "https://github.com/\($repository)", version: "1.2.3"}}')" https://api.github.com/repos/BigLinux-Package-Build/build-package/dispatches + curl -X POST -H "Accept: application/json" -H "Authorization: token $WEBHOOK_TOKEN" --data "$(jq -n --arg repository "$REPOSITORY" --arg branch "$BRANCH" '{event_type: $repository, client_payload: {branch: $branch, url: "https://github.com/\($repository)"}}')" https://api.github.com/repos/BigLinux-Package-Build/build-package-ARM/dispatches diff --git a/big-first-boot/usr/bin/big-first-boot b/big-first-boot/usr/bin/big-first-boot index 491410d..bca7196 100755 --- a/big-first-boot/usr/bin/big-first-boot +++ b/big-first-boot/usr/bin/big-first-boot @@ -4,30 +4,6 @@ # systemctl stop NetworkManager-wait-online # systemctl disable NetworkManager-wait-online -if grep -q wayland /proc/cmdline; then - -echo '[General] -DisplayServer=wayland -GreeterEnvironment=QT_WAYLAND_SHELL_INTEGRATION=layer-shell - -[Wayland] -CompositorCommand=kwin_wayland --drm --no-lockscreen --no-global-shortcuts --locale1 --inputmethod maliit-keyboard' > /etc/sddm.conf.d/10-wayland.conf - -sed -i 's|livecd.desktop|livecdWayland.desktop|g' /etc/sddm.conf - -echo '[Last] -Session=/usr/share/wayland-sessions/plasmawayland.desktop' > /var/lib/sddm/state.conf - -else - if [[ -e /etc/gdm/custom.conf ]]; then - sed -i 's| *#*WaylandEnable=false|WaylandEnable=false|g' /etc/gdm/custom.conf - fi - - if [[ -e /etc/sddm.conf.d/10-wayland.conf ]]; then - rm -f /etc/sddm.conf.d/10-wayland.conf - fi -fi - if [ ! -e "/livefs-pkgs.txt" ]; then #Enable automatic update grub and configure timeshift