forked from libyal/libbde
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsynctestdata.sh
executable file
·30 lines (23 loc) · 935 Bytes
/
synctestdata.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/bin/sh
# Script that synchronizes the local test data
#
# Version: 20231001
TEST_SET="public";
TEST_INPUT_DIRECTORY="tests/input";
TEST_FILES="bdetogo.raw";
mkdir -p "${TEST_INPUT_DIRECTORY}/${TEST_SET}";
mkdir -p "${TEST_INPUT_DIRECTORY}/.libbde/${TEST_SET}";
mkdir -p "${TEST_INPUT_DIRECTORY}/.pybde/${TEST_SET}";
mkdir -p "${TEST_INPUT_DIRECTORY}/.bdeinfo/${TEST_SET}";
cat > test_data_options << EOT
# libyal test data options
password=bde-TEST
EOT
for TEST_FILE in ${TEST_FILES};
do
URL="https://github.com/log2timeline/dfvfs/blob/main/test_data/${TEST_FILE}?raw=true";
curl -L -o "${TEST_INPUT_DIRECTORY}/${TEST_SET}/${TEST_FILE}" ${URL};
cp test_data_options "${TEST_INPUT_DIRECTORY}/.libbde/${TEST_SET}/${TEST_FILE}.password";
cp test_data_options "${TEST_INPUT_DIRECTORY}/.pybde/${TEST_SET}/${TEST_FILE}.password";
cp test_data_options "${TEST_INPUT_DIRECTORY}/.bdeinfo/${TEST_SET}/${TEST_FILE}.password";
done