Merge branch 'master' into master

pull/1019/head
Tom Parker-Shemilt 3 years ago committed by GitHub
commit 0cc078a474
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -15,7 +15,7 @@ If you want to add an entry to the `README.md` please consider this:
* if you've not published your crate to `crates.io` remove the `[[CRATE](...)]` part. * if you've not published your crate to `crates.io` remove the `[[CRATE](...)]` part.
* if you have a CI build, please add the build badge. Put the image after the description, separated by a space. Please make sure to add the branch information to the image: * if you have a CI build, please add the build badge. Put the image after the description, separated by a space. Please make sure to add the branch information to the image:
* example for Travis: ` [<img src="https://api.travis-ci.org/XXX/CRATE.svg?branch=master">](https://travis-ci.org/XXX/CRATE)` * example for Travis: ` [<img src="https://api.travis-ci.org/XXX/CRATE.svg?branch=master">](https://travis-ci.org/XXX/CRATE)`
* for Github actions please see https://docs.github.com/en/free-pro-team@latest/actions/managing-workflow-runs/adding-a-workflow-status-badge#using-the-branch-parameter * for Github actions please see https://docs.github.com/en/actions/managing-workflow-runs/adding-a-workflow-status-badge
- please pay attention to the alphabetical ordering. - please pay attention to the alphabetical ordering.

@ -39,9 +39,6 @@ enum CheckerError {
#[fail(display = "travis build image with no branch")] #[fail(display = "travis build image with no branch")]
TravisBuildNoBranch, TravisBuildNoBranch,
#[fail(display = "github actions image with no branch")]
GithubActionNoBranch,
} }
fn formatter(err: &CheckerError, url: &String) -> String { fn formatter(err: &CheckerError, url: &String) -> String {
@ -62,9 +59,6 @@ fn formatter(err: &CheckerError, url: &String) -> String {
CheckerError::TravisBuildNoBranch => { CheckerError::TravisBuildNoBranch => {
format!("[Travis build image with no branch specified] {}", url) format!("[Travis build image with no branch specified] {}", url)
} }
CheckerError::GithubActionNoBranch => {
format!("[Github action image with no branch specified] {}", url)
}
_ => { _ => {
format!("{:?}", err) format!("{:?}", err)
} }
@ -227,14 +221,6 @@ fn get_url_core(url: String) -> BoxFuture<'static, (String, Result<(), CheckerEr
break; break;
} }
} }
if let Some(matches) = GITHUB_ACTIONS_REGEX.captures(&url) {
debug!("Github actions match {:?}", matches);
let query = matches.get(1).map(|x| x.as_str()).unwrap_or("");
if !query.starts_with("?") || query.find("branch=").is_none() {
res = Err(CheckerError::GithubActionNoBranch);
break;
}
}
debug!("Finished {}", url); debug!("Finished {}", url);
res = Ok(()); res = Ok(());
break; break;

Loading…
Cancel
Save