Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mirror bats syntax / theme support #23

Closed
6 of 7 tasks
epage opened this issue Sep 11, 2022 · 3 comments
Closed
6 of 7 tasks

Mirror bats syntax / theme support #23

epage opened this issue Sep 11, 2022 · 3 comments
Labels
enhancement Improve the expected

Comments

@epage
Copy link
Collaborator

epage commented Sep 11, 2022

@epage epage added the enhancement Improve the expected label Sep 11, 2022
@epage epage added this to the 0.1 - Basic Blame milestone Sep 11, 2022
@epage
Copy link
Collaborator Author

epage commented Oct 7, 2022

Seeing if we can just depend on a subset of bat: sharkdp/bat#919 (comment)

@epage
Copy link
Collaborator Author

epage commented Oct 9, 2022

As for background color handling, they fill to the end of the line with whitespace to get the right background iff a background color is set.

@epage
Copy link
Collaborator Author

epage commented Oct 13, 2022

For the gutter (like line numbers), bat uses

const DEFAULT_GUTTER_COLOR: u8 = 238;

       let gutter_style = Style {
            foreground: match theme.settings.gutter_foreground {
                // If the theme provides a gutter foreground color, use it.
                // Note: It might be the special value #00000001, in which case
                // to_ansi_color returns None and we use an empty Style
                // (resulting in the terminal's default foreground color).
                Some(c) => to_ansi_color(c, true_color),
                // Otherwise, use a specific fallback color.
                None => Some(Fixed(DEFAULT_GUTTER_COLOR)),
            },
            ..Style::default()
        };

epage added a commit that referenced this issue Oct 26, 2022
@epage epage closed this as completed Oct 26, 2022
epage added a commit to epage/git-dive that referenced this issue Sep 27, 2024
…go-deny-action-2.x

chore(deps): Update EmbarkStudios/cargo-deny-action action to v2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improve the expected
Projects
None yet
Development

No branches or pull requests

1 participant