Skip to content

Commit 7e755c0

Browse files
Remove push_options file after reading it (#1335)
This file was considered by git bad data and sometimes caused pushes to fail Change: rm-push-options
1 parent 3043aeb commit 7e755c0

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

josh-proxy/src/lib.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,9 @@ pub fn process_repo_update(repo_update: RepoUpdate) -> josh::JoshResult<String>
137137
.join(&repo_update.git_ns)
138138
.join("push_options");
139139

140-
let push_options = std::fs::read_to_string(push_options_path)?;
140+
let push_options = std::fs::read_to_string(&push_options_path)?;
141+
std::fs::remove_file(push_options_path).ok();
142+
141143
let push_options: PushOptions = serde_json::from_str(&push_options)
142144
.map_err(|e| josh_error(&format!("Failed to parse push options: {}", e)))?;
143145

0 commit comments

Comments
 (0)