summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAnas <anas.elgarhy.dev@gmail.com>2024-02-21 22:27:33 +0200
committerGitHub <noreply@github.com>2024-02-21 21:27:33 +0100
commitc629070ea52b7cb92c4039c709caceb0439d4363 (patch)
tree3474310ba387cf32f6199740757a498e29220eb1 /src
parent5cff3221a1bb6bc45b3171fe3b95e6b7b0df9755 (diff)
fix: fix typos (#2092)
Diffstat (limited to 'src')
-rw-r--r--src/components/changes.rs2
-rw-r--r--src/components/diff.rs2
-rw-r--r--src/components/syntax_text.rs2
-rw-r--r--src/main.rs2
-rw-r--r--src/popups/msg.rs4
5 files changed, 6 insertions, 6 deletions
diff --git a/src/components/changes.rs b/src/components/changes.rs
index cf241156..9a8d5859 100644
--- a/src/components/changes.rs
+++ b/src/components/changes.rs
@@ -97,7 +97,7 @@ impl ChangesComponent {
let config =
self.options.borrow().status_show_untracked();
- //TODO: check if we can handle the one file case with it aswell
+ //TODO: check if we can handle the one file case with it as well
sync::stage_add_all(
&self.repo.borrow(),
tree_item.info.full_path.as_str(),
diff --git a/src/components/diff.rs b/src/components/diff.rs
index c402bc69..a6ce3ee3 100644
--- a/src/components/diff.rs
+++ b/src/components/diff.rs
@@ -568,7 +568,7 @@ impl DiffComponent {
fn stage_lines(&self) {
if let Some(diff) = &self.diff {
- //TODO: support untracked files aswell
+ //TODO: support untracked files as well
if !diff.untracked {
let selected_lines = self.selected_lines();
diff --git a/src/components/syntax_text.rs b/src/components/syntax_text.rs
index 9da5d2cc..aaf348dd 100644
--- a/src/components/syntax_text.rs
+++ b/src/components/syntax_text.rs
@@ -107,7 +107,7 @@ impl SyntaxTextComponent {
.is_some_and(|(current_file, _)| current_file == &path);
if !already_loaded {
- //TODO: fetch file content async aswell
+ //TODO: fetch file content async as well
match sync::tree_file_content(&self.repo.borrow(), item) {
Ok(content) => {
let content = tabs_to_spaces(content);
diff --git a/src/main.rs b/src/main.rs
index 4531c6ac..91d6649a 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -370,7 +370,7 @@ fn start_terminal(buf: Stdout) -> io::Result<Terminal> {
Ok(terminal)
}
-// do log::error! and eprintln! in one line, pass sting, error and backtrace
+// do log::error! and eprintln! in one line, pass string, error and backtrace
macro_rules! log_eprintln {
($string:expr, $e:expr, $bt:expr) => {
log::error!($string, $e, $bt);
diff --git a/src/popups/msg.rs b/src/popups/msg.rs
index d217328d..6da957ce 100644
--- a/src/popups/msg.rs
+++ b/src/popups/msg.rs
@@ -42,8 +42,8 @@ impl DrawableComponent for MsgPopup {
if max > std::u16::MAX as usize {
max = std::u16::MAX as usize;
}
- let mut width =
- u16::try_from(max).expect("cant fail due to check above");
+ let mut width = u16::try_from(max)
+ .expect("can't fail due to check above");
// dont overflow screen, and dont get too narrow
if width > f.size().width {
width = f.size().width;