Skip to content

Commit c92957d

Browse files
committed
Print an explicit message if the base repo head commit is up-to-date
1 parent 7d59cb3 commit c92957d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

josh-sync/src/sync.rs

+5
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,11 @@ impl GitSync {
4545
let josh_url =
4646
format!("http://localhost:{JOSH_PORT}/{UPSTREAM_REPO}.git@{commit}{JOSH_FILTER}.git");
4747

48+
let previous_base_commit = sh.read_file("rust-version")?.trim().to_string();
49+
if previous_base_commit == commit {
50+
return Err(anyhow::anyhow!("No changes since last pull"));
51+
}
52+
4853
// Update rust-version file. As a separate commit, since making it part of
4954
// the merge has confused the heck out of josh in the past.
5055
// We pass `--no-verify` to avoid running git hooks.

0 commit comments

Comments
 (0)