Skip to content

Commit

Permalink
Chore: rename module name & json name
Browse files Browse the repository at this point in the history
  • Loading branch information
Kr328 committed Feb 1, 2022
1 parent 0a275ef commit 86d7435
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/publish-update-json.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,20 +53,22 @@ jobs:
versionCode="$(grep_prop versionCode "$extract_root/module.prop")"
zipUrl="$url"
changelog="${{ github.event.release.html_url }}"
jsonFileName="$(echo -n "$id" | sed "s/_/-/g")"
echo "-------- Module properties --------"
echo "id = $id"
echo "version = $version"
echo "versionCode = $versionCode"
echo "zipUrl = $zipUrl"
echo "changelog = $changelog"
echo "jsonFileName = $jsonFileName"
if [[ -z "$id" || -z "$version" || -z "$versionCode" || -z "$zipUrl" || -z "$changelog" ]]; then
echo "Invalid module.prop"
exit 255
fi
printf '{"version":"%s","versionCode":%d,"zipUrl":"%s","changelog":"%s"}' "$version" "$versionCode" "$zipUrl" "$changelog" > "$publish_root/$id.json"
printf '{"version":"%s","versionCode":%d,"zipUrl":"%s","changelog":"%s"}' "$version" "$versionCode" "$zipUrl" "$changelog" > "$publish_root/$jsonFileName.json"
(( count++ )) || true
done
Expand Down
12 changes: 6 additions & 6 deletions module/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -18,22 +18,22 @@ zygote {

riru {
id = "riru_$moduleId"
name = "Riru - $moduleName"
name = "$moduleName (Riru)"
author = moduleAuthor
description = moduleDescription
entrypoint = moduleEntrypoint
archiveName = "riru-${moduleId.replace('_', '-')}-${android.defaultConfig.versionName}"
updateJson = "https://github.com/Kr328/Riru-ClipboardWhitelist/releases/latest/download/$id.json"
archiveName = "${id.replace('_', '-')}-${android.defaultConfig.versionName}"
updateJson = "https://github.com/Kr328/Riru-ClipboardWhitelist/releases/latest/download/${id.replace('_', '-')}.json"
}

zygisk {
id = "zygisk_$moduleId"
name = "Zygisk - $moduleName"
name = "$moduleName (Zygisk)"
author = moduleAuthor
description = moduleDescription
entrypoint = moduleEntrypoint
archiveName = "zygisk-${moduleId.replace('_', '-')}-${android.defaultConfig.versionName}"
updateJson = "https://github.com/Kr328/Riru-ClipboardWhitelist/releases/latest/download/$id.json"
archiveName = "${id.replace('_', '-')}-${android.defaultConfig.versionName}"
updateJson = "https://github.com/Kr328/Riru-ClipboardWhitelist/releases/latest/download/${id.replace('_', '-')}.json"
}
}

Expand Down

0 comments on commit 86d7435

Please sign in to comment.