Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ jobs:
- name: Check manifestShield
run: ./gradlew manifestShield

- name: Check proguardShield
run: ./gradlew proguardShieldFast

- name: Check spotless
run: ./gradlew spotlessCheck --init-script gradle/init.gradle.kts --stacktrace

Expand Down
10 changes: 10 additions & 0 deletions CHECK.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@
./gradlew manifestShield
```

- proguardShield
```bash
./gradlew proguardShieldFast
```

- spotless
```bash
./gradlew spotlessCheck --init-script gradle/init.gradle.kts
Expand All @@ -40,6 +45,11 @@
./gradlew manifestShieldBaseline
```

- proguardShield
```bash
./gradlew proguardShieldFastBaseline
```

- spotless
```bash
./gradlew spotlessApply --init-script gradle/init.gradle.kts
Expand Down
5 changes: 5 additions & 0 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ plugins {
id "org.jetbrains.kotlin.plugin.serialization"
alias libs.plugins.dependencyGuard
alias libs.plugins.manifestShield
alias libs.plugins.proguardShield
alias(libs.plugins.baselineprofile)
}

Expand Down Expand Up @@ -141,6 +142,10 @@ manifestShield {
configuration("release")
}

proguardShield {
configuration("release")
}

task applyDependencyBaseline {
dependsOn "dependencyGuardBaseline"
}
451 changes: 451 additions & 0 deletions app/proguardShield/releaseFastRules.txt

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ plugins {
alias(libs.plugins.ksp) apply false
alias(libs.plugins.dependencyGuard) apply false
alias(libs.plugins.manifestShield) apply false
alias(libs.plugins.proguardShield) apply false
alias(libs.plugins.baselineprofile) apply false
}

Expand Down
16 changes: 11 additions & 5 deletions check.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
# Check script for PR submission
# Validates dependencies, merged manifest, code formatting, lint.
# Validates dependencies, merged manifest, ProGuard/R8 rules, code formatting, lint.

# Exit immediately if any command fails
set -e
Expand All @@ -9,25 +9,31 @@ echo "Starting check validations..."
echo ""

# Verify dependency changes
echo "🔍 [1/4] Checking dependency guard..."
echo "🔍 [1/5] Checking dependency guard..."
./gradlew dependencyGuard
echo "✓ Dependency guard check passed"
echo ""

# Verify merged manifest changes
echo "🔍 [2/4] Checking manifest shield..."
echo "🔍 [2/5] Checking manifest shield..."
./gradlew manifestShield
echo "✓ Manifest shield check passed"
echo ""

# Verify ProGuard/R8 rule changes
echo "🔍 [3/5] Checking proguard shield..."
./gradlew proguardShieldFast
echo "✓ ProGuard shield check passed"
echo ""

# Verify code formatting
echo "🔍 [3/4] Checking code formatting..."
echo "🔍 [4/5] Checking code formatting..."
./gradlew spotlessCheck --init-script gradle/init.gradle.kts
echo "✓ Code formatting check passed"
echo ""

# Static analysis and lint checks
echo "🔍 [4/4] Running lint checks..."
echo "🔍 [5/5] Running lint checks..."
./gradlew lintDebug
echo "✓ Lint check passed"
echo ""
Expand Down
2 changes: 2 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ photo-compose = "1.0.1"
coil = "3.3.0"
dependencyGuard = "0.5.0"
manifestShield = "0.1.10"
proguardShield = "0.0.3"
retrofit = "3.0.0"
timber = "5.0.1"

Expand Down Expand Up @@ -151,4 +152,5 @@ compose-compiler = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "
ksp = { id = "com.google.devtools.ksp", version.ref = "ksp" }
dependencyGuard = { id = "com.dropbox.dependency-guard", version.ref = "dependencyGuard" }
manifestShield = { id = "io.github.fornewid.manifest-shield", version.ref = "manifestShield" }
proguardShield = { id = "io.github.fornewid.proguard-shield", version.ref = "proguardShield" }
baselineprofile = { id = "androidx.baselineprofile", version.ref = "androidx-benchmark" }
Loading