This repository has been archived on 2025-05-06. You can view files and clone it, but cannot push or open issues or pull requests.
tools/download-all.sh
Антон Аксенов c3163d683d
Новый скрипт playlists, который выкачивает ini
- playlists вызывается в download-all
- download-all теперь вызывается в начале find-in-all и make-pls
- мелочи по скриптам в целом
2025-03-18 17:05:07 +08:00

32 lines
769 B
Bash
Executable File

#!/bin/bash
#################################################
#
# IPTV Playlist download tool
#
# Usage:
# ./download-all.sh
#
# All playlists from playlists.ini will be
# downloaded in ./downloaded directory
#
# Anthony Axenov (c) 2022
# The MIT License:
# https://git.axenov.dev/IPTV/tools/src/branch/master/LICENSE
#
#################################################
# shellcheck disable=SC2002
./playlists.sh
TOOLS_DIR="$( cd -- "$( dirname -- "${BASH_SOURCE[0]:-$0}"; )" &> /dev/null && pwd 2> /dev/null; )";
DL_DIR="$TOOLS_DIR/downloaded"
INI_FILE="$TOOLS_DIR/playlists.ini"
rm -rf "$DL_DIR" && \
mkdir -p "$DL_DIR" && \
cd "$DL_DIR" && \
grep -oP "(?<=pls=)(.*)" "$INI_FILE" \
| tr -d "'" \
| tr -d '\r' \
| xargs wget