fix update-config

This commit is contained in:
j-hc 2023-10-15 15:00:29 +03:00
parent 24ab830bf8
commit a340fb89d7
No known key found for this signature in database
GPG Key ID: B69B8F690911EFCC
4 changed files with 17 additions and 8 deletions

View File

@ -18,6 +18,7 @@ parallel-jobs = 1 # amount of cores to use for parallel patching, if not set npr
patches-source = "revanced/revanced-patches" # where to fetch patches bundle from. default: "revanced/revanced-patches" patches-source = "revanced/revanced-patches" # where to fetch patches bundle from. default: "revanced/revanced-patches"
integrations-source = "revanced/revanced-integrations" # where to fetch integrations from. default: "revanced/revanced-integrations" integrations-source = "revanced/revanced-integrations" # where to fetch integrations from. default: "revanced/revanced-integrations"
cli-source = "j-hc/revanced-cli" # where to fetch cli from. default: "j-hc/revanced-cli" cli-source = "j-hc/revanced-cli" # where to fetch cli from. default: "j-hc/revanced-cli"
# options like cli-source can also set per app
rv-brand = "ReVanced Extended" # rebrand from 'ReVanced' to something different. default: "ReVanced" rv-brand = "ReVanced Extended" # rebrand from 'ReVanced' to something different. default: "ReVanced"
patches-version = "v2.160.0" # locks the patches version. default: latest available patches-version = "v2.160.0" # locks the patches version. default: latest available
@ -31,8 +32,8 @@ version = "auto" # 'auto', 'latest', 'beta' or a custom one e.g. '17.40.41'. def
# 'latest' gets the latest stable without checking patches support. 'beta' gets the latest beta/alpha # 'latest' gets the latest stable without checking patches support. 'beta' gets the latest beta/alpha
include-stock = true # includes stock apk in the module. default: true include-stock = true # includes stock apk in the module. default: true
build-mode = "apk" # 'both', 'apk' or 'module'. default: apk build-mode = "apk" # 'both', 'apk' or 'module'. default: apk
excluded-patches = "some-patch some-other-patch" # whitespace seperated list of patches to exclude. default: "" (empty) excluded-patches = "'Some Patch' 'Some Other Patch'" # whitespace seperated list of patches to exclude. default: "" (empty)
included-patches = "patch-name" # whitespace seperated list of patches to include, all default patches are included by default. default: "" (empty) included-patches = "'Patch something'" # whitespace seperated list of patches to include, all default patches are included by default. default: "" (empty)
exclusive-patches = false # exclude all patches by default. default: false exclusive-patches = false # exclude all patches by default. default: false
apkmirror-dlurl = "https://www.apkmirror.com/apk/inc/app" apkmirror-dlurl = "https://www.apkmirror.com/apk/inc/app"
uptodown-dlurl = "https://spotify.en.uptodown.com/android" uptodown-dlurl = "https://spotify.en.uptodown.com/android"
@ -41,5 +42,4 @@ module-prop-name = "some-app-magisk" # magisk module prop name.
merge-integrations = false # set false to never merge even when needed. default: true merge-integrations = false # set false to never merge even when needed. default: true
apkmirror-dpi = "360-480dpi" # used to select apk variant from apkmirror. default: nodpi apkmirror-dpi = "360-480dpi" # used to select apk variant from apkmirror. default: nodpi
apkmirror-arch = "arm64-v8a" # 'arm64-v8a', 'arm-v7a', 'universal', 'both'. 'both' downloads both arm64-v8a and arm-v7a. default: universal apkmirror-arch = "arm64-v8a" # 'arm64-v8a', 'arm-v7a', 'universal', 'both'. 'both' downloads both arm64-v8a and arm-v7a. default: universal
# arch option is only for downloading from apkmirror and does not affect anything else.
``` ```

View File

@ -31,6 +31,8 @@ if [ "${2:-}" = "--config-update" ]; then
config_update config_update
exit 0 exit 0
fi fi
PREV_BUILDMD=$(cat build.md) || PREV_BUILDMD=""
: >build.md : >build.md
ENABLE_MAGISK_UPDATE=$(toml_get "$main_config_t" enable-magisk-update) || ENABLE_MAGISK_UPDATE=true ENABLE_MAGISK_UPDATE=$(toml_get "$main_config_t" enable-magisk-update) || ENABLE_MAGISK_UPDATE=true
if [ "$ENABLE_MAGISK_UPDATE" = true ] && [ -z "${GITHUB_REPOSITORY:-}" ]; then if [ "$ENABLE_MAGISK_UPDATE" = true ] && [ -z "${GITHUB_REPOSITORY:-}" ]; then
@ -189,4 +191,10 @@ log "\n[revanced-magisk-module](https://github.com/j-hc/revanced-magisk-module)"
log "\nChangelog:" log "\nChangelog:"
log "$(cat $TEMP_DIR/*-rv/changelog.md)" log "$(cat $TEMP_DIR/*-rv/changelog.md)"
SKIPPED=$(grep -F "Patches: " <<<"$PREV_BUILDMD" | grep -vE "$(grep -F "Patches: " build.md | cut -d/ -f1 | sed 's/ //g' | paste -sd '~' | sed 's;~;|;g')" || :)
if [ -n "$SKIPPED" ]; then
log "\nSkipped:"
log "$SKIPPED"
fi
pr "Done" pr "Done"

View File

@ -4,11 +4,13 @@ enable-magisk-update = true # set this to false if you do not want to receive
# add 'enabled = false' for not patching a specific app or remove it from the config # add 'enabled = false' for not patching a specific app or remove it from the config
# see https://github.com/j-hc/revanced-magisk-module/blob/main/CONFIG.md for more detailed explanations # see https://github.com/j-hc/revanced-magisk-module/blob/main/CONFIG.md for more detailed explanations
# you can use rvmm-config-gen to generate a config
[YouTube] [YouTube]
build-mode = "both" # 'both', 'apk' or 'module' build-mode = "both"
excluded-patches = "" # space-seperated patches to exclude (multiline strings are not supported) excluded-patches = ""
included-patches = "" # space-seperated patches to include (non-excluded patches are included by default) included-patches = ""
version = "auto" # 'auto', 'latest', 'beta' or a custom one like '17.40.41' version = "auto"
archive-dlurl = "https://archive.org/download/jhc-apks/apks/com.google.android.youtube" archive-dlurl = "https://archive.org/download/jhc-apks/apks/com.google.android.youtube"
[Music-Extended] [Music-Extended]

View File

@ -3,7 +3,6 @@
MODULE_TEMPLATE_DIR="revanced-magisk" MODULE_TEMPLATE_DIR="revanced-magisk"
TEMP_DIR="temp" TEMP_DIR="temp"
BUILD_DIR="build" BUILD_DIR="build"
# PKGS_LIST="${TEMP_DIR}/module-pkgs"
if [ "${GITHUB_TOKEN:-}" ]; then GH_HEADER="Authorization: token ${GITHUB_TOKEN}"; else GH_HEADER=; fi if [ "${GITHUB_TOKEN:-}" ]; then GH_HEADER="Authorization: token ${GITHUB_TOKEN}"; else GH_HEADER=; fi
NEXT_VER_CODE=${NEXT_VER_CODE:-$(date +'%Y%m%d')} NEXT_VER_CODE=${NEXT_VER_CODE:-$(date +'%Y%m%d')}