Compare commits

..

2 commits

Author SHA1 Message Date
6e3aef2e84 build: add start-mac-tunnel
All checks were successful
ci/woodpecker/push/push-next Pipeline was successful
ci/woodpecker/push/cron-docker-builder Pipeline was successful
ci/woodpecker/push/tag-created Pipeline was successful
2024-08-30 08:17:10 +01:00
6efe82d5b6 fix: create git graph log to after doing a fetch
Some checks failed
ci/woodpecker/push/cron-docker-builder Pipeline was successful
ci/woodpecker/push/tag-created Pipeline was successful
ci/woodpecker/push/push-next Pipeline failed
Rust / build (push) Successful in 7m14s
2024-08-30 08:16:37 +01:00
4 changed files with 18 additions and 64 deletions

View file

@ -1,7 +1,7 @@
//
use actix::prelude::*;
use tracing::{debug, info, instrument, Instrument as _};
use tracing::{debug, instrument, Instrument as _};
use crate::{
repo::{
@ -13,7 +13,6 @@ use crate::{
};
use git_next_core::git::{
self,
validation::positions::{validate, Error, Positions},
UserNotification,
};
@ -112,6 +111,7 @@ impl Handler<ValidateRepo> for RepoActor {
.wait(ctx);
}
Err(Error::UserIntervention(user_notification)) => {
// FIXME: end up here when doing git force push to leave this situation
self.alert_tui(format!("[USER INTERVENTION: {user_notification}]"));
if let UserNotification::CICheckFailed { log, .. }
| UserNotification::DevNotBasedOnMain { log, .. } = &user_notification

View file

@ -1,10 +1,9 @@
use tracing::{debug, info, instrument};
//
use crate::{
git::{self, repository::open::OpenRepositoryLike, RepoDetails, UserNotification},
BranchName, RepoConfig,
};
use tracing::{debug, instrument};
pub type Result<T> = core::result::Result<T, Error>;

View file

@ -75,12 +75,7 @@ mod positions {
);
let repo_config = given::a_repo_config();
let result = validate(
&*repository,
&repo_details,
&repo_config,
git::graph::Log::default(),
);
let result = validate(&*repository, &repo_details, &repo_config);
println!("{result:?}");
let_assert!(Err(err) = result, "validate");
@ -120,12 +115,7 @@ mod positions {
"open repo"
);
let result = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default(),
);
let result = validate(&*open_repository, &repo_details, &repo_config);
println!("{result:?}");
assert!(matches!(
@ -164,12 +154,7 @@ mod positions {
"open repo"
);
let result = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default(),
);
let result = validate(&*open_repository, &repo_details, &repo_config);
println!("{result:?}");
assert!(matches!(
@ -208,12 +193,7 @@ mod positions {
"open repo"
);
let result = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default(),
);
let result = validate(&*open_repository, &repo_details, &repo_config);
println!("{result:?}");
assert!(matches!(
@ -260,12 +240,7 @@ mod positions {
//when
let_assert!(
Err(err) = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default()
),
Err(err) = validate(&*open_repository, &repo_details, &repo_config),
"validate"
);
@ -350,12 +325,7 @@ mod positions {
//when
let_assert!(
Err(err) = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default()
),
Err(err) = validate(&*open_repository, &repo_details, &repo_config),
"validate"
);
@ -424,12 +394,7 @@ mod positions {
//when
let_assert!(
Err(err) = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default()
),
Err(err) = validate(&*open_repository, &repo_details, &repo_config),
"validate"
);
@ -516,12 +481,7 @@ mod positions {
//when
let_assert!(
Err(err) = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default()
),
Err(err) = validate(&*open_repository, &repo_details, &repo_config),
"validate"
);
@ -607,12 +567,8 @@ mod positions {
//when
let_assert!(
Ok(positions) = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default()
),
Ok((positions, _git_log)) =
validate(&*open_repository, &repo_details, &repo_config),
"validate"
);
@ -671,12 +627,8 @@ mod positions {
//when
let_assert!(
Ok(positions) = validate(
&*open_repository,
&repo_details,
&repo_config,
git::graph::Log::default()
),
Ok((positions, _git_log)) =
validate(&*open_repository, &repo_details, &repo_config),
"validate"
);

View file

@ -21,6 +21,9 @@ start-ngrok:
ngrok http --domain=${NGROK_DOMAIN} 8080
fi
start-mac-tunnel:
ssh dagon -R7777:localhost:8888
coverage-update:
cargo tarpaulin --lib --out html
echo "Now:\n\topen tarpaulin-report.html"