mirror of
https://github.com/msfjarvis/clipboard-substitutor
synced 2025-08-14 21:17:01 +05:30
feat(rust): upgrade to Rust 1.78.0
This commit is contained in:
parent
31fc360c02
commit
fc7ae8340a
4 changed files with 4 additions and 4 deletions
|
@ -42,7 +42,7 @@
|
|||
|
||||
rustStable = (import fenix {inherit pkgs;}).fromToolchainFile {
|
||||
file = ./rust-toolchain.toml;
|
||||
sha256 = "sha256-7QfkHty6hSrgNM0fspycYkRcB82eEqYa4CoAJ9qA3tU=";
|
||||
sha256 = "sha256-opUgs6ckUQCyDxcB9Wy51pqhd0MPGHUVbwRKKPGiwZU=";
|
||||
};
|
||||
|
||||
craneLib = (crane.mkLib pkgs).overrideToolchain rustStable;
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
[toolchain]
|
||||
channel = "1.77.2"
|
||||
channel = "1.78.0"
|
||||
components = ["clippy", "rustfmt", "rust-src"]
|
||||
targets = ["x86_64-unknown-linux-gnu"]
|
||||
profile = "minimal"
|
||||
|
|
|
@ -4,7 +4,7 @@ use copypasta::{ClipboardContext, ClipboardProvider};
|
|||
use std::time::Duration;
|
||||
use tracing::{debug, error};
|
||||
|
||||
pub fn monitor(config: Replacements) -> Result<()> {
|
||||
pub fn monitor(config: &Replacements) -> Result<()> {
|
||||
loop {
|
||||
let mut clipboard =
|
||||
ClipboardContext::new().expect("Failed to get clipboard");
|
||||
|
|
|
@ -25,7 +25,7 @@ fn main() -> Result<()> {
|
|||
std::fs::read_to_string(config_path.as_path()).unwrap_or_default();
|
||||
let config: Replacements = toml::from_str(&config_str)?;
|
||||
config.validate()?;
|
||||
monitor(config)
|
||||
monitor(&config)
|
||||
}
|
||||
|
||||
fn check_for_version_arg() -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue