summaryrefslogtreecommitdiffstats
path: root/src/cli.rs
diff options
context:
space:
mode:
authorDan Davison <dandavison7@gmail.com>2020-06-29 18:10:59 -0400
committerDan Davison <dandavison7@gmail.com>2020-06-30 08:00:30 -0400
commit3d2d5b4be755f0bea7ebd92759d930191514297f (patch)
treef3829fe7d5d645f542fd209b5e8a4d3eaca17fcc /src/cli.rs
parentf5c7053fdbedebb512151346a7eefd2b7d3565c9 (diff)
Trivial changes
Diffstat (limited to 'src/cli.rs')
-rw-r--r--src/cli.rs14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/cli.rs b/src/cli.rs
index e8c48654..1855d660 100644
--- a/src/cli.rs
+++ b/src/cli.rs
@@ -7,11 +7,13 @@ use itertools;
use lazy_static::lazy_static;
use structopt::clap::AppSettings::{ColorAlways, ColoredHelp, DeriveDisplayOrder};
use structopt::{clap, StructOpt};
+use syntect::highlighting::Theme as SyntaxTheme;
+use syntect::parsing::SyntaxSet;
use crate::git_config::GitConfig;
use crate::options;
-#[derive(StructOpt, Clone, Debug, PartialEq)]
+#[derive(StructOpt, Clone)]
#[structopt(
name = "delta",
about = "A viewer for git and diff output",
@@ -495,6 +497,16 @@ pub struct Opt {
#[structopt(long = "theme")]
/// Deprecated: use --syntax-theme.
pub deprecated_theme: Option<String>,
+ #[structopt(skip)]
+ pub computed: ComputedValues,
+}
+
+#[derive(Default, Clone, Debug)]
+pub struct ComputedValues {
+ pub is_light_mode: bool,
+ pub syntax_set: SyntaxSet,
+ pub syntax_theme: Option<SyntaxTheme>,
+ pub syntax_dummy_theme: SyntaxTheme,
}
impl Opt {