Skip to content

Commit cc59639

Browse files
committed
fix?
1 parent 83e5b90 commit cc59639

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

get-dependencies.sh

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,15 @@ get-debloated-pkgs --add-common --prefer-nano
2424
# Use tessdata_fast script models since they are way lighter than what archlinux provides
2525
echo "Downloading tesseract script models..."
2626
echo "---------------------------------------------------------------"
27-
rm -rf /usr/share/tessdata
28-
git clone --depth 1 https://github.com/tesseract-ocr/tessdata_fast /usr/share/tessdata
29-
rm -rf /usr/share/tessdata/.git
27+
tessdata_dir=/usr/share/tessdata
28+
tessdata_source=https://github.com/tesseract-ocr/tessdata_fast/raw/main
29+
rm -rf "$tessdata_dir"
30+
mkdir -p "$tessdata_dir"
31+
for lang in deu eng fin fra por rus spa; do
32+
echo "Downloading $lang.traineddata"
33+
wget --retry-connrefused --tries=30 "$tessdata_source"/"$lang".traineddata -O "$tessdata_dir"/"$lang".traineddata
34+
done
35+
wget --retry-connrefused --tries=30 "$tessdata_source"/osd.traineddata -O "$tessdata_dir"/osd.traineddata
3036

3137
# if you also have to make nightly releases check for DEVEL_RELEASE = 1
3238
#

0 commit comments

Comments
 (0)