fix: don't modify config of external repos
The git config files of external repos are read-only. This is the only place where we make reference to a remote named 'origin', so this also closes kemitix/git-next#85. Closes kemitix/git-next#85
This commit is contained in:
parent
5f36282667
commit
b70b479a49
2 changed files with 2 additions and 2 deletions
|
@ -138,7 +138,7 @@ impl RepoDetails {
|
||||||
#[tracing::instrument]
|
#[tracing::instrument]
|
||||||
pub fn write_remote_url(&self, url: &RemoteUrl) -> Result<(), kxio::fs::Error> {
|
pub fn write_remote_url(&self, url: &RemoteUrl) -> Result<(), kxio::fs::Error> {
|
||||||
if self.gitdir.storage_path_type() != StoragePathType::Internal {
|
if self.gitdir.storage_path_type() != StoragePathType::Internal {
|
||||||
// return Err(Not an internal repo)
|
return Ok(());
|
||||||
}
|
}
|
||||||
let fs = self.gitdir.as_fs();
|
let fs = self.gitdir.as_fs();
|
||||||
// load config file
|
// load config file
|
||||||
|
|
|
@ -354,7 +354,7 @@ async fn should_reject_message_with_expired_token() -> TestResult {
|
||||||
}
|
}
|
||||||
|
|
||||||
#[test_log::test(actix::test)]
|
#[test_log::test(actix::test)]
|
||||||
// NOTE: failed then passed on retry: count = 3
|
// NOTE: failed then passed on retry: count = 4
|
||||||
async fn should_send_validate_repo_when_retryable_error() -> TestResult {
|
async fn should_send_validate_repo_when_retryable_error() -> TestResult {
|
||||||
//given
|
//given
|
||||||
let fs = given::a_filesystem();
|
let fs = given::a_filesystem();
|
||||||
|
|
Loading…
Reference in a new issue