never let clippy fail, use CARGO_PKG_NAME, allow issues on gh, simplify regex a tad
Signed-off-by: strawberry <strawberry@puppygock.gay>
This commit is contained in:
parent
1a3051eb4a
commit
56e4166ee8
4 changed files with 4 additions and 17 deletions
11
.github/ISSUE_TEMPLATE/Issue.md
vendored
11
.github/ISSUE_TEMPLATE/Issue.md
vendored
|
@ -1,11 +0,0 @@
|
||||||
---
|
|
||||||
name: "Issue with / Feature Request for Conduit"
|
|
||||||
about: "Please file issues on GitLab: https://gitlab.com/famedly/conduit/-/issues/new"
|
|
||||||
title: "CLOSE ME"
|
|
||||||
---
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
**⚠️ Conduit development does not happen on GitHub. Issues opened here will not be addressed**
|
|
||||||
|
|
||||||
Please open issues on GitLab: https://gitlab.com/famedly/conduit/-/issues/new
|
|
|
@ -145,7 +145,6 @@ test:cargo:
|
||||||
|
|
||||||
test:clippy:
|
test:clippy:
|
||||||
extends: .test-shared-settings
|
extends: .test-shared-settings
|
||||||
allow_failure: true
|
|
||||||
before_script:
|
before_script:
|
||||||
- rustup component add clippy
|
- rustup component add clippy
|
||||||
- apt-get update && apt-get -y --no-install-recommends install libclang-dev # dependency for rocksdb
|
- apt-get update && apt-get -y --no-install-recommends install libclang-dev # dependency for rocksdb
|
||||||
|
@ -166,7 +165,6 @@ test:format:
|
||||||
|
|
||||||
test:audit:
|
test:audit:
|
||||||
extends: .test-shared-settings
|
extends: .test-shared-settings
|
||||||
allow_failure: true
|
|
||||||
script:
|
script:
|
||||||
- cargo audit --color always || true
|
- cargo audit --color always || true
|
||||||
- cargo audit --stale --json | gitlab-report -p audit > gl-sast-report.json
|
- cargo audit --stale --json | gitlab-report -p audit > gl-sast-report.json
|
||||||
|
|
|
@ -572,7 +572,7 @@ pub async fn get_server_version_route(
|
||||||
|
|
||||||
Ok(get_server_version::v1::Response {
|
Ok(get_server_version::v1::Response {
|
||||||
server: Some(get_server_version::v1::Server {
|
server: Some(get_server_version::v1::Server {
|
||||||
name: Some(env!("CARGO_CRATE_NAME").to_owned()),
|
name: Some(env!("CARGO_PKG_NAME").to_owned()),
|
||||||
version: Some(env!("CARGO_PKG_VERSION").to_owned()),
|
version: Some(env!("CARGO_PKG_VERSION").to_owned()),
|
||||||
}),
|
}),
|
||||||
})
|
})
|
||||||
|
|
|
@ -1316,7 +1316,7 @@ impl Service {
|
||||||
// And are converted to:
|
// And are converted to:
|
||||||
// <code>-V, --version</code>: Prints version information
|
// <code>-V, --version</code>: Prints version information
|
||||||
// (?m) enables multi-line mode for ^ and $
|
// (?m) enables multi-line mode for ^ and $
|
||||||
let re = Regex::new("(?m)^ (([a-zA-Z_&;-]+(, )?)+) +(.*)$")
|
let re = Regex::new("(?m)^ {4}(([a-zA-Z_&;-]+(, )?)+) +(.*)$")
|
||||||
.expect("Regex compilation should not fail");
|
.expect("Regex compilation should not fail");
|
||||||
let text = re.replace_all(&text, "<code>$1</code>: $4");
|
let text = re.replace_all(&text, "<code>$1</code>: $4");
|
||||||
|
|
||||||
|
@ -1348,13 +1348,13 @@ impl Service {
|
||||||
// Improve the usage section
|
// Improve the usage section
|
||||||
let text = if command_body.is_empty() {
|
let text = if command_body.is_empty() {
|
||||||
// Wrap the usage line in code tags
|
// Wrap the usage line in code tags
|
||||||
let re = Regex::new("(?m)^USAGE:\n (@conduit:.*)$")
|
let re = Regex::new("(?m)^USAGE:\n {4}(@conduit:.*)$")
|
||||||
.expect("Regex compilation should not fail");
|
.expect("Regex compilation should not fail");
|
||||||
re.replace_all(&text, "USAGE:\n<code>$1</code>").to_string()
|
re.replace_all(&text, "USAGE:\n<code>$1</code>").to_string()
|
||||||
} else {
|
} else {
|
||||||
// Wrap the usage line in a code block, and add a yaml block example
|
// Wrap the usage line in a code block, and add a yaml block example
|
||||||
// This makes the usage of e.g. `register-appservice` more accurate
|
// This makes the usage of e.g. `register-appservice` more accurate
|
||||||
let re = Regex::new("(?m)^USAGE:\n (.*?)\n\n")
|
let re = Regex::new("(?m)^USAGE:\n {4}(.*?)\n\n")
|
||||||
.expect("Regex compilation should not fail");
|
.expect("Regex compilation should not fail");
|
||||||
re.replace_all(&text, "USAGE:\n<pre>$1[nobr]\n[commandbodyblock]</pre>")
|
re.replace_all(&text, "USAGE:\n<pre>$1[nobr]\n[commandbodyblock]</pre>")
|
||||||
.replace("[commandbodyblock]", &command_body)
|
.replace("[commandbodyblock]", &command_body)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue