Skip to content

Commit c4f68bf

Browse files
committed
adapt to changes in git-repository
1 parent becbd8d commit c4f68bf

File tree

4 files changed

+4
-7
lines changed

4 files changed

+4
-7
lines changed

Diff for: cargo-smart-release/src/context.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ impl Context {
2626
) -> anyhow::Result<Self> {
2727
let meta = cargo_metadata::MetadataCommand::new().exec()?;
2828
let root = meta.workspace_root.clone();
29-
let repo = git::discover(&root)?.apply_environment();
29+
let repo = git::discover(&root)?;
3030
let crates_index = crate::crates_index::Index::new_cargo_default()?;
3131
let history = (force_history_segmentation
3232
|| matches!(bump, BumpSpec::Auto)

Diff for: gitoxide-core/src/hours/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ where
5353
W: io::Write,
5454
P: Progress,
5555
{
56-
let repo = git::discover(working_dir)?.apply_environment();
56+
let repo = git::discover(working_dir)?;
5757
let commit_id = repo.rev_parse_single(rev_spec)?.detach();
5858
let mut string_heap = BTreeSet::<&'static [u8]>::new();
5959
let needs_stats = file_stats || line_stats;

Diff for: gitoxide-core/src/index/checkout.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,7 @@ pub fn checkout_exclusive(
2626
thread_limit,
2727
}: index::checkout_exclusive::Options,
2828
) -> anyhow::Result<()> {
29-
let repo = repo
30-
.map(|dir| git_repository::discover(dir).map(|r| r.apply_environment()))
31-
.transpose()?;
29+
let repo = repo.map(git_repository::discover).transpose()?;
3230

3331
let dest_directory = dest_directory.as_ref();
3432
if dest_directory.exists() {

Diff for: src/plumbing/main.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,7 @@ pub fn main() -> Result<()> {
8989
mapping.full.modify(to_match_settings);
9090
mapping.reduced.modify(to_match_settings);
9191
let mut repo = git::ThreadSafeRepository::discover_opts(repository, Default::default(), mapping)
92-
.map(git::Repository::from)
93-
.map(|r| r.apply_environment())?;
92+
.map(git::Repository::from)?;
9493
if !config.is_empty() {
9594
repo.config_snapshot_mut()
9695
.append_config(config.iter(), git::config::Source::Cli)

0 commit comments

Comments
 (0)