dumper: Randomize Branch Names
(1). This is needed in order to dump custom-roms, as multiple builds of the same device might use the same fingerprint, thus not pushing the firmware, or git notifying to use "-f" flag, which is not what we want. (2). We aren't hosting our dumps on a custom server, so storage isn't much of a headache as of now.
This commit is contained in:
parent
74a85390fb
commit
c78f2a22ee
|
|
@ -985,6 +985,9 @@ repo=$(echo "${brand}"_"${codename}"_dump | tr '[:upper:]' '[:lower:]')
|
|||
platform=$(echo "${platform}" | tr '[:upper:]' '[:lower:]' | tr -dc '[:print:]' | tr '_' '-' | cut -c 1-35)
|
||||
top_codename=$(echo "${codename}" | tr '[:upper:]' '[:lower:]' | tr -dc '[:print:]' | tr '_' '-' | cut -c 1-35)
|
||||
manufacturer=$(echo "${manufacturer}" | tr '[:upper:]' '[:lower:]' | tr -dc '[:print:]' | tr '_' '-' | cut -c 1-35)
|
||||
# Randomize Branch Names: This is needed in order to dump custom-roms, as multiple builds of the same device might use the same fingerprint, thus not pushing the firmware, or git notifying to use "-f" flag, which is not what we want.
|
||||
# We aren't hosting our dumps on a custom server, so storage isn't much of a headache as of now.
|
||||
branch="${branch}""-random-text-""${RANDOM}""${RANDOM}""${RANDOM}"
|
||||
# Repo README File
|
||||
printf "## %s\n- Manufacturer: %s\n- Platform: %s\n- Codename: %s\n- Brand: %s\n- Flavor: %s\n- Release Version: %s\n- Id: %s\n- Incremental: %s\n- Tags: %s\n- CPU Abilist: %s\n- A/B Device: %s\n- Locale: %s\n- Screen Density: %s\n- Fingerprint: %s\n- OTA version: %s\n- Branch: %s\n- Repo: %s\n" "${description}" "${manufacturer}" "${platform}" "${codename}" "${brand}" "${flavor}" "${release}" "${id}" "${incremental}" "${tags}" "${abilist}" "${is_ab}" "${locale}" "${density}" "${fingerprint}" "${otaver}" "${branch}" "${repo}" > "${OUTDIR}"/README.md
|
||||
printf "\n\n>Dumped by [Phoenix Firmware Dumper](https://github.com/DroidDumps/phoenix_firmware_dumper)\n" >> "${OUTDIR}"/README.md
|
||||
|
|
|
|||
Loading…
Reference in New Issue