-
Notifications
You must be signed in to change notification settings - Fork 32
Merge queue #330
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merge queue #330
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -303,3 +303,33 @@ fn list_workflows_status(workflows: &[WorkflowModel]) -> String { | |
.collect::<Vec<_>>() | ||
.join("\n") | ||
} | ||
|
||
pub fn auto_build_started_comment(head_sha: &CommitSha, merge_sha: &CommitSha) -> Comment { | ||
Comment::new(format!( | ||
":hourglass: Testing commit {} with merge {}...", | ||
head_sha, merge_sha | ||
)) | ||
} | ||
|
||
pub fn auto_build_succeeded_comment( | ||
workflows: &[WorkflowModel], | ||
approved_by: &str, | ||
merge_sha: &CommitSha, | ||
base_ref: &str, | ||
) -> Comment { | ||
let urls = workflows | ||
.iter() | ||
.map(|w| format!("[{}]({})", w.name, w.url)) | ||
.collect::<Vec<_>>() | ||
.join(", "); | ||
|
||
Comment::new(format!( | ||
":sunny: Test successful - {urls}\nApproved by: `{approved_by}`\nPushing {merge_sha} to `{base_ref}`...", | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like the raw string change got reverted here in the latest push? But I don't want to block this PR any further, it can be changed to a raw string again in some follow-up PR. |
||
)) | ||
} | ||
|
||
pub fn auto_build_push_failed_comment(error: &str) -> Comment { | ||
Comment::new(format!( | ||
":eyes: Test was successful, but fast-forwarding failed: {error}" | ||
)) | ||
} |
Uh oh!
There was an error while loading. Please reload this page.