feat: kanban cli
runner nix smoke / nix label and flake smoke (push) Failing after 1m20s

This commit is contained in:
2026-09-28 09:25:04 +00:00
parent 54eb69d1c7
commit 5b0ae6be5e
9 changed files with 272 additions and 55 deletions
+21 -8
View File
@@ -5,15 +5,10 @@ use std::fs;
use std::os::unix::fs::PermissionsExt;
use std::path::PathBuf;
use clap::Parser;
use clap::{Args as ClapArgs, Parser};
#[derive(Parser)]
#[command(
name = "gitea-kanban-tui",
version,
about = "Browse and move Gitea issues using native projects"
)]
pub struct Args {
#[derive(Clone, Debug, ClapArgs)]
pub struct SharedArgs {
/// Gitea base URL; falls back to GITEA_URL
#[arg(long)]
pub url: Option<String>,
@@ -37,6 +32,17 @@ pub struct Args {
pub repo: Option<String>,
}
#[derive(Debug, Parser)]
#[command(
name = "gitea-kanban-tui",
version,
about = "Browse and move Gitea issues using native projects"
)]
pub struct Args {
#[command(flatten)]
pub shared: SharedArgs,
}
#[derive(Debug)]
pub struct Config {
pub base_url: String,
@@ -64,6 +70,13 @@ impl Config {
}
pub fn from_args_with<F>(args: Args, env_var: F) -> Result<Self, ConfigError>
where
F: Fn(&str) -> Option<String>,
{
Self::from_shared_args_with(args.shared, env_var)
}
pub fn from_shared_args_with<F>(args: SharedArgs, env_var: F) -> Result<Self, ConfigError>
where
F: Fn(&str) -> Option<String>,
{