Skip to content

Commit c517bc9

Browse files
authored
Initial commit
0 parents  commit c517bc9

File tree

87 files changed

+3098
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

87 files changed

+3098
-0
lines changed

.github/back/build.yml

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
name: Android Build
2+
3+
on:
4+
workflow_dispatch:
5+
# push:
6+
# branches:
7+
# - 'main'
8+
9+
jobs:
10+
build:
11+
name: Build APK
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Checkout Repository
15+
uses: actions/checkout@v4
16+
17+
- name: Set up JDK 17
18+
uses: actions/setup-java@v3
19+
with:
20+
distribution: 'temurin'
21+
java-version: '17'
22+
cache: gradle
23+
24+
- name: Set up Android SDK
25+
uses: android-actions/setup-android@v3
26+
27+
- uses: pnpm/action-setup@v3
28+
with:
29+
version: latest
30+
31+
- name: Sync node version and setup cache
32+
uses: actions/setup-node@v4
33+
with:
34+
node-version: 20
35+
cache: pnpm
36+
37+
- name: Install ImageMagick
38+
run: |
39+
sudo apt-get update
40+
sudo apt-get install imagemagick
41+
convert --version
42+
43+
- name: Init Project Config
44+
run: |
45+
pnpm install
46+
pnpm pp:worker
47+
48+
- name: Grant Execute Permission for Gradle
49+
run: chmod +x ./gradlew
50+
51+
- name: Build Debug APK
52+
run: ./gradlew assembleDebug
53+
54+
- name: Rename APK file
55+
run: |
56+
cd app/build/outputs/apk/debug/
57+
mv app-debug.apk ${{ env.NAME }}-v${{ env.VERSION }}.apk
58+
59+
- name: Create GitHub Release
60+
uses: softprops/action-gh-release@v1
61+
with:
62+
files: app/build/outputs/apk/debug/*.apk
63+
tag_name: '${{ env.NAME }}'
64+
name: '${{ env.NAME }} v${{ env.VERSION }}'
65+
body: '${{ env.PUBBODY }}'
66+
draft: false
67+
env:
68+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
69+
NAME: ${{ env.NAME }}
70+
VERSION: ${{ env.VERSION }}
71+
PUBBODY: ${{ env.PUBBODY }}

.github/back/gitai.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Build unsigned APK
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
pull_request:
8+
9+
jobs:
10+
build:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout code
15+
uses: actions/checkout@v5
16+
17+
- name: Set up JDK 17
18+
uses: actions/setup-java@v4
19+
with:
20+
java-version: '17'
21+
distribution: 'temurin'
22+
23+
- name: Build unsigned APK
24+
run: ./gradlew assembleDebug
25+
26+
- name: Upload APK artifact
27+
uses: actions/upload-artifact@v4
28+
with:
29+
name: app-debug-unsigned-apk
30+
path: app/build/outputs/apk/debug/app-debug.apk

.github/back/release.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
name: Android Build & Release
2+
3+
on:
4+
push:
5+
branches:
6+
- 'main'
7+
8+
jobs:
9+
build:
10+
name: Build APK
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout Repository
14+
uses: actions/checkout@v4
15+
16+
- name: Set up JDK 17
17+
uses: actions/setup-java@v3
18+
with:
19+
distribution: 'temurin'
20+
java-version: '17'
21+
cache: gradle
22+
23+
- name: Set up Android SDK
24+
uses: android-actions/setup-android@v3
25+
26+
- name: Grant Execute Permission for Gradle
27+
run: chmod +x ./gradlew
28+
29+
- name: Build Debug APK (可安装版本)
30+
run: ./gradlew assembleDebug
31+
32+
- name: Create GitHub Release
33+
uses: softprops/action-gh-release@v2
34+
with:
35+
files: app/build/outputs/apk/debug/*.apk
36+
tag_name: 'PakePlus-v0.0.1'
37+
body: 'PakePlus-v0.0.1'
38+
draft: false
39+
prerelease: false
40+
env:
41+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/build.yml

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
name: Android Build
2+
3+
on:
4+
workflow_dispatch:
5+
# push:
6+
# branches:
7+
# - 'main'
8+
9+
permissions:
10+
contents: write
11+
pages: write
12+
id-token: write
13+
14+
jobs:
15+
build:
16+
name: Build APK
17+
runs-on: ubuntu-latest
18+
steps:
19+
- name: Checkout Repository
20+
uses: actions/checkout@v4
21+
22+
- name: Set up JDK 17
23+
uses: actions/setup-java@v3
24+
with:
25+
distribution: 'temurin'
26+
java-version: '17'
27+
cache: gradle
28+
29+
- name: Set up Android SDK
30+
uses: android-actions/setup-android@v3
31+
32+
- uses: pnpm/action-setup@v3
33+
with:
34+
version: latest
35+
36+
- name: Sync node version and setup cache
37+
uses: actions/setup-node@v4
38+
with:
39+
node-version: 20
40+
cache: pnpm
41+
42+
- name: Install ImageMagick
43+
run: |
44+
sudo apt-get update
45+
sudo apt-get install imagemagick
46+
convert --version
47+
48+
- name: Init Project Config
49+
run: |
50+
pnpm install
51+
pnpm pp:worker
52+
53+
- name: Grant Execute Permission for Gradle
54+
run: chmod +x ./gradlew
55+
56+
- name: Build Debug APK
57+
run: ./gradlew assembleDebug
58+
59+
- name: Rename APK file
60+
run: |
61+
cd app/build/outputs/apk/debug/
62+
mv app-debug.apk ${{ env.NAME }}-v${{ env.VERSION }}.apk
63+
64+
- name: Create GitHub Release
65+
uses: softprops/action-gh-release@v1
66+
with:
67+
files: app/build/outputs/apk/debug/*.apk
68+
tag_name: '${{ env.NAME }}'
69+
name: '${{ env.NAME }} v${{ env.VERSION }}'
70+
body: '${{ env.PUBBODY }}'
71+
draft: false
72+
env:
73+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
74+
NAME: ${{ env.NAME }}
75+
VERSION: ${{ env.VERSION }}
76+
PUBBODY: ${{ env.PUBBODY }}

.github/workflows/tips.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# 安装包损坏
2+
因为assembleRelease模式下的apk需要签名才可以使用。
3+
4+
5+
# 签名
6+
在本地生成签名文件:
7+
```agsl
8+
keytool -genkeypair -v \
9+
-keystore release.keystore \
10+
-keyalg RSA -keysize 2048 -validity 10000 \
11+
-alias pakeplus_android
12+
```
13+
keytool是jdk自带的工具,路径在jdk/bin目录下。
14+
15+
16+
17+
# 或者使用assembleDebug

.gitignore

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
*.iml
2+
.gradle
3+
/local.properties
4+
/.idea/caches
5+
/.idea/libraries
6+
/.idea/modules.xml
7+
/.idea/workspace.xml
8+
/.idea/navEditor.xml
9+
/.idea/assetWizardSettings.xml
10+
.DS_Store
11+
/build
12+
/captures
13+
.externalNativeBuild
14+
.cxx
15+
local.properties
16+
/.idea
17+
node_modules
18+
# Built application files
19+
*.apk
20+
*.aar
21+
*.ap_
22+
*.aab
23+
24+
# Files for the ART/Dalvik VM
25+
*.dex
26+
27+
# Java class files
28+
*.class
29+
30+
# Generated files
31+
bin/
32+
gen/
33+
out/
34+
35+
# Gradle files
36+
.gradle/
37+
build/
38+
39+
# Local configuration file (sdk path, etc)
40+
local.properties
41+
42+
# Log Files
43+
*.log
44+
45+
# Android Studio files
46+
.idea/
47+
*.iml
48+
.navigation/
49+
captures/
50+
51+
# Keystore files
52+
*.jks
53+
*.keystore
54+
55+
# External native build folder
56+
.externalNativeBuild/
57+
.cxx/
58+
59+
# Google Services (e.g., Firebase)
60+
google-services.json
61+
62+
# Freeline
63+
freeline.py
64+
freeline/
65+
freeline_project_description.json
66+
67+
# Fastlane
68+
fastlane/report.xml
69+
fastlane/Preview.html
70+
fastlane/screenshots
71+
fastlane/test_output
72+
fastlane/readme.md
73+
74+
# Version control
75+
vcs.xml
76+
77+
# lint
78+
lint/intermediates/
79+
lint/generated/
80+
lint/outputs/
81+
lint/tmp/
82+
# lint/reports/

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2025 1024 小神
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

0 commit comments

Comments
 (0)