File tree 1 file changed +25
-1
lines changed
src/main/kotlin/app/revanced/cli/command
1 file changed +25
-1
lines changed Original file line number Diff line number Diff line change @@ -90,6 +90,13 @@ internal object PatchCommand : Runnable {
90
90
}
91
91
}
92
92
93
+ @CommandLine(
94
+ names = [" -os" , " --only-sign" ],
95
+ description = [" Only Sign the APK, without doing patches." ],
96
+ showDefaultValue = ALWAYS ,
97
+ )
98
+ private var onlySign: Boolean = false
99
+
93
100
@CommandLine.Option (
94
101
names = [" --exclusive" ],
95
102
description = [" Disable all patches except the ones enabled." ],
@@ -273,7 +280,9 @@ internal object PatchCommand : Runnable {
273
280
null
274
281
}
275
282
276
- // endregion
283
+ if (! onlySign)
284
+ {
285
+ // endregion
277
286
278
287
// region Load patches
279
288
@@ -348,6 +357,21 @@ internal object PatchCommand : Runnable {
348
357
patchedApkFile.copyTo(outputFilePath, overwrite = true )
349
358
}
350
359
}
360
+ }
361
+ else
362
+ {
363
+ ApkUtils .signApk(
364
+ apk,
365
+ outputFilePath,
366
+ signer,
367
+ ApkUtils .KeyStoreDetails (
368
+ keystoreFilePath,
369
+ keyStorePassword,
370
+ keyStoreEntryAlias,
371
+ keyStoreEntryPassword,
372
+ ),
373
+ )
374
+ }
351
375
352
376
logger.info(" Saved to $outputFilePath " )
353
377
You can’t perform that action at this time.
0 commit comments