mirror of
https://github.com/alexpasmantier/television.git
synced 2025-06-07 03:55:23 +00:00
chore(rust): update rust edition to 2024 and version to 1.87 (#528)
This commit is contained in:
parent
aac7e4dc45
commit
738fe08fbb
@ -1,7 +1,7 @@
|
||||
[package]
|
||||
name = "television"
|
||||
version = "0.11.9"
|
||||
edition = "2021"
|
||||
edition = "2024"
|
||||
description = "A cross-platform, fast and extensible general purpose fuzzy finder TUI."
|
||||
license = "MIT"
|
||||
authors = ["Alexandre Pasmantier <alex.pasmant@gmail.com>"]
|
||||
@ -24,7 +24,7 @@ include = [
|
||||
"build.rs",
|
||||
"man",
|
||||
]
|
||||
rust-version = "1.83"
|
||||
rust-version = "1.87"
|
||||
build = "build.rs"
|
||||
|
||||
[lib]
|
||||
|
@ -1,17 +1,17 @@
|
||||
use criterion::criterion_group;
|
||||
use criterion::{black_box, Criterion};
|
||||
use criterion::{Criterion, black_box};
|
||||
use devicons::FileIcon;
|
||||
use ratatui::Terminal;
|
||||
use ratatui::backend::TestBackend;
|
||||
use ratatui::layout::Alignment;
|
||||
use ratatui::layout::Rect;
|
||||
use ratatui::prelude::{Line, Style};
|
||||
use ratatui::style::Color;
|
||||
use ratatui::widgets::{Block, BorderType, Borders, ListDirection, Padding};
|
||||
use ratatui::Terminal;
|
||||
use television::{
|
||||
action::Action,
|
||||
channels::{
|
||||
entry::{into_ranges, Entry},
|
||||
entry::{Entry, into_ranges},
|
||||
prototypes::Cable,
|
||||
},
|
||||
config::{Config, ConfigEnv},
|
||||
|
@ -1,3 +1,3 @@
|
||||
[toolchain]
|
||||
channel = "1.83"
|
||||
channel = "1.87"
|
||||
components = ["rustfmt", "clippy", "rust-analyzer"]
|
||||
|
@ -10,10 +10,10 @@ use crate::{
|
||||
entry::Entry,
|
||||
prototypes::{Cable, ChannelPrototype},
|
||||
},
|
||||
config::{default_tick_rate, Config},
|
||||
config::{Config, default_tick_rate},
|
||||
event::{Event, EventLoop, Key},
|
||||
keymap::Keymap,
|
||||
render::{render, RenderingTask, UiState},
|
||||
render::{RenderingTask, UiState, render},
|
||||
television::{Mode, Television},
|
||||
};
|
||||
|
||||
@ -417,7 +417,7 @@ impl App {
|
||||
// forward action to the television handler
|
||||
if let Some(action) = self.television.update(&action)? {
|
||||
self.action_tx.send(action)?;
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
Ok(ActionOutcome::None)
|
||||
|
@ -104,10 +104,10 @@ where
|
||||
let p = p.as_ref();
|
||||
p.file_stem()
|
||||
.and_then(|s| s.to_str())
|
||||
.map_or(false, |s| s.ends_with(CABLE_FILE_NAME_SUFFIX))
|
||||
.map_or_else(|| false, |s| s.ends_with(CABLE_FILE_NAME_SUFFIX))
|
||||
&& p.extension()
|
||||
.and_then(|e| e.to_str())
|
||||
.map_or(false, |e| e.to_lowercase() == CABLE_FILE_FORMAT)
|
||||
.map_or_else(|| false, |e| e.to_lowercase() == CABLE_FILE_FORMAT)
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
@ -1,4 +1,7 @@
|
||||
use std::hash::{Hash, Hasher};
|
||||
use std::{
|
||||
fmt::Write,
|
||||
hash::{Hash, Hasher},
|
||||
};
|
||||
|
||||
use devicons::FileIcon;
|
||||
|
||||
@ -131,7 +134,7 @@ impl Entry {
|
||||
pub fn stdout_repr(&self) -> String {
|
||||
let mut repr = self.name.clone();
|
||||
if let Some(line_number) = self.line_number {
|
||||
repr.push_str(&format!(":{line_number}"));
|
||||
write!(repr, ":{}", line_number).unwrap();
|
||||
}
|
||||
repr
|
||||
}
|
||||
|
@ -16,21 +16,21 @@ use crate::{
|
||||
///
|
||||
/// The prototype contains the following fields:
|
||||
/// - `name`: The name of the channel. This will be used to identify the
|
||||
/// channel throughout the application and in UI menus.
|
||||
/// channel throughout the application and in UI menus.
|
||||
/// - `source_command`: The command to run to get the source for the channel.
|
||||
/// This is a shell command that will be run in the background.
|
||||
/// This is a shell command that will be run in the background.
|
||||
/// - `interactive`: Whether the source command should be run in an interactive
|
||||
/// shell. This is useful for commands that need the user's environment e.g.
|
||||
/// `alias`.
|
||||
/// shell. This is useful for commands that need the user's environment e.g.
|
||||
/// `alias`.
|
||||
/// - `preview_command`: The command to run on each entry to get the preview
|
||||
/// for the channel. If this is not `None`, the channel will display a preview
|
||||
/// pane with the output of this command.
|
||||
/// for the channel. If this is not `None`, the channel will display a preview
|
||||
/// pane with the output of this command.
|
||||
/// - `preview_delimiter`: The delimiter to use to split an entry into
|
||||
/// multiple parts that can then be referenced in the preview command (e.g.
|
||||
/// `{1} + {2}`).
|
||||
/// multiple parts that can then be referenced in the preview command (e.g.
|
||||
/// `{1} + {2}`).
|
||||
/// - `preview_offset`: a litteral expression that will be interpreted later on
|
||||
/// in order to determine the vertical offset at which the preview should be
|
||||
/// displayed.
|
||||
/// in order to determine the vertical offset at which the preview should be
|
||||
/// displayed.
|
||||
///
|
||||
/// # Example
|
||||
/// The default files channel might look something like this:
|
||||
|
@ -3,7 +3,7 @@ use crate::{
|
||||
entry::Entry,
|
||||
prototypes::{Cable, ChannelPrototype},
|
||||
},
|
||||
matcher::{config::Config, Matcher},
|
||||
matcher::{Matcher, config::Config},
|
||||
};
|
||||
use anyhow::Result;
|
||||
use devicons::FileIcon;
|
||||
|
@ -1,7 +1,7 @@
|
||||
use rustc_hash::FxHashMap;
|
||||
use std::path::Path;
|
||||
|
||||
use anyhow::{anyhow, Result};
|
||||
use anyhow::{Result, anyhow};
|
||||
use tracing::debug;
|
||||
|
||||
use crate::{
|
||||
@ -11,7 +11,7 @@ use crate::{
|
||||
prototypes::{Cable, ChannelPrototype},
|
||||
},
|
||||
cli::args::{Cli, Command},
|
||||
config::{get_config_dir, get_data_dir, KeyBindings},
|
||||
config::{KeyBindings, get_config_dir, get_data_dir},
|
||||
};
|
||||
|
||||
pub mod args;
|
||||
@ -327,8 +327,8 @@ mod tests {
|
||||
}
|
||||
|
||||
/// Returns a tuple containing a command mapping and a fallback channel.
|
||||
fn guess_channel_from_prompt_setup<'a>(
|
||||
) -> (FxHashMap<String, String>, &'a str, Cable) {
|
||||
fn guess_channel_from_prompt_setup<'a>()
|
||||
-> (FxHashMap<String, String>, &'a str, Cable) {
|
||||
let mut command_mapping = FxHashMap::default();
|
||||
command_mapping.insert("vim".to_string(), "files".to_string());
|
||||
command_mapping.insert("export".to_string(), "env".to_string());
|
||||
|
@ -1,5 +1,5 @@
|
||||
use crate::action::Action;
|
||||
use crate::event::{convert_raw_event_to_key, Key};
|
||||
use crate::event::{Key, convert_raw_event_to_key};
|
||||
use crossterm::event::{KeyCode, KeyEvent, KeyModifiers};
|
||||
use rustc_hash::FxHashMap;
|
||||
use serde::{Deserialize, Deserializer, Serialize};
|
||||
@ -144,7 +144,7 @@ fn extract_modifiers(raw: &str) -> (&str, KeyModifiers) {
|
||||
current = &rest[6..];
|
||||
}
|
||||
_ => break, // break out of the loop if no known prefix is detected
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
(current, modifiers)
|
||||
@ -273,8 +273,7 @@ pub fn parse_key(raw: &str) -> anyhow::Result<Key, String> {
|
||||
raw
|
||||
} else {
|
||||
let raw = raw.strip_prefix('<').unwrap_or(raw);
|
||||
let raw = raw.strip_suffix('>').unwrap_or(raw);
|
||||
raw
|
||||
raw.strip_suffix('>').unwrap_or(raw)
|
||||
};
|
||||
let key_event = parse_key_event(raw)?;
|
||||
Ok(convert_raw_event_to_key(key_event))
|
||||
|
@ -8,7 +8,7 @@ use std::{
|
||||
use anyhow::{Context, Result};
|
||||
use directories::ProjectDirs;
|
||||
pub use keybindings::merge_keybindings;
|
||||
pub use keybindings::{parse_key, Binding, KeyBindings};
|
||||
pub use keybindings::{Binding, KeyBindings, parse_key};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use shell_integration::ShellIntegrationConfig;
|
||||
pub use themes::Theme;
|
||||
@ -138,7 +138,10 @@ impl Config {
|
||||
Ok(final_cfg)
|
||||
} else {
|
||||
// otherwise, create the default configuration file
|
||||
warn!("No config file found at {:?}, creating default configuration file at that location.", config_env.config_dir);
|
||||
warn!(
|
||||
"No config file found at {:?}, creating default configuration file at that location.",
|
||||
config_env.config_dir
|
||||
);
|
||||
// create the default configuration file in the user's config directory
|
||||
std::fs::write(
|
||||
config_env.config_dir.join(CONFIG_FILE_NAME),
|
||||
@ -213,14 +216,13 @@ pub fn get_data_dir() -> PathBuf {
|
||||
.filter(|p| p.is_absolute())
|
||||
});
|
||||
|
||||
let directory = if let Some(s) = data_folder {
|
||||
if let Some(s) = data_folder {
|
||||
s
|
||||
} else if let Some(proj_dirs) = project_directory() {
|
||||
proj_dirs.data_local_dir().to_path_buf()
|
||||
} else {
|
||||
PathBuf::from("../../../../..").join(".data")
|
||||
};
|
||||
directory
|
||||
}
|
||||
}
|
||||
|
||||
pub fn get_config_dir() -> PathBuf {
|
||||
@ -235,14 +237,12 @@ pub fn get_config_dir() -> PathBuf {
|
||||
.map(|p| p.join(PROJECT_NAME))
|
||||
.filter(|p| p.is_absolute())
|
||||
});
|
||||
let directory = if let Some(s) = config_dir {
|
||||
if let Some(s) = config_dir {
|
||||
s
|
||||
} else if cfg!(unix) {
|
||||
// default to ~/.config/television for unix systems
|
||||
if let Some(base_dirs) = directories::BaseDirs::new() {
|
||||
let cfg_dir =
|
||||
base_dirs.home_dir().join(".config").join("television");
|
||||
cfg_dir
|
||||
base_dirs.home_dir().join(".config").join("television")
|
||||
} else {
|
||||
PathBuf::from("../../../../..").join(".config")
|
||||
}
|
||||
@ -250,8 +250,7 @@ pub fn get_config_dir() -> PathBuf {
|
||||
proj_dirs.config_local_dir().to_path_buf()
|
||||
} else {
|
||||
PathBuf::from("../../../../..").join("../../../../../.config")
|
||||
};
|
||||
directory
|
||||
}
|
||||
}
|
||||
|
||||
fn project_directory() -> Option<ProjectDirs> {
|
||||
|
@ -1,7 +1,7 @@
|
||||
use std::{hash::Hash, time::Instant};
|
||||
|
||||
use anyhow::Result;
|
||||
use ratatui::{layout::Rect, Frame};
|
||||
use ratatui::{Frame, layout::Rect};
|
||||
use rustc_hash::FxHashSet;
|
||||
|
||||
use crate::{
|
||||
|
@ -8,8 +8,8 @@ use std::{
|
||||
|
||||
use crossterm::event::{
|
||||
KeyCode::{
|
||||
BackTab, Backspace, Char, Delete, Down, End, Enter, Esc, Home, Insert,
|
||||
Left, PageDown, PageUp, Right, Tab, Up, F,
|
||||
BackTab, Backspace, Char, Delete, Down, End, Enter, Esc, F, Home,
|
||||
Insert, Left, PageDown, PageUp, Right, Tab, Up,
|
||||
},
|
||||
KeyEvent, KeyEventKind, KeyModifiers,
|
||||
};
|
||||
|
@ -1,5 +1,5 @@
|
||||
use anyhow::Result;
|
||||
use tracing_subscriber::{fmt, prelude::*, EnvFilter};
|
||||
use tracing_subscriber::{EnvFilter, fmt, prelude::*};
|
||||
|
||||
use crate::config::get_data_dir;
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use std::env;
|
||||
use std::io::{stdout, BufWriter, IsTerminal, Write};
|
||||
use std::io::{BufWriter, IsTerminal, Write, stdout};
|
||||
use std::path::Path;
|
||||
use std::process::exit;
|
||||
|
||||
@ -15,14 +15,15 @@ use tracing::{debug, error, info};
|
||||
|
||||
use television::app::{App, AppOptions};
|
||||
use television::cli::{
|
||||
PostProcessedCli,
|
||||
args::{Cli, Command},
|
||||
guess_channel_from_prompt, list_channels, PostProcessedCli,
|
||||
guess_channel_from_prompt, list_channels,
|
||||
};
|
||||
|
||||
use television::config::{merge_keybindings, Config, ConfigEnv};
|
||||
use television::config::{Config, ConfigEnv, merge_keybindings};
|
||||
use television::utils::shell::render_autocomplete_script_template;
|
||||
use television::utils::{
|
||||
shell::{completion_script, Shell},
|
||||
shell::{Shell, completion_script},
|
||||
stdin::is_readable_stdin,
|
||||
};
|
||||
|
||||
|
@ -123,6 +123,7 @@ impl Picker {
|
||||
}
|
||||
}
|
||||
|
||||
#[allow(clippy::doc_overindented_list_items)]
|
||||
#[cfg(test)]
|
||||
mod tests {
|
||||
use super::*;
|
||||
|
@ -14,7 +14,7 @@ use crate::{
|
||||
channels::{entry::Entry, preview::PreviewCommand},
|
||||
utils::{
|
||||
command::shell_command,
|
||||
strings::{replace_non_printable, ReplaceNonPrintableConfig},
|
||||
strings::{ReplaceNonPrintableConfig, replace_non_printable},
|
||||
},
|
||||
};
|
||||
|
||||
@ -193,12 +193,16 @@ impl Previewer {
|
||||
}
|
||||
}
|
||||
Request::Shutdown => {
|
||||
debug!("Received shutdown signal, breaking out of the previewer loop.");
|
||||
debug!(
|
||||
"Received shutdown signal, breaking out of the previewer loop."
|
||||
);
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
debug!("Preview request channel closed and no messages left, breaking out of the previewer loop.");
|
||||
debug!(
|
||||
"Preview request channel closed and no messages left, breaking out of the previewer loop."
|
||||
);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -2,7 +2,7 @@ use anyhow::Result;
|
||||
use crossterm::terminal::{BeginSynchronizedUpdate, EndSynchronizedUpdate};
|
||||
use crossterm::{execute, queue};
|
||||
use ratatui::layout::Rect;
|
||||
use std::io::{stderr, stdout, LineWriter};
|
||||
use std::io::{LineWriter, stderr, stdout};
|
||||
use tracing::{debug, warn};
|
||||
|
||||
use tokio::sync::mpsc;
|
||||
|
@ -5,10 +5,10 @@ use crate::screen::metadata::build_metadata_table;
|
||||
use crate::screen::mode::mode_color;
|
||||
use crate::television::Mode;
|
||||
use crate::utils::metadata::AppMetadata;
|
||||
use ratatui::Frame;
|
||||
use ratatui::layout::Rect;
|
||||
use ratatui::prelude::{Color, Style};
|
||||
use ratatui::widgets::{Block, BorderType, Borders, Padding, Table};
|
||||
use ratatui::Frame;
|
||||
|
||||
pub fn draw_logo_block(
|
||||
f: &mut Frame,
|
||||
|
@ -1,15 +1,15 @@
|
||||
use crate::utils::input::Input;
|
||||
use anyhow::Result;
|
||||
use ratatui::{
|
||||
Frame,
|
||||
layout::{
|
||||
Alignment, Constraint, Direction, Layout as RatatuiLayout, Rect,
|
||||
},
|
||||
style::{Style, Stylize},
|
||||
text::{Line, Span},
|
||||
widgets::{
|
||||
block::Position, Block, BorderType, Borders, ListState, Paragraph,
|
||||
Block, BorderType, Borders, ListState, Paragraph, block::Position,
|
||||
},
|
||||
Frame,
|
||||
};
|
||||
|
||||
use crate::screen::{colors::Colorscheme, spinner::Spinner};
|
||||
|
@ -21,8 +21,7 @@ pub fn build_logo_paragraph<'a>() -> Paragraph<'a> {
|
||||
.lines()
|
||||
.map(std::convert::Into::into)
|
||||
.collect::<Vec<_>>();
|
||||
let logo_paragraph = Paragraph::new(lines);
|
||||
logo_paragraph
|
||||
Paragraph::new(lines)
|
||||
}
|
||||
|
||||
const REMOTE_LOGO: &str = r"
|
||||
@ -51,6 +50,5 @@ pub fn build_remote_logo_paragraph<'a>() -> Paragraph<'a> {
|
||||
.lines()
|
||||
.map(std::convert::Into::into)
|
||||
.collect::<Vec<_>>();
|
||||
let logo_paragraph = Paragraph::new(lines);
|
||||
logo_paragraph
|
||||
Paragraph::new(lines)
|
||||
}
|
||||
|
@ -1,14 +1,14 @@
|
||||
use crate::previewer::state::PreviewState;
|
||||
use crate::screen::colors::Colorscheme;
|
||||
use crate::utils::strings::{
|
||||
replace_non_printable, shrink_with_ellipsis, ReplaceNonPrintableConfig,
|
||||
EMPTY_STRING,
|
||||
EMPTY_STRING, ReplaceNonPrintableConfig, replace_non_printable,
|
||||
shrink_with_ellipsis,
|
||||
};
|
||||
use ansi_to_tui::IntoText;
|
||||
use anyhow::Result;
|
||||
use devicons::FileIcon;
|
||||
use ratatui::widgets::{Block, BorderType, Borders, Padding, Paragraph};
|
||||
use ratatui::Frame;
|
||||
use ratatui::widgets::{Block, BorderType, Borders, Padding, Paragraph};
|
||||
use ratatui::{
|
||||
layout::{Alignment, Rect},
|
||||
prelude::{Color, Line, Span, Style, Stylize, Text},
|
||||
|
@ -7,6 +7,7 @@ use crate::television::Mode;
|
||||
use crate::utils::input::Input;
|
||||
|
||||
use anyhow::Result;
|
||||
use ratatui::Frame;
|
||||
use ratatui::layout::{Alignment, Constraint, Direction, Layout, Rect};
|
||||
use ratatui::prelude::Style;
|
||||
use ratatui::style::{Color, Stylize};
|
||||
@ -14,7 +15,6 @@ use ratatui::text::{Line, Span};
|
||||
use ratatui::widgets::{
|
||||
Block, BorderType, Borders, ListDirection, ListState, Padding, Paragraph,
|
||||
};
|
||||
use ratatui::Frame;
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
pub fn draw_remote_control(
|
||||
|
@ -4,14 +4,15 @@ use crate::screen::layout::InputPosition;
|
||||
use crate::utils::indices::truncate_highlighted_string;
|
||||
use crate::utils::strings::make_matched_string_printable;
|
||||
use anyhow::Result;
|
||||
use ratatui::Frame;
|
||||
use ratatui::layout::{Alignment, Rect};
|
||||
use ratatui::prelude::{Color, Line, Span, Style};
|
||||
use ratatui::style::Stylize;
|
||||
use ratatui::widgets::{
|
||||
Block, BorderType, Borders, List, ListDirection, ListState, Padding,
|
||||
};
|
||||
use ratatui::Frame;
|
||||
use rustc_hash::FxHashSet;
|
||||
use std::fmt::Write;
|
||||
use std::str::FromStr;
|
||||
use unicode_width::UnicodeWidthStr;
|
||||
|
||||
@ -73,7 +74,8 @@ fn build_result_line<'a>(
|
||||
entry,
|
||||
area_width,
|
||||
use_icons,
|
||||
selected_entries.map_or(false, |selected| selected.contains(entry)),
|
||||
selected_entries
|
||||
.map_or_else(|| false, |selected| selected.contains(entry)),
|
||||
);
|
||||
// optional selection symbol
|
||||
if let Some(selected_entries) = selected_entries {
|
||||
@ -257,10 +259,10 @@ pub fn draw_results_list(
|
||||
) -> Result<()> {
|
||||
let mut toggle_hints = String::new();
|
||||
if !no_help {
|
||||
toggle_hints.push_str(&format!(" help: <{help_keybinding}> ",));
|
||||
write!(toggle_hints, " help: <{}> ", help_keybinding)?;
|
||||
}
|
||||
if preview_togglable {
|
||||
toggle_hints.push_str(&format!(" preview: <{preview_keybinding}> ",));
|
||||
write!(toggle_hints, " preview: <{}> ", preview_keybinding)?;
|
||||
}
|
||||
|
||||
let results_block = Block::default()
|
||||
|
@ -11,8 +11,8 @@ use crate::{
|
||||
input::convert_action_to_input_request,
|
||||
picker::Picker,
|
||||
previewer::{
|
||||
state::PreviewState, Config as PreviewerConfig, Preview, Previewer,
|
||||
Request as PreviewRequest, Ticket,
|
||||
Config as PreviewerConfig, Preview, Previewer,
|
||||
Request as PreviewRequest, Ticket, state::PreviewState,
|
||||
},
|
||||
render::UiState,
|
||||
screen::{
|
||||
@ -29,7 +29,7 @@ use rustc_hash::{FxBuildHasher, FxHashSet};
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::collections::HashSet;
|
||||
use tokio::sync::mpsc::{
|
||||
unbounded_channel, UnboundedReceiver, UnboundedSender,
|
||||
UnboundedReceiver, UnboundedSender, unbounded_channel,
|
||||
};
|
||||
use tracing::debug;
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
use std::{
|
||||
io::{stderr, LineWriter, Write},
|
||||
io::{LineWriter, Write, stderr},
|
||||
ops::{Deref, DerefMut},
|
||||
};
|
||||
|
||||
@ -9,8 +9,8 @@ use crossterm::{
|
||||
event::DisableMouseCapture,
|
||||
execute,
|
||||
terminal::{
|
||||
disable_raw_mode, enable_raw_mode, is_raw_mode_enabled,
|
||||
EnterAlternateScreen, LeaveAlternateScreen,
|
||||
EnterAlternateScreen, LeaveAlternateScreen, disable_raw_mode,
|
||||
enable_raw_mode, is_raw_mode_enabled,
|
||||
},
|
||||
};
|
||||
use ratatui::{backend::CrosstermBackend, layout::Size};
|
||||
|
@ -82,7 +82,7 @@ impl Clipboard {
|
||||
#[cfg(unix)]
|
||||
pub async fn set(&self, s: impl AsRef<std::ffi::OsStr>) {
|
||||
use std::{
|
||||
io::{stderr, BufWriter},
|
||||
io::{BufWriter, stderr},
|
||||
process::Stdio,
|
||||
};
|
||||
|
||||
@ -150,7 +150,7 @@ impl Clipboard {
|
||||
mod osc52 {
|
||||
use std::ffi::OsStr;
|
||||
|
||||
use base64::{engine::general_purpose, Engine};
|
||||
use base64::{Engine, engine::general_purpose};
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct SetClipboard {
|
||||
|
@ -10,7 +10,7 @@ use std::sync::OnceLock;
|
||||
use tracing::{debug, warn};
|
||||
|
||||
use crate::utils::strings::{
|
||||
proportion_of_printable_ascii_characters, PRINTABLE_ASCII_THRESHOLD,
|
||||
PRINTABLE_ASCII_THRESHOLD, proportion_of_printable_ascii_characters,
|
||||
};
|
||||
use crate::utils::threads::default_num_threads;
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
use lazy_regex::{regex, Lazy, Regex};
|
||||
use lazy_regex::{Lazy, Regex, regex};
|
||||
|
||||
/// Returns the index of the next character boundary in the given string.
|
||||
///
|
||||
|
Loading…
x
Reference in New Issue
Block a user