diff options
Diffstat (limited to 'crates')
84 files changed, 840 insertions, 0 deletions
diff --git a/crates/colors/src/custom.rs b/crates/colors/src/custom.rs index 2adcfa9..fd6b7b3 100644 --- a/crates/colors/src/custom.rs +++ b/crates/colors/src/custom.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + // Taken from <https://github.com/owo-colors/owo-colors/blob/61f8bba2f5f80e9f4fa600fbfdf2c21656f1d523/src/colors/custom.rs> // at 2025-07-16T18:05:55 CEST. diff --git a/crates/colors/src/lib.rs b/crates/colors/src/lib.rs index 71a5f34..663e19a 100644 --- a/crates/colors/src/lib.rs +++ b/crates/colors/src/lib.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::fmt::{Display, Write}; use crate::{ diff --git a/crates/colors/src/list.rs b/crates/colors/src/list.rs index ecbe465..35fcb83 100644 --- a/crates/colors/src/list.rs +++ b/crates/colors/src/list.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::support::prepend_input; prepend_input! { diff --git a/crates/colors/src/support.rs b/crates/colors/src/support.rs index b42ce5d..3c3f87d 100644 --- a/crates/colors/src/support.rs +++ b/crates/colors/src/support.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + pub(super) const CSI: &str = "\x1b["; pub(super) const CSE: &str = "m"; diff --git a/crates/yt/src/commands/cache/implm.rs b/crates/yt/src/commands/cache/implm.rs index f71fe94..fd0fbce 100644 --- a/crates/yt/src/commands/cache/implm.rs +++ b/crates/yt/src/commands/cache/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ app::App, commands::CacheCommand, diff --git a/crates/yt/src/commands/cache/mod.rs b/crates/yt/src/commands/cache/mod.rs index b6afa39..4ed4b40 100644 --- a/crates/yt/src/commands/cache/mod.rs +++ b/crates/yt/src/commands/cache/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::Subcommand; mod implm; diff --git a/crates/yt/src/commands/config/implm.rs b/crates/yt/src/commands/config/implm.rs index 47b7fee..00c28a9 100644 --- a/crates/yt/src/commands/config/implm.rs +++ b/crates/yt/src/commands/config/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{app::App, commands::config::ConfigCommand}; use anyhow::Result; diff --git a/crates/yt/src/commands/config/mod.rs b/crates/yt/src/commands/config/mod.rs index ff97aab..503b4f7 100644 --- a/crates/yt/src/commands/config/mod.rs +++ b/crates/yt/src/commands/config/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::Parser; mod implm; diff --git a/crates/yt/src/commands/database/implm.rs b/crates/yt/src/commands/database/implm.rs index 8d81f2e..07d346b 100644 --- a/crates/yt/src/commands/database/implm.rs +++ b/crates/yt/src/commands/database/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ app::App, commands::DatabaseCommand, diff --git a/crates/yt/src/commands/database/mod.rs b/crates/yt/src/commands/database/mod.rs index 92b120f..06e3169 100644 --- a/crates/yt/src/commands/database/mod.rs +++ b/crates/yt/src/commands/database/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::fmt::{self, Display}; use clap::{Subcommand, ValueEnum}; diff --git a/crates/yt/src/commands/download/implm/mod.rs b/crates/yt/src/commands/download/implm/mod.rs index f681aea..c74a909 100644 --- a/crates/yt/src/commands/download/implm/mod.rs +++ b/crates/yt/src/commands/download/implm/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::sync::Arc; use crate::{ diff --git a/crates/yt/src/commands/download/mod.rs b/crates/yt/src/commands/download/mod.rs index 432865f..15026ba 100644 --- a/crates/yt/src/commands/download/mod.rs +++ b/crates/yt/src/commands/download/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use anyhow::Context; use clap::Parser; diff --git a/crates/yt/src/commands/implm.rs b/crates/yt/src/commands/implm.rs index ff29ce5..7c60c6a 100644 --- a/crates/yt/src/commands/implm.rs +++ b/crates/yt/src/commands/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::sync::Arc; use crate::commands::Command; diff --git a/crates/yt/src/commands/mod.rs b/crates/yt/src/commands/mod.rs index 2b847f7..431acef 100644 --- a/crates/yt/src/commands/mod.rs +++ b/crates/yt/src/commands/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ffi::OsStr, thread}; use clap::Subcommand; diff --git a/crates/yt/src/commands/playlist/implm.rs b/crates/yt/src/commands/playlist/implm.rs index 52a0977..603184b 100644 --- a/crates/yt/src/commands/playlist/implm.rs +++ b/crates/yt/src/commands/playlist/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{fmt::Write, path::Path}; use crate::{ diff --git a/crates/yt/src/commands/playlist/mod.rs b/crates/yt/src/commands/playlist/mod.rs index 6f7b255..8d3407d 100644 --- a/crates/yt/src/commands/playlist/mod.rs +++ b/crates/yt/src/commands/playlist/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::Parser; mod implm; diff --git a/crates/yt/src/commands/select/implm/fs_generators/mod.rs b/crates/yt/src/commands/select/implm/fs_generators/mod.rs index 8ccda3c..10da032 100644 --- a/crates/yt/src/commands/select/implm/fs_generators/mod.rs +++ b/crates/yt/src/commands/select/implm/fs_generators/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ collections::HashMap, env, diff --git a/crates/yt/src/commands/select/implm/mod.rs b/crates/yt/src/commands/select/implm/mod.rs index 155012c..f39c77f 100644 --- a/crates/yt/src/commands/select/implm/mod.rs +++ b/crates/yt/src/commands/select/implm/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{app::App, commands::select::SelectCommand, storage::db::insert::Operations}; use anyhow::Result; diff --git a/crates/yt/src/commands/select/implm/standalone/mod.rs b/crates/yt/src/commands/select/implm/standalone/mod.rs index 8b1008e..9512e32 100644 --- a/crates/yt/src/commands/select/implm/standalone/mod.rs +++ b/crates/yt/src/commands/select/implm/standalone/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::io::{Write, stderr}; use crate::{ diff --git a/crates/yt/src/commands/select/mod.rs b/crates/yt/src/commands/select/mod.rs index 3ab2972..db69238 100644 --- a/crates/yt/src/commands/select/mod.rs +++ b/crates/yt/src/commands/select/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ fmt::{self, Display, Formatter}, str::FromStr, diff --git a/crates/yt/src/commands/show/implm/mod.rs b/crates/yt/src/commands/show/implm/mod.rs index 66f9fa7..a2e40fd 100644 --- a/crates/yt/src/commands/show/implm/mod.rs +++ b/crates/yt/src/commands/show/implm/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ fs::{self, OpenOptions}, io, diff --git a/crates/yt/src/commands/show/mod.rs b/crates/yt/src/commands/show/mod.rs index fe583c0..60f2e51 100644 --- a/crates/yt/src/commands/show/mod.rs +++ b/crates/yt/src/commands/show/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::Subcommand; mod implm; diff --git a/crates/yt/src/commands/status/implm.rs b/crates/yt/src/commands/status/implm.rs index bdce6ee..dabc5df 100644 --- a/crates/yt/src/commands/status/implm.rs +++ b/crates/yt/src/commands/status/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::time::Duration; use crate::{ diff --git a/crates/yt/src/commands/status/mod.rs b/crates/yt/src/commands/status/mod.rs index d333fb4..4a8dee7 100644 --- a/crates/yt/src/commands/status/mod.rs +++ b/crates/yt/src/commands/status/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::Parser; mod implm; diff --git a/crates/yt/src/commands/subscriptions/implm.rs b/crates/yt/src/commands/subscriptions/implm.rs index 6001c85..31b714e 100644 --- a/crates/yt/src/commands/subscriptions/implm.rs +++ b/crates/yt/src/commands/subscriptions/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::str::FromStr; use crate::{ diff --git a/crates/yt/src/commands/subscriptions/mod.rs b/crates/yt/src/commands/subscriptions/mod.rs index 57d065b..edd41c6 100644 --- a/crates/yt/src/commands/subscriptions/mod.rs +++ b/crates/yt/src/commands/subscriptions/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::path::PathBuf; use clap::Subcommand; diff --git a/crates/yt/src/commands/update/implm/mod.rs b/crates/yt/src/commands/update/implm/mod.rs index 0bb6d99..53c7415 100644 --- a/crates/yt/src/commands/update/implm/mod.rs +++ b/crates/yt/src/commands/update/implm/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ app::App, commands::update::{UpdateCommand, implm::updater::Updater}, diff --git a/crates/yt/src/commands/update/implm/updater.rs b/crates/yt/src/commands/update/implm/updater.rs index 3e4bc85..ee61fa1 100644 --- a/crates/yt/src/commands/update/implm/updater.rs +++ b/crates/yt/src/commands/update/implm/updater.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::sync::atomic::{AtomicUsize, Ordering}; use anyhow::{Context, Result}; diff --git a/crates/yt/src/commands/update/mod.rs b/crates/yt/src/commands/update/mod.rs index 6c605b4..cb29148 100644 --- a/crates/yt/src/commands/update/mod.rs +++ b/crates/yt/src/commands/update/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::Parser; use clap_complete::ArgValueCompleter; diff --git a/crates/yt/src/commands/videos/implm.rs b/crates/yt/src/commands/videos/implm.rs index 0441b31..2a018c7 100644 --- a/crates/yt/src/commands/videos/implm.rs +++ b/crates/yt/src/commands/videos/implm.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ app::App, commands::videos::VideosCommand, diff --git a/crates/yt/src/commands/videos/mod.rs b/crates/yt/src/commands/videos/mod.rs index 298f13d..ca20715 100644 --- a/crates/yt/src/commands/videos/mod.rs +++ b/crates/yt/src/commands/videos/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::{ArgAction, Subcommand}; use crate::storage::db::extractor_hash::LazyExtractorHash; diff --git a/crates/yt/src/commands/watch/implm/mod.rs b/crates/yt/src/commands/watch/implm/mod.rs index 9eba858..8182216 100644 --- a/crates/yt/src/commands/watch/implm/mod.rs +++ b/crates/yt/src/commands/watch/implm/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ fs, path::PathBuf, diff --git a/crates/yt/src/commands/watch/mod.rs b/crates/yt/src/commands/watch/mod.rs index b106370..ea4c513 100644 --- a/crates/yt/src/commands/watch/mod.rs +++ b/crates/yt/src/commands/watch/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use clap::Parser; mod implm; diff --git a/crates/yt/src/config/mod.rs b/crates/yt/src/config/mod.rs index a19c25c..05bb4cf 100644 --- a/crates/yt/src/config/mod.rs +++ b/crates/yt/src/config/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::sync::atomic::{AtomicBool, Ordering}; use crate::config::support::mk_config; diff --git a/crates/yt/src/config/non_empty_vec.rs b/crates/yt/src/config/non_empty_vec.rs index 0ca864b..bd2c5e3 100644 --- a/crates/yt/src/config/non_empty_vec.rs +++ b/crates/yt/src/config/non_empty_vec.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ collections::VecDeque, fmt::{Display, Write}, diff --git a/crates/yt/src/config/support.rs b/crates/yt/src/config/support.rs index 880eba7..96e7ba4 100644 --- a/crates/yt/src/config/support.rs +++ b/crates/yt/src/config/support.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + macro_rules! mk_config { ( $(use $usage_path:path;)* diff --git a/crates/yt/src/shared/mod.rs b/crates/yt/src/shared/mod.rs index 14e4949..d3cc563 100644 --- a/crates/yt/src/shared/mod.rs +++ b/crates/yt/src/shared/mod.rs @@ -1 +1,11 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + pub(crate) mod bytes; diff --git a/crates/yt/src/storage/db/get/extractor_hash.rs b/crates/yt/src/storage/db/get/extractor_hash.rs index d10b326..c8e150a 100644 --- a/crates/yt/src/storage/db/get/extractor_hash.rs +++ b/crates/yt/src/storage/db/get/extractor_hash.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use anyhow::Result; use blake3::Hash; use sqlx::{SqliteConnection, query}; diff --git a/crates/yt/src/storage/db/get/mod.rs b/crates/yt/src/storage/db/get/mod.rs index 58f1dd6..dca16fc 100644 --- a/crates/yt/src/storage/db/get/mod.rs +++ b/crates/yt/src/storage/db/get/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + pub(crate) mod subscription; pub(crate) mod video; pub(crate) mod extractor_hash; diff --git a/crates/yt/src/storage/db/get/playlist.rs b/crates/yt/src/storage/db/get/playlist.rs index 95a61bf..5094523 100644 --- a/crates/yt/src/storage/db/get/playlist.rs +++ b/crates/yt/src/storage/db/get/playlist.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ app::App, storage::db::{ diff --git a/crates/yt/src/storage/db/get/subscription.rs b/crates/yt/src/storage/db/get/subscription.rs index cdb2b9a..16a6e8b 100644 --- a/crates/yt/src/storage/db/get/subscription.rs +++ b/crates/yt/src/storage/db/get/subscription.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::collections::HashMap; use crate::{ diff --git a/crates/yt/src/storage/db/get/txn_log.rs b/crates/yt/src/storage/db/get/txn_log.rs index e4a1dcb..1a6df2c 100644 --- a/crates/yt/src/storage/db/get/txn_log.rs +++ b/crates/yt/src/storage/db/get/txn_log.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ app::App, storage::db::{insert::Committable, txn_log::TxnLog, video::TimeStamp}, diff --git a/crates/yt/src/storage/db/get/video/mod.rs b/crates/yt/src/storage/db/get/video/mod.rs index 1f847cb..69adb6b 100644 --- a/crates/yt/src/storage/db/get/video/mod.rs +++ b/crates/yt/src/storage/db/get/video/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{fs::File, path::PathBuf}; use anyhow::{Context, Result, bail}; diff --git a/crates/yt/src/storage/db/insert/maintenance.rs b/crates/yt/src/storage/db/insert/maintenance.rs index 6442c48..d87c1ae 100644 --- a/crates/yt/src/storage/db/insert/maintenance.rs +++ b/crates/yt/src/storage/db/insert/maintenance.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ app::App, storage::db::{ diff --git a/crates/yt/src/storage/db/insert/mod.rs b/crates/yt/src/storage/db/insert/mod.rs index 60bbc0a..3458608 100644 --- a/crates/yt/src/storage/db/insert/mod.rs +++ b/crates/yt/src/storage/db/insert/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::mem; use crate::app::App; diff --git a/crates/yt/src/storage/db/insert/playlist.rs b/crates/yt/src/storage/db/insert/playlist.rs index 2287db9..4d3e140 100644 --- a/crates/yt/src/storage/db/insert/playlist.rs +++ b/crates/yt/src/storage/db/insert/playlist.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{cmp::Ordering, time::Duration}; use anyhow::{Context, Result}; diff --git a/crates/yt/src/storage/db/insert/subscription.rs b/crates/yt/src/storage/db/insert/subscription.rs index 8499966..d25a209 100644 --- a/crates/yt/src/storage/db/insert/subscription.rs +++ b/crates/yt/src/storage/db/insert/subscription.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::storage::db::{ insert::{Committable, Operations}, subscription::{Subscription, Subscriptions}, diff --git a/crates/yt/src/storage/db/insert/video/mod.rs b/crates/yt/src/storage/db/insert/video/mod.rs index 4cc7358..da62e37 100644 --- a/crates/yt/src/storage/db/insert/video/mod.rs +++ b/crates/yt/src/storage/db/insert/video/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ path::{Path, PathBuf}, time, diff --git a/crates/yt/src/storage/db/mod.rs b/crates/yt/src/storage/db/mod.rs index 5da28ed..f42c3fc 100644 --- a/crates/yt/src/storage/db/mod.rs +++ b/crates/yt/src/storage/db/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + pub(crate) mod get; pub(crate) mod insert; diff --git a/crates/yt/src/storage/db/playlist/mod.rs b/crates/yt/src/storage/db/playlist/mod.rs index 6fca98a..7366e8e 100644 --- a/crates/yt/src/storage/db/playlist/mod.rs +++ b/crates/yt/src/storage/db/playlist/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::ops::Add; use crate::storage::db::video::Video; diff --git a/crates/yt/src/storage/db/subscription.rs b/crates/yt/src/storage/db/subscription.rs index eb03e47..c111b52 100644 --- a/crates/yt/src/storage/db/subscription.rs +++ b/crates/yt/src/storage/db/subscription.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::collections::HashMap; use anyhow::Result; diff --git a/crates/yt/src/storage/db/txn_log.rs b/crates/yt/src/storage/db/txn_log.rs index 8d6c305..64884b0 100644 --- a/crates/yt/src/storage/db/txn_log.rs +++ b/crates/yt/src/storage/db/txn_log.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::storage::db::{insert::Committable, video::TimeStamp}; pub(crate) struct TxnLog<O: Committable> { diff --git a/crates/yt/src/storage/db/video/comments/display.rs b/crates/yt/src/storage/db/video/comments/display.rs index 084e54c..c372603 100644 --- a/crates/yt/src/storage/db/video/comments/display.rs +++ b/crates/yt/src/storage/db/video/comments/display.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::fmt::Write; use chrono::{Local, TimeZone}; diff --git a/crates/yt/src/storage/db/video/comments/mod.rs b/crates/yt/src/storage/db/video/comments/mod.rs index e7bd8f5..b89aa63 100644 --- a/crates/yt/src/storage/db/video/comments/mod.rs +++ b/crates/yt/src/storage/db/video/comments/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::mem; use regex::{Captures, Regex}; diff --git a/crates/yt/src/storage/db/video/comments/raw.rs b/crates/yt/src/storage/db/video/comments/raw.rs index a79820a..3b7f40f 100644 --- a/crates/yt/src/storage/db/video/comments/raw.rs +++ b/crates/yt/src/storage/db/video/comments/raw.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use serde::{Deserialize, Deserializer}; use url::Url; diff --git a/crates/yt/src/storage/db/video/comments/tests.rs b/crates/yt/src/storage/db/video/comments/tests.rs index 3bd1c73..03e3597 100644 --- a/crates/yt/src/storage/db/video/comments/tests.rs +++ b/crates/yt/src/storage/db/video/comments/tests.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use pretty_assertions::assert_eq; use url::Url; diff --git a/crates/yt/src/storage/db/video/mod.rs b/crates/yt/src/storage/db/video/mod.rs index e768cec..deeb82c 100644 --- a/crates/yt/src/storage/db/video/mod.rs +++ b/crates/yt/src/storage/db/video/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{fmt::Display, path::PathBuf, time::Duration}; use chrono::{DateTime, Utc}; diff --git a/crates/yt/src/yt_dlp/mod.rs b/crates/yt/src/yt_dlp/mod.rs index 0415247..eaa80a1 100644 --- a/crates/yt/src/yt_dlp/mod.rs +++ b/crates/yt/src/yt_dlp/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{borrow::ToOwned, str::FromStr, time::Duration}; use anyhow::{Context, Result}; diff --git a/crates/yt/tests/_testenv/init.rs b/crates/yt/tests/_testenv/init.rs index d797ed8..5970c7c 100644 --- a/crates/yt/tests/_testenv/init.rs +++ b/crates/yt/tests/_testenv/init.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ env, fs::{self, OpenOptions}, diff --git a/crates/yt/tests/_testenv/mod.rs b/crates/yt/tests/_testenv/mod.rs index 4798d5d..38d1f0a 100644 --- a/crates/yt/tests/_testenv/mod.rs +++ b/crates/yt/tests/_testenv/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + //! This code was taken from *fd* at 30-06-2025. use std::{path::PathBuf, process}; diff --git a/crates/yt/tests/_testenv/run.rs b/crates/yt/tests/_testenv/run.rs index 4df9362..578d823 100644 --- a/crates/yt/tests/_testenv/run.rs +++ b/crates/yt/tests/_testenv/run.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ collections::HashMap, process::{self, Stdio}, diff --git a/crates/yt/tests/_testenv/util.rs b/crates/yt/tests/_testenv/util.rs index b811bf7..6633fbf 100644 --- a/crates/yt/tests/_testenv/util.rs +++ b/crates/yt/tests/_testenv/util.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::_testenv::TestEnv; use std::{ diff --git a/crates/yt/tests/select/base.rs b/crates/yt/tests/select/base.rs index dddf721..24e198b 100644 --- a/crates/yt/tests/select/base.rs +++ b/crates/yt/tests/select/base.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{collections::HashMap, fs}; use crate::{ diff --git a/crates/yt/tests/select/file.rs b/crates/yt/tests/select/file.rs index 320b27f..b8bd2b5 100644 --- a/crates/yt/tests/select/file.rs +++ b/crates/yt/tests/select/file.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{ _testenv::util::{self, Subscription}, select::get_videos_in_state, diff --git a/crates/yt/tests/select/mod.rs b/crates/yt/tests/select/mod.rs index 9ee23f5..d7033f8 100644 --- a/crates/yt/tests/select/mod.rs +++ b/crates/yt/tests/select/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::_testenv::TestEnv; mod base; diff --git a/crates/yt/tests/select/options.rs b/crates/yt/tests/select/options.rs index f9456c0..6a0d155 100644 --- a/crates/yt/tests/select/options.rs +++ b/crates/yt/tests/select/options.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{_testenv::util, select::get_videos_in_state, testenv::TestEnv}; #[test] diff --git a/crates/yt/tests/subscriptions/import_export/golden.txt.license b/crates/yt/tests/subscriptions/import_export/golden.txt.license new file mode 100644 index 0000000..7813eb6 --- /dev/null +++ b/crates/yt/tests/subscriptions/import_export/golden.txt.license @@ -0,0 +1,9 @@ +yt - A fully featured command line YouTube client + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of Yt. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/crates/yt/tests/subscriptions/import_export/mod.rs b/crates/yt/tests/subscriptions/import_export/mod.rs index 44d3b8b..1156508 100644 --- a/crates/yt/tests/subscriptions/import_export/mod.rs +++ b/crates/yt/tests/subscriptions/import_export/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::testenv::TestEnv; #[test] diff --git a/crates/yt/tests/subscriptions/mod.rs b/crates/yt/tests/subscriptions/mod.rs index 5b0157f..0b300c5 100644 --- a/crates/yt/tests/subscriptions/mod.rs +++ b/crates/yt/tests/subscriptions/mod.rs @@ -1,2 +1,12 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + mod import_export; mod naming_subscriptions; diff --git a/crates/yt/tests/subscriptions/naming_subscriptions/golden.txt.license b/crates/yt/tests/subscriptions/naming_subscriptions/golden.txt.license new file mode 100644 index 0000000..7813eb6 --- /dev/null +++ b/crates/yt/tests/subscriptions/naming_subscriptions/golden.txt.license @@ -0,0 +1,9 @@ +yt - A fully featured command line YouTube client + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of Yt. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. diff --git a/crates/yt/tests/subscriptions/naming_subscriptions/mod.rs b/crates/yt/tests/subscriptions/naming_subscriptions/mod.rs index 255a575..50fe3e4 100644 --- a/crates/yt/tests/subscriptions/naming_subscriptions/mod.rs +++ b/crates/yt/tests/subscriptions/naming_subscriptions/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::testenv::TestEnv; #[test] diff --git a/crates/yt/tests/tests.rs b/crates/yt/tests/tests.rs index 9e6c95a..89c3091 100644 --- a/crates/yt/tests/tests.rs +++ b/crates/yt/tests/tests.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + // Use this, for the background run pids // #![feature(linux_pidfd)] diff --git a/crates/yt/tests/videos/downloading.rs b/crates/yt/tests/videos/downloading.rs index 7cb437c..f026858 100644 --- a/crates/yt/tests/videos/downloading.rs +++ b/crates/yt/tests/videos/downloading.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use crate::{_testenv::util, testenv::TestEnv}; #[test] diff --git a/crates/yt/tests/videos/mod.rs b/crates/yt/tests/videos/mod.rs index 1077d05..6a80761 100644 --- a/crates/yt/tests/videos/mod.rs +++ b/crates/yt/tests/videos/mod.rs @@ -1 +1,11 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + mod downloading; diff --git a/crates/yt/tests/watch/focus_switch.rs b/crates/yt/tests/watch/focus_switch.rs index e2242a8..81246f3 100644 --- a/crates/yt/tests/watch/focus_switch.rs +++ b/crates/yt/tests/watch/focus_switch.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use yt_dlp::json_cast; use crate::{_testenv::util, testenv::TestEnv, watch::MpvControl}; diff --git a/crates/yt/tests/watch/mod.rs b/crates/yt/tests/watch/mod.rs index deea597..7af8b39 100644 --- a/crates/yt/tests/watch/mod.rs +++ b/crates/yt/tests/watch/mod.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ io::{BufRead, BufReader, Write}, os::unix::net::UnixStream, diff --git a/crates/yt_dlp/crates/pyo3-pylogger/.gitignore b/crates/yt_dlp/crates/pyo3-pylogger/.gitignore index 64f40ab..733c5bc 100644 --- a/crates/yt_dlp/crates/pyo3-pylogger/.gitignore +++ b/crates/yt_dlp/crates/pyo3-pylogger/.gitignore @@ -1,3 +1,13 @@ +# yt - A fully featured command line YouTube client +# +# Copyright (C) 2025 Dylan Bobby Storey <dylan.storey@gmail.com>, cpu <daniel@binaryparadox.net>, Warren Snipes <contact@warrensnipes.dev> +# SPDX-License-Identifier: Apache-2.0 +# +# This file is part of Yt. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + target Cargo.lock .idea diff --git a/crates/yt_dlp/crates/pyo3-pylogger/Cargo.toml b/crates/yt_dlp/crates/pyo3-pylogger/Cargo.toml index 1deafd9..259ea98 100644 --- a/crates/yt_dlp/crates/pyo3-pylogger/Cargo.toml +++ b/crates/yt_dlp/crates/pyo3-pylogger/Cargo.toml @@ -1,3 +1,13 @@ +# yt - A fully featured command line YouTube client +# +# Copyright (C) 2025 Dylan Bobby Storey <dylan.storey@gmail.com>, cpu <daniel@binaryparadox.net>, Warren Snipes <contact@warrensnipes.dev> +# SPDX-License-Identifier: Apache-2.0 +# +# This file is part of Yt. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + [package] name = "pyo3-pylogger" version = "0.5.0" diff --git a/crates/yt_dlp/crates/pyo3-pylogger/README.md b/crates/yt_dlp/crates/pyo3-pylogger/README.md index 3160f4c..1f6c419 100644 --- a/crates/yt_dlp/crates/pyo3-pylogger/README.md +++ b/crates/yt_dlp/crates/pyo3-pylogger/README.md @@ -1,3 +1,15 @@ +<!-- +yt - A fully featured command line YouTube client + +Copyright (C) 2025 Dylan Bobby Storey <dylan.storey@gmail.com>, cpu <daniel@binaryparadox.net>, Warren Snipes <contact@warrensnipes.dev> +SPDX-License-Identifier: Apache-2.0 + +This file is part of Yt. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # pyo3-pylogger Enables log messages for pyo3 embedded Python applications using Python's `logging` or module. diff --git a/crates/yt_dlp/crates/pyo3-pylogger/src/kv.rs b/crates/yt_dlp/crates/pyo3-pylogger/src/kv.rs index 871a170..67a0c3e 100644 --- a/crates/yt_dlp/crates/pyo3-pylogger/src/kv.rs +++ b/crates/yt_dlp/crates/pyo3-pylogger/src/kv.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Dylan Bobby Storey <dylan.storey@gmail.com>, cpu <daniel@binaryparadox.net>, Warren Snipes <contact@warrensnipes.dev> +// SPDX-License-Identifier: Apache-2.0 +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + //! Key-Value handling module for Python LogRecord attributes. //! //! This module provides functionality to extract and handle custom key-value pairs diff --git a/crates/yt_dlp/crates/pyo3-pylogger/src/level.rs b/crates/yt_dlp/crates/pyo3-pylogger/src/level.rs index 132c65f..d244ef4 100644 --- a/crates/yt_dlp/crates/pyo3-pylogger/src/level.rs +++ b/crates/yt_dlp/crates/pyo3-pylogger/src/level.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Dylan Bobby Storey <dylan.storey@gmail.com>, cpu <daniel@binaryparadox.net>, Warren Snipes <contact@warrensnipes.dev> +// SPDX-License-Identifier: Apache-2.0 +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + /// A wrapper type for logging levels that supports both `tracing` and `log` features. pub(crate) struct Level(pub log::Level); diff --git a/crates/yt_dlp/crates/pyo3-pylogger/src/lib.rs b/crates/yt_dlp/crates/pyo3-pylogger/src/lib.rs index b16e448..3ecb123 100644 --- a/crates/yt_dlp/crates/pyo3-pylogger/src/lib.rs +++ b/crates/yt_dlp/crates/pyo3-pylogger/src/lib.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Dylan Bobby Storey <dylan.storey@gmail.com>, cpu <daniel@binaryparadox.net>, Warren Snipes <contact@warrensnipes.dev> +// SPDX-License-Identifier: Apache-2.0 +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + use std::{ ffi::CString, sync::{self, OnceLock}, diff --git a/crates/yt_dlp/crates/pyo3-pylogger/update.sh b/crates/yt_dlp/crates/pyo3-pylogger/update.sh index 2586afe..dd3e57e 100755 --- a/crates/yt_dlp/crates/pyo3-pylogger/update.sh +++ b/crates/yt_dlp/crates/pyo3-pylogger/update.sh @@ -1,5 +1,15 @@ #! /usr/bin/env sh +# yt - A fully featured command line YouTube client +# +# Copyright (C) 2025 Dylan Bobby Storey <dylan.storey@gmail.com>, cpu <daniel@binaryparadox.net>, Warren Snipes <contact@warrensnipes.dev> +# SPDX-License-Identifier: Apache-2.0 +# +# This file is part of Yt. +# +# You should have received a copy of the License along with this program. +# If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + cd "$(dirname "$0")" || exit 1 [ "$1" = "upgrade" ] && cargo upgrade --incompatible cargo update diff --git a/crates/yt_dlp/examples/main.rs b/crates/yt_dlp/examples/main.rs index b3a2dd5..e924407 100644 --- a/crates/yt_dlp/examples/main.rs +++ b/crates/yt_dlp/examples/main.rs @@ -1,3 +1,13 @@ +// yt - A fully featured command line YouTube client +// +// Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +// SPDX-License-Identifier: GPL-3.0-or-later +// +// This file is part of Yt. +// +// You should have received a copy of the License along with this program. +// If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. + fn main() { let yt_dlp = yt_dlp::options::YoutubeDLOptions::new().build().unwrap(); |