OTA:Add support for poco x3 and redmi note 7
Signed-off-by: Hưng Phan <phandinhhungvp2001@gmail.com>
This commit is contained in:
29
builds/lavender.json
Normal file
29
builds/lavender.json
Normal file
@@ -0,0 +1,29 @@
|
||||
|
||||
{
|
||||
"response": [
|
||||
{
|
||||
"maintainer": "Moonitime",
|
||||
"oem": "Redmi",
|
||||
"device": "Redmi Note 7/7S",
|
||||
"filename": "Cherish-OS-v3.9.5-20220802-1645-lavender-OFFICIAL-GApps.zip",
|
||||
"download": "https://sourceforge.net/projects/cherish-os/files/device/lavender/Cherish-OS-v3.9.5-20220802-1824-lavender-OFFICIAL-GApps.zip/download",
|
||||
"timestamp": 1659326472,
|
||||
"md5": "1e8486ccc68b1e60e6d18e3b0a2b8026",
|
||||
"sha256": "fd86338be87f70efdd6792b2de3dc3d4ae76d45f",
|
||||
"size": 1817920926,
|
||||
"version": 3.9.5,
|
||||
"buildtype": "Active Development Releases",
|
||||
"forum": "https://t.me/cherishOS",
|
||||
"gapps": "",
|
||||
"firmware": "",
|
||||
"modem": "",
|
||||
"bootloader": "",
|
||||
"recovery": "",
|
||||
"paypal": "https://www.paypal.me/hungphan2001",
|
||||
"telegram": "https://t.me/CherishOS",
|
||||
"dt": "",
|
||||
"common-dt": "",
|
||||
"kernel": ""
|
||||
}
|
||||
]
|
||||
}
|
||||
29
builds/surya.json
Normal file
29
builds/surya.json
Normal file
@@ -0,0 +1,29 @@
|
||||
|
||||
{
|
||||
"response": [
|
||||
{
|
||||
"maintainer": "Pranjal Singh",
|
||||
"oem": "Poco",
|
||||
"device": "Poco X3",
|
||||
"filename": "Cherish-OS-v3.9.5-20220802-1645-surya-OFFICIAL-GApps.zip",
|
||||
"download": "https://sourceforge.net/projects/cherish-os/files/device/surya/Cherish-OS-v3.9.5-20220802-1824-surya-OFFICIAL-GApps.zip/download",
|
||||
"timestamp": 1659326472,
|
||||
"md5": "1e8486ccc68b1e60e6d18e3b0a2b8026",
|
||||
"sha256": "fd86338be87f70efdd6792b2de3dc3d4ae76d45f",
|
||||
"size": 1817920926,
|
||||
"version": 3.9.5,
|
||||
"buildtype": "Active Development Releases",
|
||||
"forum": "https://t.me/cherishOS",
|
||||
"gapps": "",
|
||||
"firmware": "",
|
||||
"modem": "",
|
||||
"bootloader": "",
|
||||
"recovery": "",
|
||||
"paypal": "https://www.paypal.me/hungphan2001",
|
||||
"telegram": "https://t.me/CherishOS",
|
||||
"dt": "",
|
||||
"common-dt": "",
|
||||
"kernel": ""
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1,2 +1,2 @@
|
||||
v3.9//
|
||||
v3.9.5//
|
||||
Initial Official Release!
|
||||
@@ -1,2 +1,2 @@
|
||||
v3.9//
|
||||
v3.9.5//
|
||||
Initial Official Release!
|
||||
@@ -1,35 +0,0 @@
|
||||
DEVICE=$1
|
||||
ROMDIR=~/$2
|
||||
MAINTAINER=$3
|
||||
MAINTAINER_URL=$4
|
||||
FORUM_URL=$5
|
||||
|
||||
# Ensures that mandatory parameters are entered
|
||||
if [ $# -lt 5 ]; then
|
||||
echo "Missing mandatory parameters"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
cd $ROMDIR
|
||||
DATETIME=$(grep "ro.cherish.build_date_utc=" out/target/product/$DEVICE/system/build.prop | cut -d "=" -f 2)
|
||||
FILENAME=$(find out/target/product/$DEVICE/Cherish*.zip | cut -d "/" -f 5)
|
||||
ID=$(md5sum out/target/product/$DEVICE/Cherish*.zip | cut -d " " -f 1)
|
||||
FILEHASH=$ID
|
||||
SIZE=$(wc -c out/target/product/$DEVICE/Cherish*.zip | awk '{print $1}')
|
||||
URL="https://sourceforge.net/projects/cherish-os/files/device/$DEVICE/$FILENAME/download"
|
||||
VERSION="11"
|
||||
DONATE_URL="https://www.paypal.me/hungphan2001"
|
||||
WEBSITE_URL="https://cherishos.com"
|
||||
NEWS_URL="https:\/\/t.me\/CherishOS"
|
||||
JSON_FMT='{\n"error":false,\n"filename": %s,\n"datetime": %s,\n"size":%s, \n"url":"%s", \n"filehash":"%s", \n"version": "%s", \n"id": "%s",\n"donate_url": "%s",\n"website_url":"%s",\n"news_url":"%s",\n"maintainer":"%s",\n"maintainer_url":"%s",\n"forum_url":"%s"\n}'
|
||||
printf "$JSON_FMT" "$FILENAME" "$DATETIME" "$SIZE" "$URL" "$FILEHASH" "$VERSION" "$ID" "$DONATE_URL" "$WEBSITE_URL" "$NEWS_URL" "$MAINTAINER" "$MAINTAINER_URL" "$FORUM_URL" > $ROMDIR/OTA/builds/$DEVICE.json
|
||||
echo $ROMDIR/OTA/builds/$DEVICE.json file created
|
||||
|
||||
BUILD_DATE=$(echo $FILENAME | cut -d "-" -f 3)
|
||||
BUILD_YEAR=${BUILD_DATE:0:4}
|
||||
BUILD_MONTH=${BUILD_DATE:4:2}
|
||||
BUILD_DAY=${BUILD_DATE:6:2}
|
||||
CHANGELOG_DATE=$(echo $BUILD_YEAR/$BUILD_MONTH/$BUILD_DAY)
|
||||
CHANGELOG="Changelog - %s\n\n"
|
||||
printf "$CHANGELOG_DATE" > $ROMDIR/OTA/changelogs/$FILENAME.txt
|
||||
echo $ROMDIR/OTA/changelog/$FILENAME.txt file created
|
||||
Reference in New Issue
Block a user