mirror of
https://github.com/sotam0316/docker-py-revanced.git
synced 2026-04-25 03:48:37 +09:00
🐛 Handle updated patch name
This commit is contained in:
@@ -55,7 +55,7 @@ jobs:
|
|||||||
json_data=$(cat "${path}")
|
json_data=$(cat "${path}")
|
||||||
|
|
||||||
new_object='{
|
new_object='{
|
||||||
"patchName": "Change OAuth client id",
|
"patchName": "Spoof client",
|
||||||
"options": [
|
"options": [
|
||||||
{
|
{
|
||||||
"key": "client-id",
|
"key": "client-id",
|
||||||
@@ -63,8 +63,8 @@ jobs:
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}'
|
}'
|
||||||
# Check if an object with the patchName "Change OAuth client id" already exists
|
# Check if an object with the patchName "Spoof client" already exists
|
||||||
existing_object_index=$(echo "${json_data}" | jq 'map(.patchName) | index("Change OAuth client id")')
|
existing_object_index=$(echo "${json_data}" | jq 'map(.patchName) | index("Spoof client")')
|
||||||
echo "${existing_object_index}"
|
echo "${existing_object_index}"
|
||||||
if [[ ${existing_object_index} != "null" ]]; then
|
if [[ ${existing_object_index} != "null" ]]; then
|
||||||
echo "Patch entry already exists. Overriding client ID in it."
|
echo "Patch entry already exists. Overriding client ID in it."
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
[
|
[
|
||||||
{
|
{
|
||||||
"patchName": "Change OAuth client id",
|
"patchName": "Spoof client",
|
||||||
"options": [
|
"options": [
|
||||||
{
|
{
|
||||||
"key": "client-id",
|
"key": "client-id",
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ path="apks/options.json"
|
|||||||
json_data=$(cat "${path}")
|
json_data=$(cat "${path}")
|
||||||
|
|
||||||
new_object='{
|
new_object='{
|
||||||
"patchName": "Change OAuth client id",
|
"patchName": "Spoof client",
|
||||||
"options": [
|
"options": [
|
||||||
{
|
{
|
||||||
"key": "client-id",
|
"key": "client-id",
|
||||||
@@ -14,8 +14,8 @@ new_object='{
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
}'
|
}'
|
||||||
# Check if an object with the patchName "Change OAuth client id" already exists
|
# Check if an object with the patchName "Spoof client" already exists
|
||||||
existing_object_index=$(echo "${json_data}" | jq 'map(.patchName) | index("Change OAuth client id")')
|
existing_object_index=$(echo "${json_data}" | jq 'map(.patchName) | index("Spoof client")')
|
||||||
echo "${existing_object_index}"
|
echo "${existing_object_index}"
|
||||||
if [[ ${existing_object_index} != "null" ]]; then
|
if [[ ${existing_object_index} != "null" ]]; then
|
||||||
echo "Exist"
|
echo "Exist"
|
||||||
|
|||||||
Reference in New Issue
Block a user