Skip to content

Commit 3e506e7

Browse files
chore: move external utils to 'external/'
Change-Id: If0b2435879f198c4adffd1f547ea7b633769ba93
1 parent 3745ff0 commit 3e506e7

File tree

2 files changed

+12
-17
lines changed

2 files changed

+12
-17
lines changed

.gitignore

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,4 @@
11
.githubtoken
22
.tgtoken
3-
.venv
4-
extract-dtb/
5-
extract-ikconfig
6-
Firmware_extractor/
7-
mkbootimg_tools/
8-
TWRP-device-tree-generator/
9-
vmlinux-to-elf/
103
working/
4+
external/

dumpyara.sh

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -135,27 +135,28 @@ if [[ -d "${INPUT}" ]]; then
135135
fi
136136

137137
# clone other repo's
138-
if [[ -d "${PWD}/Firmware_extractor" ]]; then
139-
git -C "${PWD}"/Firmware_extractor pull --recurse-submodules --rebase
138+
if [[ -d "${PWD}/external/Firmware_extractor" ]]; then
139+
git -C "${PWD}"/external/Firmware_extractor pull --recurse-submodules --rebase
140140
else
141-
git clone -q --recurse-submodules https://github.com/AndroidDumps/Firmware_extractor "${PWD}"/Firmware_extractor
141+
LOGI "Cloning 'Fimrware_extractor' to 'external/'..."
142+
git clone -q --recurse-submodules https://github.com/AndroidDumps/Firmware_extractor "${PWD}"/external/Firmware_extractor
142143
fi
143144

144145
# Extract input via 'Firmware_extractor'
145146
[[ ! -d "${INPUT}" ]] && \
146-
bash "$PWD"/Firmware_extractor/extractor.sh "${INPUT}" "${WORKING}" || LOGF "Extraction failed. Aborting."
147+
bash "$PWD"/external/Firmware_extractor/extractor.sh "${INPUT}" "${WORKING}" || LOGF "Extraction failed. Aborting."
147148

148149
# Retrive 'extract-ikconfig' from torvalds/linux
149-
if ! [[ -f "${PWD}"/extract-ikconfig ]]; then
150-
curl -s -Lo "${PWD}"/extract-ikconfig https://raw.githubusercontent.com/torvalds/linux/refs/heads/master/scripts/extract-ikconfig
151-
chmod +x "${PWD}"/extract-ikconfig
150+
if ! [[ -f "${PWD}"/external/extract-ikconfig ]]; then
151+
curl -s -Lo "${PWD}"/external/extract-ikconfig https://raw.githubusercontent.com/torvalds/linux/refs/heads/master/scripts/extract-ikconfig
152+
chmod +x "${PWD}"/external/extract-ikconfig
152153
fi
153154

154155
# Set path for tools
155-
UNPACKBOOTIMG="${PWD}"/Firmware_extractor/tools/unpackbootimg
156+
UNPACKBOOTIMG="${PWD}"/external/Firmware_extractor/tools/unpackbootimg
156157
VMLINUX_TO_ELF="uvx -q --from git+https://github.com/marin-m/vmlinux-to-elf@da14e789596d493f305688e221e9e34ebf63cbb8"
157-
EXTRACT_IKCONFIG="${PWD}"/extract-ikconfig
158-
FSCK_EROFS="${PWD}"/Firmware_extractor/tools/fsck.erofs
158+
EXTRACT_IKCONFIG="${PWD}"/external/extract-ikconfig
159+
FSCK_EROFS="${PWD}"/external/Firmware_extractor/tools/fsck.erofs
159160

160161
# Initialize images extraction
161162
cd "${WORKING}" || exit

0 commit comments

Comments
 (0)