feat: set rust-version in Cargo.toml, closes #77

Update zigbuild docker run command to download latest rust version
This commit is contained in:
Jack Wills
2025-12-09 11:10:19 +00:00
parent 65d7970033
commit 0763a1024f
13 changed files with 50 additions and 62 deletions
+4 -6
View File
@@ -689,12 +689,11 @@ impl Logs {
if let Some(new_index) = match sd {
ScrollDirection::Next => current_position.checked_add(1),
ScrollDirection::Previous => current_position.checked_sub(1),
} {
if let Some(f) = self.search_results.get(new_index) {
}
&& let Some(f) = self.search_results.get(new_index) {
self.lines.state.select(Some(*f));
return Some(());
}
}
} else {
let range = match sd {
ScrollDirection::Previous => (0..=current_selected).rev().collect::<Vec<_>>(),
@@ -922,11 +921,10 @@ impl Logs {
/// Add a padding so one char will always be visilbe?
pub fn forward(&mut self, width: u16) {
let offset = usize::from(self.offset);
if self.horizontal_scroll_able(width) {
if self.adjusted_max_width > 0 && offset < self.adjusted_max_width {
if self.horizontal_scroll_able(width)
&& self.adjusted_max_width > 0 && offset < self.adjusted_max_width {
self.offset = self.offset.saturating_add(1);
}
}
}
/// Reduce the char offset
+4 -6
View File
@@ -172,11 +172,10 @@ impl AppData {
}
pub fn log_search_scroll(&mut self, np: &ScrollDirection) {
if let Some(i) = self.get_mut_selected_container() {
if i.logs.search_scroll(np).is_some() {
if let Some(i) = self.get_mut_selected_container()
&& i.logs.search_scroll(np).is_some() {
self.rerender.update_draw();
}
}
}
pub fn gen_log_search(&self) -> Option<LogSearch> {
@@ -340,14 +339,13 @@ impl AppData {
/// Sort containers based on a given header, if headings match, and already ascending, remove sorting
pub fn set_sort_by_header(&mut self, selected_header: Header) {
let mut output = Some((selected_header, SortedOrder::Asc));
if let Some((current_header, order)) = self.get_sorted() {
if current_header == selected_header {
if let Some((current_header, order)) = self.get_sorted()
&& current_header == selected_header {
match order {
SortedOrder::Desc => output = None,
SortedOrder::Asc => output = Some((selected_header, SortedOrder::Desc)),
}
}
}
self.set_sorted(output);
}