mirror of
https://github.com/Jonny007-MKD/OTR-SaneRename
synced 2025-01-22 08:49:48 +01:00
Renamed functions
This commit is contained in:
parent
c2f339fff4
commit
afd75a18db
1 changed files with 15 additions and 15 deletions
|
@ -328,8 +328,8 @@ function funcGetEPG {
|
||||||
}
|
}
|
||||||
|
|
||||||
# Get the title of the episode from description in EPG using $1 as delimiter to the real description
|
# Get the title of the episode from description in EPG using $1 as delimiter to the real description
|
||||||
function funcGetEpgEpisodeTitle {
|
function funcGetEpisodeTitleFromEpg {
|
||||||
if $debug; then echo -e "\033[36mfuncGetEpgEpisodeTitle \"$1\" \"$2\"\033[37m"; fi;
|
if $debug; then echo -e "\033[36mfuncGetEpisodeTitleFromEpg \"$1\" \"$2\"\033[37m"; fi;
|
||||||
local delimiter;
|
local delimiter;
|
||||||
local delimiter2;
|
local delimiter2;
|
||||||
delimiter1="$1"
|
delimiter1="$1"
|
||||||
|
@ -351,8 +351,8 @@ function funcGetEpgEpisodeTitle {
|
||||||
}
|
}
|
||||||
|
|
||||||
# Download episodes list from TvDB, language as argument
|
# Download episodes list from TvDB, language as argument
|
||||||
function funcGetEpisodes {
|
function funcDownloadEpisodesFile {
|
||||||
if $debug; then echo -e "\033[36mfuncGetEpisodes\033[37m"; fi;
|
if $debug; then echo -e "\033[36mfuncDownloadEpisodesFile\033[37m"; fi;
|
||||||
wget_file="$PwD/episodes-${series_id}-${langCurrent}.xml"
|
wget_file="$PwD/episodes-${series_id}-${langCurrent}.xml"
|
||||||
if [ -f "$wget_file" ]; then
|
if [ -f "$wget_file" ]; then
|
||||||
wget_file_date=$(stat --format=%Y "$wget_file")
|
wget_file_date=$(stat --format=%Y "$wget_file")
|
||||||
|
@ -378,8 +378,8 @@ function funcGetEpisodes {
|
||||||
}
|
}
|
||||||
|
|
||||||
# Get the information from episodes list of TvDB
|
# Get the information from episodes list of TvDB
|
||||||
function funcGetEpisodeInfo {
|
function funcGetEpisodeInfoByTitle {
|
||||||
if $debug; then echo -e "\033[36mfuncGetEpisodeInfo\033[37m"; fi;
|
if $debug; then echo -e "\033[36mfuncGetEpisodeInfoByTitle\033[37m"; fi;
|
||||||
local tmp;
|
local tmp;
|
||||||
local title;
|
local title;
|
||||||
local title1;
|
local title1;
|
||||||
|
@ -553,16 +553,16 @@ function doIt {
|
||||||
# Parse the episodes, language as argument
|
# Parse the episodes, language as argument
|
||||||
function doItEpisodes {
|
function doItEpisodes {
|
||||||
if ! $episode_title_set; then
|
if ! $episode_title_set; then
|
||||||
funcGetEpgEpisodeTitle "." # Get the episode title using . as delimiter
|
funcGetEpisodeTitleFromEpg "." # Get the episode title using . as delimiter
|
||||||
fi
|
fi
|
||||||
funcGetEpisodes # Download episodes file
|
funcDownloadEpisodesFile # Download episodes file
|
||||||
if [ -n "$episode_title" ]; then
|
if [ -n "$episode_title" ]; then
|
||||||
funcGetEpisodeInfo
|
funcGetEpisodeInfoByTitle
|
||||||
fi
|
fi
|
||||||
if [ -z "$episode_info" ] && ! $episode_title_set && [[ "$episode_title" == *,* ]]; then # No info found and we are allowed to search and our title contains a ","
|
if [ -z "$episode_info" ] && ! $episode_title_set && [[ "$episode_title" == *,* ]]; then # No info found and we are allowed to search and our title contains a ","
|
||||||
funcGetEpgEpisodeTitle "." "," # Try again with . AND , as delimiter
|
funcGetEpisodeTitleFromEpg "." "," # Try again with . AND , as delimiter
|
||||||
if [ -n "episode_title" ]; then # If we have got an episode title
|
if [ -n "episode_title" ]; then # If we have got an episode title
|
||||||
funcGetEpisodeInfo
|
funcGetEpisodeInfoByTitle
|
||||||
else
|
else
|
||||||
eecho -e " EPG:\tNo episode title found in EPG!"
|
eecho -e " EPG:\tNo episode title found in EPG!"
|
||||||
logNexit 21
|
logNexit 21
|
||||||
|
@ -570,15 +570,15 @@ function doItEpisodes {
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$episode_info" ] && ! $episode_title_set; then # No info found and delimiter , is possible:
|
if [ -z "$episode_info" ] && ! $episode_title_set; then # No info found and delimiter , is possible:
|
||||||
funcGetEpgEpisodeTitle "," # Try again with , as delimiter
|
funcGetEpisodeTitleFromEpg "," # Try again with , as delimiter
|
||||||
if [ -n "episode_title" ]; then # If we have got an episode title
|
if [ -n "episode_title" ]; then # If we have got an episode title
|
||||||
funcGetEpisodeInfo
|
funcGetEpisodeInfoByTitle
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
if [ -z "$episode_info" ] && ! $episode_title_set && [[ "$episode_title" == *.* ]]; then # No info found and our title contains a "."
|
if [ -z "$episode_info" ] && ! $episode_title_set && [[ "$episode_title" == *.* ]]; then # No info found and our title contains a "."
|
||||||
funcGetEpgEpisodeTitle "," "." # Try again with , AND . as delimiter
|
funcGetEpisodeTitleFromEpg "," "." # Try again with , AND . as delimiter
|
||||||
if [ -n "episode_title" ]; then # If we have got an episode title
|
if [ -n "episode_title" ]; then # If we have got an episode title
|
||||||
funcGetEpisodeInfo
|
funcGetEpisodeInfoByTitle
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue