diff --git a/Tubio/DownloadManager.cpp b/Tubio/DownloadManager.cpp index 4613a17..6b5678a 100644 --- a/Tubio/DownloadManager.cpp +++ b/Tubio/DownloadManager.cpp @@ -709,7 +709,7 @@ void DownloadManager::WarnIfMissingDependenciesWIN() #ifdef _WIN if (!FileSystem::Exists("yt-dlp.exe")) { - log->cout << log->Warn() << "Dependency yt-dlp.exe missing! Try updating it! (\"request\": \"update_dep_youtubedl\"). " + log->cout << log->Warn() << "Dependency yt-dlp.exe missing! Try updating it! (\"request\": \"update_dep_YtDlp\"). " << "Dependencies HAVE to lie in Tubios working directory! (where the config.json is)"; log->Flush(); } diff --git a/Tubio/DownloadManager.h b/Tubio/DownloadManager.h index 9f1b033..c1aa9d6 100644 --- a/Tubio/DownloadManager.h +++ b/Tubio/DownloadManager.h @@ -135,10 +135,10 @@ namespace Downloader static std::vector ParseJsonArrayToEntries(const JasonPP::JsonArray& arr); /// - /// Will return a youtube-dl quality string based on 'quality' + /// Will return a yt-dlp quality string based on 'quality' /// /// The download quality to get the parameter from - /// The youtube-dl quality parameter + /// The yt-dlp quality parameter static std::string DownloadQualityToStringParams(DOWNLOAD_QUALITY quality); /// diff --git a/Tubio/RestQueryHandler.cpp b/Tubio/RestQueryHandler.cpp index 8b2d3e4..65b7cda 100644 --- a/Tubio/RestQueryHandler.cpp +++ b/Tubio/RestQueryHandler.cpp @@ -41,7 +41,7 @@ bool RestQueryHandler::ProcessQuery(const std::string clientAdress, const Json& else if (requestName == "get_os_name") return GetOSName(requestBody, responseBody, responseCode); else if (requestName == "fetch_session_logs") return FetchSessionLogs(requestBody, responseBody, responseCode); else if (requestName == "fetch_alltime_logs") return FetchAlltimeLogs(requestBody, responseBody, responseCode); - else if (requestName == "update_dep_youtubedl") return UpdateYoutubeDL(requestBody, responseBody, responseCode); + else if (requestName == "update_dep_yt-dlp") return UpdateYtDlp(requestBody, responseBody, responseCode); else if (requestName == "remove_download_entry") return RemoveDownloadEntry(requestBody, responseBody, responseCode); else if (requestName == "update_config") return UpdateConfig(requestBody, responseBody, responseCode); else if (requestName == "reset_config_to_default_values") return ResetConfigDefaults(requestBody, responseBody, responseCode); @@ -370,9 +370,9 @@ bool RestQueryHandler::GetDiskUsage(const JsonBlock& request, JsonBlock& respons { dependencies += FileSystem::CalculateSize("ffplay.exe"); } - if (FileSystem::Exists("youtube-dl.exe")) + if (FileSystem::Exists("yt-dlp.exe")) { - dependencies += FileSystem::CalculateSize("youtube-dl.exe"); + dependencies += FileSystem::CalculateSize("yt-dlp.exe"); } diskUsages.Set("dependencies") = dependencies; @@ -397,12 +397,12 @@ bool RestQueryHandler::ClearLogs(const JsonBlock& request, JsonBlock& responseBo return true; } -bool RestQueryHandler::UpdateYoutubeDL(const JsonBlock& request, JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode) +bool RestQueryHandler::UpdateYtDlp(const JsonBlock& request, JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode) { - log->cout << "Updating youtube-dl..."; + log->cout << "Updating yt-dlp..."; log->Flush(); - std::string result = Updater::UpdateYoutubeDL(); + std::string result = Updater::UpdateYtDlp(); if (result == "OK") { log->cout << " => OK!"; @@ -410,7 +410,7 @@ bool RestQueryHandler::UpdateYoutubeDL(const JsonBlock& request, JsonBlock& resp responseCode = HTTP_STATUS_CODE::OK; responseBody.CloneFrom(RestResponseTemplates::GetByCode(HTTP_STATUS_CODE::OK)); - responseBody.Set("message") = "Updated youtube-dl.exe successfully!"; + responseBody.Set("message") = "Updated yt-dlp.exe successfully!"; } else if (result == "not implemented") { @@ -420,7 +420,7 @@ bool RestQueryHandler::UpdateYoutubeDL(const JsonBlock& request, JsonBlock& resp log->Flush(); responseCode = HTTP_STATUS_CODE::NOT_IMPLEMENTED; responseBody.CloneFrom(RestResponseTemplates::GetByCode(HTTP_STATUS_CODE::NOT_IMPLEMENTED)); - responseBody.Set("message") = "On linux you have to update youtube-dl yourself since it is a system-wide package handled by various package managers!"; + responseBody.Set("message") = "On linux you have to update yt-dlp yourself since it is a system-wide package handled by various package managers!"; } else // Some other error { @@ -429,7 +429,7 @@ bool RestQueryHandler::UpdateYoutubeDL(const JsonBlock& request, JsonBlock& resp responseCode = HTTP_STATUS_CODE::INTERNAL_SERVER_ERROR; responseBody.CloneFrom(RestResponseTemplates::GetByCode(HTTP_STATUS_CODE::INTERNAL_SERVER_ERROR)); - responseBody.Set("message") = "Unable do update youtube-dl.exe! See urlmon " + result; + responseBody.Set("message") = "Unable do update yt-dlp.exe! See urlmon " + result; } return true; diff --git a/Tubio/RestQueryHandler.h b/Tubio/RestQueryHandler.h index bd2e5a5..6e5bbd2 100644 --- a/Tubio/RestQueryHandler.h +++ b/Tubio/RestQueryHandler.h @@ -32,7 +32,7 @@ namespace Rest static bool FetchAlltimeLogs(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); static bool FetchSessionLogs(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); static bool GetDiskUsage(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); - static bool UpdateYoutubeDL(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); + static bool UpdateYtDlp(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); static bool RemoveDownloadEntry(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); static bool UpdateConfig(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); static bool ResetConfigDefaults(const JasonPP::JsonBlock& request, JasonPP::JsonBlock& responseBody, HTTP_STATUS_CODE& responseCode); diff --git a/Tubio/Updater.cpp b/Tubio/Updater.cpp index 67a4664..0eeb533 100644 --- a/Tubio/Updater.cpp +++ b/Tubio/Updater.cpp @@ -2,7 +2,7 @@ using namespace JasonPP; -std::string Updater::UpdateYoutubeDL() +std::string Updater::UpdateYtDlp() { #ifdef _WIN // Fetch rest respone for latest yt-dlp release diff --git a/Tubio/Updater.h b/Tubio/Updater.h index 89e9f11..648c1b1 100644 --- a/Tubio/Updater.h +++ b/Tubio/Updater.h @@ -13,8 +13,8 @@ class Updater { public: /// - /// Will update youtube-dl.exe on windows only!! Returns error message. On linux, you have to update it yourself, since it is a package of its own! + /// Will update yt-dlp.exe on windows only!! Returns error message. On linux, you have to update it yourself, since it is a package of its own! /// /// - static std::string UpdateYoutubeDL(); + static std::string UpdateYtDlp(); }; diff --git a/tubio-frontend-nuxt-app/pages/settings.vue b/tubio-frontend-nuxt-app/pages/settings.vue index 015d140..0fcbc03 100644 --- a/tubio-frontend-nuxt-app/pages/settings.vue +++ b/tubio-frontend-nuxt-app/pages/settings.vue @@ -209,7 +209,7 @@ export default { updateYtdl: function() { const that = this; axios.post("/api", { - request: "update_dep_youtubedl", + request: "update_dep_yt-dlp", }).then(function(response){ if (response.data.status === "OK") { that.$store.dispatch("logs/update", that);