Skip to content

Commit 9bb950b

Browse files
committed
chore: sync with microG unofficial installer
Signed-off-by: ale5000 <15793015+ale5000-git@users.noreply.github.com>
1 parent f4a1f4c commit 9bb950b

12 files changed

Lines changed: 49 additions & 10 deletions

File tree

.debricked.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
# SPDX-FileCopyrightText: NONE
3+
# SPDX-License-Identifier: CC0-1.0
4+
5+
excluded_directories:
6+
- "zip-content/origin/app"
7+
- "zip-content/origin/priv-app"

.git-hooks/post-checkout.main.sh

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#!/usr/bin/env sh
2+
# SPDX-FileCopyrightText: NONE
3+
# SPDX-License-Identifier: CC0-1.0
4+
5+
#PREVIOUS_REF="${1:?}"
6+
#CURRENT_REF="${2:?}"
7+
CHECKOUT_TYPE="${3:?}"
8+
9+
if test "${CHECKOUT_TYPE:?}" = '1'; then
10+
REMOTE_NAME='origin'
11+
TARGET_TAG='nightly'
12+
LOCAL_HASH="$(git 2> /dev/null rev-parse --verify "refs/tags/${TARGET_TAG:?}")" || LOCAL_HASH=''
13+
14+
if test -n "${LOCAL_HASH?}"; then
15+
REMOTE_HASH="$(git ls-remote "${REMOTE_NAME:?}" "refs/tags/${TARGET_TAG:?}" | cut -f 1 -s)" || REMOTE_HASH=''
16+
17+
if test -n "${REMOTE_HASH?}" && test "${LOCAL_HASH:?}" != "${REMOTE_HASH:?}"; then
18+
git update-ref "refs/tags/${TARGET_TAG:?}" "${REMOTE_HASH:?}" || exit "${?}"
19+
printf '%s\n' "[Hook] Local tag '${TARGET_TAG?}' updated to ${REMOTE_HASH?}"
20+
fi
21+
fi
22+
fi

.github/workflows/auto-nightly.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ jobs:
203203
}).catch(response => response);
204204
if(response && response.status === 200) {
205205
console.log('Nightly tag updated.');
206-
} else if(response && response.status === 422 && response.message === 'Reference does not exist') {
206+
} else if(response?.status === 422 && response?.message?.startsWith('Reference does not exist')) {
207207
const responseCreate = await github.rest.git.createRef({
208208
owner: context.repo.owner,
209209
repo: context.repo.repo,

.github/workflows/code-scan.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -184,6 +184,7 @@ jobs:
184184
uses: github/codeql-action/upload-sarif@v4
185185
if: "${{ github.ref == 'refs/heads/main' }}"
186186
with:
187+
token: "${{ github.token }}"
187188
sarif_file: "results-combined.sarif"
188189
category: "Codacy"
189190

.vscode/settings.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
},
5656
"ruff.lineLength": 80,
5757
"ruff.lint.select": ["ALL"],
58-
"ruff.lint.ignore": ["ANN001", "ANN201", "ANN202", "PTH", "SIM105", "UP009", "UP030", "UP032", "TD002", "TD003"],
58+
"ruff.lint.ignore": ["ANN001", "ANN201", "ANN202", "PTH", "SIM105", "UP009", "UP030", "UP032", "TD002", "TD003", "D212"],
5959
"[python]": {
6060
"editor.rulers": [80, 100, 120],
6161
"editor.defaultFormatter": "charliermarsh.ruff",

build.gradle

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ private Provider<String> getLazyOrg() {
7070

7171
@Memoized
7272
private Provider<String> getLazyLicense() {
73-
moduleProps.map { it.getProperty('license', 'unknown') }
73+
moduleProps.map { it.getProperty('license', 'NOASSERTION') }
7474
}
7575

7676
@Memoized
@@ -87,13 +87,15 @@ private Provider<String> getGitCommitHash() {
8787

8888
providers.exec {
8989
commandLine 'git', 'rev-parse', '--short=8', 'HEAD'
90-
}.standardOutput.asText.map { "g${ it.trim() }" }.orElse('unknown')
90+
}.standardOutput.asText.map { "g${ it.trim() }" }.orElse('UNKNOWN')
9191
}
9292
}
9393

9494
@Memoized
9595
private Provider<String> getMavenVersion() {
96-
ext.lazyVersion.map { it.endsWith('-alpha') ? "${it}-SNAPSHOT" : it }
96+
ext.lazyVersion.flatMap { v ->
97+
v.endsWith('-alpha') ? getGitCommitHash().map { "${v}-${it}-SNAPSHOT" } : providers.provider { v }
98+
}
9799
}
98100

99101
private Provider<String> getZipName(String variant = '*') {

build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,7 @@ run_hook 'pre_package'
359359
# Note: Unicode filenames in the zip are disabled since we don't need them and also zipsigner.jar chokes on them
360360
cd "${TEMP_DIR}/zip-content" || ui_error 'Failed to change the folder' "${LINENO-}" "${FUNCNAME-}"
361361
echo 'Zipping...'
362-
find . -type f | LC_ALL=C sort | zip -D -9 -X -UN=n -nw "${TEMP_DIR}/flashable${FILENAME_EXT:?}" -@ || ui_error 'Failed compressing' "${LINENO-}" "${FUNCNAME-}"
362+
find . -type f | LC_ALL='C.UTF-8' sort | zip -D -9 -X -UN=n -nw "${TEMP_DIR}/flashable${FILENAME_EXT:?}" -@ || ui_error 'Failed compressing' "${LINENO-}" "${FUNCNAME-}"
363363
FILENAME="${FILENAME:?}-signed"
364364

365365
# [HOOK] post_package: Triggered after compression, but before signing

lib/main.lib.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@ if test "${A5K_FUNCTIONS_INCLUDED:-false}" = 'false'; then readonly A5K_FUNCTION
1212
readonly LIB_FILENAME="${USING_LIB:?}"
1313
unset USING_LIB
1414

15-
export LANG='en_US.UTF-8'
16-
export TZ='UTC'
15+
export LANG="${LANG:-"en_US.UTF-8"}"
1716

1817
unset LANGUAGE
1918
unset UNZIP

set-git-local-config.sh

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,15 @@ printf '\n'
8282

8383
test -d "${PWD:?}/.git-hooks"
8484
config_var core.hooksPath '.git-hooks' "${?}" || STATUS="${?}"
85-
HOME="${USER_HOME:-${HOME:?}}" git lfs install --local || STATUS="${?}"
85+
HOME="${USER_HOME:-${HOME:?}}" git lfs install --local --force || STATUS="${?}"
86+
87+
# shellcheck disable=SC2016 # Ignore: Expressions don't expand in single quotes, use double quotes for that
88+
{
89+
printf '\n%s\n' '# BEGIN CUSTOM'
90+
printf '%s\n' 'HOOKS_DIR="$(dirname "${0:?}")" || exit 2'
91+
printf '%s\n' 'if test -f "${HOOKS_DIR:?}/post-checkout.main.sh"; then . "${HOOKS_DIR:?}/post-checkout.main.sh" || exit 2; fi'
92+
printf '%s\n' '# END CUSTOM'
93+
} 1>> "${PWD:?}/.git-hooks/post-checkout"
8694

8795
printf '\n'
8896

tools/README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ TOOLS
99

1010
- zipsigner_ **3.0** => zipsigner.jar
1111
- zipsigner_ **3.0** (Dalvik) => zipsigner-dvk.jar
12-
- `BusyBox for Windows`_ **1.38.0-PRE-6047-g8d97f4176 (2026-03-21)** (w build) => win/busybox.exe
12+
- `BusyBox for Windows`_ **1.38.0-PRE-6084-ge6c716317 (2026-05-17)** (w build) => win/busybox.exe
1313
- `BusyBox legacy for Windows`_ **1.21.0-TIG-931-g7e6a84d (2012-11-29)** => win/busybox-legacy.bin
1414
- Zip_ **3.0** => win/zip.exe
1515
- UnZip_ **6.0** => win/unzip.exe

0 commit comments

Comments
 (0)