Skip to content

Commit 2b71f35

Browse files
authored
Merge branch 'extrawurst:master' into allow-multiline-commit-messgages
2 parents 35b5a18 + 5b69f77 commit 2b71f35

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+251
-159
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2424
* add `regex-fancy` and `regex-onig` features to allow building Syntect with Onigumara regex engine instead of the default engine based on fancy-regex [[@jirutka](https://github.com/jirutka)]
2525
* add `vendor-openssl` feature to allow building without vendored openssl [[@jirutka](https://github.com/jirutka)]
2626
* allow copying marked commits [[@remique](https://github.com/remique)] ([#1288](https://github.com/extrawurst/gitui/issues/1288))
27+
* display tags and branches in the log view [[@alexmaco]](https://github.com/alexmaco)([#1371](https://github.com/extrawurst/gitui/pull/1371))
28+
* display current repository path in the top-right corner [[@alexmaco]](https://github.com/alexmaco)([#1387](https://github.com/extrawurst/gitui/pull/1387))
2729

2830
### Fixes
2931
* remove insecure dependency `ansi_term` ([#1290](https://github.com/extrawurst/gitui/issues/1290))

Cargo.lock

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,4 +69,7 @@ install-timing:
6969
cargo install --features=timing --path "." --offline
7070

7171
licenses:
72-
cargo bundle-licenses --format toml --output THIRDPARTY.toml
72+
cargo bundle-licenses --format toml --output THIRDPARTY.toml
73+
74+
clean:
75+
cargo clean

THEMES.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@ Notes:
1818
* rgb colors might not be supported in every terminal.
1919
* using a color like `yellow` might appear in whatever your terminal/theme defines for `yellow`
2020
* valid colors can be found in tui-rs' [Color](https://docs.rs/tui/0.12.0/tui/style/enum.Color.html) struct.
21-
* all customizable theme elements can be found in `style.rs` in the `impl Default for Theme` block
21+
* all customizable theme elements can be found in [`style.rs` in the `impl Default for Theme` block](https://github.com/extrawurst/gitui/blob/master/src/ui/style.rs#L305)

asyncgit/src/asyncjob/mod.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ mod test {
207207
let res =
208208
self.v.fetch_add(self.value_to_add, Ordering::SeqCst);
209209

210-
println!("[job] value: {}", res);
210+
println!("[job] value: {res}");
211211

212212
Ok(())
213213
}
@@ -236,8 +236,8 @@ mod test {
236236
}
237237

238238
println!("recv");
239-
let _foo = receiver.recv().unwrap();
240-
let _foo = receiver.recv().unwrap();
239+
receiver.recv().unwrap();
240+
receiver.recv().unwrap();
241241
assert!(receiver.is_empty());
242242

243243
assert_eq!(
@@ -282,7 +282,7 @@ mod test {
282282
wait_for_job(&job);
283283

284284
println!("recv");
285-
let _foo = receiver.recv().unwrap();
285+
receiver.recv().unwrap();
286286
println!("received");
287287

288288
assert_eq!(

asyncgit/src/error.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,12 +83,12 @@ pub type Result<T> = std::result::Result<T, Error>;
8383

8484
impl<T> From<std::sync::PoisonError<T>> for Error {
8585
fn from(error: std::sync::PoisonError<T>) -> Self {
86-
Self::Generic(format!("poison error: {}", error))
86+
Self::Generic(format!("poison error: {error}"))
8787
}
8888
}
8989

9090
impl<T> From<crossbeam_channel::SendError<T>> for Error {
9191
fn from(error: crossbeam_channel::SendError<T>) -> Self {
92-
Self::Generic(format!("send error: {}", error))
92+
Self::Generic(format!("send error: {error}"))
9393
}
9494
}

asyncgit/src/sync/blame.rs

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -170,18 +170,15 @@ mod tests {
170170
let repo_path: &RepoPath =
171171
&root.as_os_str().to_str().unwrap().into();
172172

173-
assert!(matches!(
174-
blame_file(&repo_path, "foo", None),
175-
Err(_)
176-
));
173+
assert!(matches!(blame_file(repo_path, "foo", None), Err(_)));
177174

178175
File::create(&root.join(file_path))?
179176
.write_all(b"line 1\n")?;
180177

181178
stage_add_file(repo_path, file_path)?;
182179
commit(repo_path, "first commit")?;
183180

184-
let blame = blame_file(&repo_path, "foo", None)?;
181+
let blame = blame_file(repo_path, "foo", None)?;
185182

186183
assert!(matches!(
187184
blame.lines.as_slice(),
@@ -205,7 +202,7 @@ mod tests {
205202
stage_add_file(repo_path, file_path)?;
206203
commit(repo_path, "second commit")?;
207204

208-
let blame = blame_file(&repo_path, "foo", None)?;
205+
let blame = blame_file(repo_path, "foo", None)?;
209206

210207
assert!(matches!(
211208
blame.lines.as_slice(),
@@ -232,14 +229,14 @@ mod tests {
232229

233230
file.write(b"line 3\n")?;
234231

235-
let blame = blame_file(&repo_path, "foo", None)?;
232+
let blame = blame_file(repo_path, "foo", None)?;
236233

237234
assert_eq!(blame.lines.len(), 2);
238235

239236
stage_add_file(repo_path, file_path)?;
240237
commit(repo_path, "third commit")?;
241238

242-
let blame = blame_file(&repo_path, "foo", None)?;
239+
let blame = blame_file(repo_path, "foo", None)?;
243240

244241
assert_eq!(blame.lines.len(), 3);
245242

@@ -264,6 +261,6 @@ mod tests {
264261
stage_add_file(repo_path, file_path).unwrap();
265262
commit(repo_path, "first commit").unwrap();
266263

267-
assert!(blame_file(&repo_path, "bar\\foo", None).is_ok());
264+
assert!(blame_file(repo_path, "bar\\foo", None).is_ok());
268265
}
269266
}

asyncgit/src/sync/branch/merge_commit.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ mod test {
158158
false,
159159
false,
160160
None,
161-
None.into(),
161+
None,
162162
)
163163
.is_err());
164164

@@ -195,7 +195,7 @@ mod test {
195195
//verify commit msg
196196
let details = crate::sync::get_commit_details(
197197
&clone2_dir.into(),
198-
merge_commit.into(),
198+
merge_commit,
199199
)
200200
.unwrap();
201201
assert_eq!(

asyncgit/src/sync/branch/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ pub(crate) fn branch_set_upstream(
206206

207207
if branch.upstream().is_err() {
208208
let remote = get_default_remote_in_repo(repo)?;
209-
let upstream_name = format!("{}/{}", remote, branch_name);
209+
let upstream_name = format!("{remote}/{branch_name}");
210210
branch.set_upstream(Some(upstream_name.as_str()))?;
211211
}
212212

asyncgit/src/sync/branch/rename.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ pub fn rename_branch(
2424

2525
#[cfg(test)]
2626
mod test {
27-
use super::super::*;
27+
use super::super::{checkout_branch, create_branch, RepoPath};
2828
use super::rename_branch;
2929
use crate::sync::tests::repo_init;
3030

@@ -42,7 +42,7 @@ mod test {
4242
assert_eq!(
4343
repo.branches(None)
4444
.unwrap()
45-
.nth(0)
45+
.next()
4646
.unwrap()
4747
.unwrap()
4848
.0
@@ -58,7 +58,7 @@ mod test {
5858
assert_eq!(
5959
repo.branches(None)
6060
.unwrap()
61-
.nth(0)
61+
.next()
6262
.unwrap()
6363
.unwrap()
6464
.0

0 commit comments

Comments
 (0)