-
Notifications
You must be signed in to change notification settings - Fork 0
Main #34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Main #34
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
63 changes: 63 additions & 0 deletions
63
-name *concept* -o -name *build* -o -name *app* -o -name *.md
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,63 @@ | ||
| [33mcommit 04975261a2b7e9f12c49c6c683a6f1b028d665ac[m[33m ([m[1;36mHEAD[m[33m -> [m[1;32mmain[m[33m, [m[1;31morigin/main[m[33m, [m[1;31morigin/HEAD[m[33m)[m | ||
| Author: yve-android <yvonne26sa90@gmail.com> | ||
| Date: Wed Dec 31 10:02:22 2025 +0100 | ||
|
|
||
| Fix: Pin actions to commit SHA | ||
|
|
||
| [33mcommit 7a98bc2688df9966cd75c3682f3342d90b44ac64[m | ||
| Author: yve-android <yvonne26sa90@gmail.com> | ||
| Date: Tue Dec 30 11:05:01 2025 +0100 | ||
|
|
||
| tools: add GitHub Actions compliance fixer | ||
|
|
||
| [33mcommit 9d34cbf299295fb3e0467ab36c0deb9063851457[m | ||
| Author: yve-android <yvonne26sa90@gmail.com> | ||
| Date: Tue Dec 30 10:35:49 2025 +0100 | ||
|
|
||
| Fix: Pin actions to commit SHA | ||
|
|
||
| [33mcommit fcf8feee6561f7fda6ee63943caa44acbf8235f1[m | ||
| Author: Yve-android <yvonne26sa90@gmail.com> | ||
| Date: Mon Dec 29 01:11:59 2025 +0100 | ||
|
|
||
| Create codeql.yml | ||
|
|
||
| [33mcommit 680a047672d79ea8f923905196f2806bed8f14bb[m | ||
| Merge: 741e49e 9bd8483 | ||
| Author: Yve-android <yvonne26sa90@gmail.com> | ||
| Date: Sun Dec 28 23:44:52 2025 +0100 | ||
|
|
||
| Potential fix for code scanning alert no. 1: Workflow does not contain permissions (#30) | ||
|
|
||
| Potential fix for | ||
| [https://github.com/yve-android/blacky/security/code-scanning/1](https://github.com/yve-android/blacky/security/code-scanning/1) | ||
|
|
||
| In general, fix this by adding an explicit `permissions:` block that | ||
| grants only the minimal scopes needed. Since this workflow only needs to | ||
| read repository contents (for `actions/checkout`) and upload an artifact | ||
| (which does not require repository write access), `contents: read` is | ||
| sufficient. | ||
|
|
||
| The best single fix without changing functionality is to add a | ||
| workflow-level `permissions:` block near the top of | ||
| `.github/workflows/build-apk.yml`, so it applies to all jobs. Place it | ||
| after the `name:` (line 1) and before `on:` (line 3), with: | ||
|
|
||
| ```yaml | ||
| permissions: | ||
| contents: read | ||
| ``` | ||
|
|
||
| No additional imports, methods, or definitions are needed because this | ||
| is purely a YAML configuration change within the workflow file. | ||
|
|
||
|
|
||
| _Suggested fixes powered by Copilot Autofix. Review carefully before | ||
| merging._ | ||
|
|
||
| [33mcommit 9bd84833464685f7b911eac0752f3bddb5d4cba5[m | ||
| Merge: d1f07bf 741e49e | ||
| Author: Yve-android <yvonne26sa90@gmail.com> | ||
| Date: Sun Dec 28 23:44:43 2025 +0100 | ||
|
|
||
| Merge branch 'blacky' into alert-autofix-1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| name: Build Blacky APK | ||
|
|
||
| on: | ||
| push: | ||
| branches: [ main, blacky ] | ||
| pull_request: | ||
| branches: [ main, blacky ] | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - name: Checkout Code | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - name: Set up JDK 17 | ||
| uses: actions/setup-java@v4 | ||
| with: | ||
| java-version: '17' | ||
| distribution: 'temurin' | ||
| cache: gradle | ||
|
|
||
| - name: Grant execute permission for gradlew | ||
| run: chmod +x gradlew | ||
|
|
||
| - name: Cache Gradle packages | ||
| uses: actions/cache@v3 | ||
| with: | ||
| path: | | ||
| ~/.gradle/caches | ||
| ~/.gradle/wrapper | ||
| key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }} | ||
| restore-keys: | | ||
| ${{ runner.os }}-gradle- | ||
|
|
||
| - name: Build with Gradle | ||
| run: ./gradlew assembleDebug --stacktrace --no-daemon | ||
|
|
||
| - name: Upload APK | ||
| uses: actions/upload-artifact@v3 | ||
| if: success() | ||
| with: | ||
| name: blacky-apk | ||
| path: app/build/outputs/apk/debug/*.apk | ||
| retention-days: 30 | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,23 @@ | ||
| # Android Studio | ||
| *.iml | ||
| .gradle | ||
| /local.properties | ||
| /.idea | ||
| .DS_Store | ||
| /build | ||
| /captures | ||
| .externalNativeBuild | ||
| .cxx | ||
| *.apk | ||
| *.ap_ | ||
| *.dex | ||
|
|
||
| # Gradle | ||
| .gradle/ | ||
| build/ | ||
|
|
||
| # Local configuration | ||
| local.properties | ||
|
|
||
| # Log Files | ||
| *.log |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
Copilot Autofix
AI about 1 month ago
To fix the problem, explicitly define a
permissionsblock so that theGITHUB_TOKENused in this workflow has only the minimal required scope. For this workflow, the steps useactions/checkout(which needs read access to repository contents) andactions/upload-artifact(which does not require repo permissions). No write operations to the repo are present, socontents: readis sufficient.The best way to fix this without changing functionality is to add a job-level
permissionsblock underjobs.build, alongsideruns-on. This scopes the permissions only to this job and avoids affecting any other jobs that might exist in this workflow file. Specifically, in.github/workflows/build.yml, add:directly under
runs-on: ubuntu-latest(line 12), with correct indentation. No additional imports or methods are required, as this is purely a YAML configuration change.