Explorar o código

refactor(action): improve fdinfo.c patch application logic and remove obsolete cleanup script

Co-authored-by: Copilot <copilot@github.com>
TheWildJames hai 4 meses
pai
achega
a2a0527a21

+ 2 - 2
.github/actions/susfs/action.yml

@@ -95,7 +95,7 @@ runs:
         fi
         if [ "${{ inputs.sublevel }}" -le "117" ]; then
           echo "Applying fdinfo.c Android 12 5.10 Fake Patch"
-          sed -i '/^\s*\/\*/,/^\s*u32 mask = mark->mask & IN_ALL_EVENTS;$/d' fs/notify/fdinfo.c
+          sed -i '/\/\*$/,/^\s*u32 mask = mark->mask & IN_ALL_EVENTS;$/d' fs/notify/fdinfo.c
           perl -i -pe 's/\bmask,\s*mark->ignored_mask/inotify_mark_user_mask(mark)/g' fs/notify/fdinfo.c
         fi
 
@@ -180,7 +180,7 @@ runs:
         fi
         if [ "${{ inputs.sublevel }}" -le "117" ]; then
           echo "Reverting fdinfo.c Android 12 5.10 Fake Patch"
-          perl -i -pe 's/^(\s*if \(inode\) \{)/$1\n        \/\*\n         * IN_ALL_EVENTS represents all of the mask bits\n         * that we expose to userspace.  There is at\n         * least one bit (FS_EVENT_ON_CHILD) which is\n         * used only internally to the kernel.\n         *\/\n        u32 mask = mark->mask & IN_ALL_EVENTS;/m' fs/notify/fdinfo.c
+          perl -i -pe 's/^(\s+if \(inode\) \{)/$1\n\t\t\/\*\n\t\t * IN_ALL_EVENTS represents all of the mask bits\n\t\t * that we expose to userspace.  There is at\n\t\t * least one bit (FS_EVENT_ON_CHILD) which is\n\t\t * used only internally to the kernel.\n\t\t *\/\n\t\tu32 mask = mark->mask & IN_ALL_EVENTS;/m' fs/notify/fdinfo.c
           perl -i -pe 's/\binotify_mark_user_mask\(mark\)/mask, mark->ignored_mask/g' fs/notify/fdinfo.c
         fi
 

+ 0 - 33
.github/workflows/manifest-resource-summary.yml

@@ -1,33 +0,0 @@
-name: Manifest Resource Summary
-
-on:
-  workflow_dispatch:
-
-jobs:
-  manifest-summary:
-    runs-on: ubuntu-latest
-    steps:
-      - name: Checkout (for summary upload)
-        uses: actions/checkout@v4
-
-      - name: Install requirements
-        run: sudo apt-get update && sudo apt-get install -y python3 python3-pip
-
-      - name: Download and summarize manifests
-        run: |
-          python3 .github/scripts/manifest_resource_summary.py
-        # No env needed; script discovers manifests from kernel config files
-
-      - name: Upload summary
-        if: always()
-        run: |
-          cat manifest_resource_summary.md
-        shell: bash
-        continue-on-error: true
-        id: summary
-
-      - name: Add summary to GitHub Actions
-        if: always()
-        run: |
-          echo "## Manifest Resource Summary" >> $GITHUB_STEP_SUMMARY
-          cat manifest_resource_summary.md >> $GITHUB_STEP_SUMMARY

+ 1 - 4
.gitignore

@@ -1,4 +1 @@
-OnePlus_KernelSU_SUSFS/
-6.12/
-free-disk-space/
-manifest.yml
+AIO-REJ/

+ 0 - 52
clean_space.sh

@@ -1,52 +0,0 @@
-#!/bin/bash
-# clean_space.sh - Aggressive disk cleanup for CI runners or local use
-# Usage: bash clean_space.sh
-
-set -e
-
-# Remove Android SDKs and packages
-echo "Removing Android SDKs and packages..."
-sudo rm -rf /usr/local/lib/android /opt/android /usr/local/android-sdk /home/runner/Android || true
-ANDROID_PKGS=$(dpkg -l | grep -E "^ii.*(android|adb)" | awk '{print $2}' | tr '\n' ' ')
-if [ -n "$ANDROID_PKGS" ]; then
-  sudo apt-get remove -y $ANDROID_PKGS || true
-  sudo apt-get autoremove -y || true
-  sudo apt-get clean || true
-fi
-
-# Remove .NET SDKs and packages
-echo "Removing .NET SDKs and packages..."
-sudo rm -rf /usr/share/dotnet /usr/share/doc/dotnet-* || true
-DOTNET_PKGS=$(dpkg -l | grep -E "^ii.*dotnet" | awk '{print $2}' | tr '\n' ' ')
-if [ -n "$DOTNET_PKGS" ]; then
-  sudo apt-get remove -y $DOTNET_PKGS || true
-  sudo apt-get autoremove -y || true
-  sudo apt-get clean || true
-fi
-
-# Remove Haskell SDKs and packages
-echo "Removing Haskell SDKs and packages..."
-sudo rm -rf /opt/ghc /usr/local/.ghcup /opt/cabal /home/runner/.ghcup /home/runner/.cabal || true
-HASKELL_PKGS=$(dpkg -l | grep -E "^ii.*(ghc|haskell|cabal)" | awk '{print $2}' | tr '\n' ' ')
-if [ -n "$HASKELL_PKGS" ]; then
-  sudo apt-get remove -y $HASKELL_PKGS || true
-  sudo apt-get autoremove -y || true
-  sudo apt-get clean || true
-fi
-
-# Remove tool cache (set AGENT_TOOLSDIRECTORY if needed)
-if [ -n "$AGENT_TOOLSDIRECTORY" ]; then
-  echo "Removing tool cache at $AGENT_TOOLSDIRECTORY..."
-  sudo rm -rf "$AGENT_TOOLSDIRECTORY" || true
-fi
-
-# Remove swap storage
-echo "Removing swap storage..."
-sudo swapoff -a || true
-sudo rm -f /mnt/swapfile || true
-
-# Remove extra large folders (add your own as needed)
-# Example: sudo rm -rf /path/to/large/folder
-
-# Done
-echo "Disk cleanup complete."