Skip to content

Commit 25ef001

Browse files
committed
Add uptream diff link to pull merge commit message
1 parent 28a012f commit 25ef001

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/sync.rs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,10 +169,16 @@ Pull recent changes from https://github.com/{upstream_repo} via Josh.
169169
170170
Upstream ref: {upstream_sha}
171171
Filtered ref: {incoming_ref}
172+
Upstream diff: https://github.com/{DEFAULT_UPSTREAM_REPO}/compare/{prev_upstream_sha}...{upstream_sha}
172173
173174
This merge was created using https://github.com/rust-lang/josh-sync.
174175
"#,
175176
upstream_head_short = &upstream_sha[..12],
177+
prev_upstream_sha = self
178+
.context
179+
.last_upstream_sha
180+
.as_deref()
181+
.unwrap_or(&upstream_sha)
176182
);
177183

178184
// Merge the fetched commit.
@@ -367,7 +373,7 @@ fn prepare_rustc_checkout(verbose: bool) -> anyhow::Result<PathBuf> {
367373
"git",
368374
"clone",
369375
"--filter=blob:none",
370-
"https://github.com/rust-lang/rust",
376+
&format!("https://github.com/{DEFAULT_UPSTREAM_REPO}"),
371377
path,
372378
],
373379
verbose,

0 commit comments

Comments
 (0)