Compare commits

..

2 commits

4 changed files with 10 additions and 47 deletions

View file

@ -3,6 +3,13 @@
All notable changes to this project will be documented in this file. All notable changes to this project will be documented in this file.
## [v0.4.2](https://codeberg.org/ThetaDev/artifactview/compare/v0.4.1..v0.4.2) - 2024-06-22
### 🐛 Bug Fixes
- PR comment emoji prefix detection - ([ed0fbc3](https://codeberg.org/ThetaDev/artifactview/commit/ed0fbc38b2a1e76f070697f766812a20c84149ee))
## [v0.4.1](https://codeberg.org/ThetaDev/artifactview/compare/v0.4.0..v0.4.1) - 2024-06-22 ## [v0.4.1](https://codeberg.org/ThetaDev/artifactview/compare/v0.4.0..v0.4.1) - 2024-06-22
### 🚀 Features ### 🚀 Features

44
Cargo.lock generated
View file

@ -141,7 +141,7 @@ dependencies = [
[[package]] [[package]]
name = "artifactview" name = "artifactview"
version = "0.4.1" version = "0.4.2"
dependencies = [ dependencies = [
"async_zip", "async_zip",
"axum", "axum",
@ -187,7 +187,6 @@ dependencies = [
"tower-http", "tower-http",
"tracing", "tracing",
"tracing-subscriber", "tracing-subscriber",
"unic-emoji-char",
"url", "url",
"yarte", "yarte",
"yarte_helpers", "yarte_helpers",
@ -3145,47 +3144,6 @@ version = "0.1.4"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94"
[[package]]
name = "unic-char-property"
version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a8c57a407d9b6fa02b4795eb81c5b6652060a15a7903ea981f3d723e6c0be221"
dependencies = [
"unic-char-range",
]
[[package]]
name = "unic-char-range"
version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0398022d5f700414f6b899e10b8348231abf9173fa93144cbc1a43b9793c1fbc"
[[package]]
name = "unic-common"
version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "80d7ff825a6a654ee85a63e80f92f054f904f21e7d12da4e22f9834a4aaa35bc"
[[package]]
name = "unic-emoji-char"
version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0b07221e68897210270a38bde4babb655869637af0f69407f96053a34f76494d"
dependencies = [
"unic-char-property",
"unic-char-range",
"unic-ucd-version",
]
[[package]]
name = "unic-ucd-version"
version = "0.9.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "96bd2f2237fe450fcd0a1d2f5f4e91711124f7857ba2e964247776ebeeb7b0c4"
dependencies = [
"unic-common",
]
[[package]] [[package]]
name = "unicase" name = "unicase"
version = "2.7.0" version = "2.7.0"

View file

@ -1,6 +1,6 @@
[package] [package]
name = "artifactview" name = "artifactview"
version = "0.4.1" version = "0.4.2"
edition = "2021" edition = "2021"
authors = ["ThetaDev <thetadev@magenta.de>"] authors = ["ThetaDev <thetadev@magenta.de>"]
license = "MIT" license = "MIT"
@ -73,7 +73,6 @@ tokio-util = { version = "0.7.11", features = ["io"] }
tower-http = { version = "0.5.2", features = ["trace", "set-header"] } tower-http = { version = "0.5.2", features = ["trace", "set-header"] }
tracing = "0.1.40" tracing = "0.1.40"
tracing-subscriber = "0.3.18" tracing-subscriber = "0.3.18"
unic-emoji-char = "0.9.0"
url = "2.5.0" url = "2.5.0"
yarte = { version = "0.15.7", features = ["json"] } yarte = { version = "0.15.7", features = ["json"] }

View file

@ -871,8 +871,7 @@ fn pr_comment_text(p: PrCommentTextParams) -> String {
let mut title = Cow::Borrowed(title); let mut title = Cow::Borrowed(title);
if let Some((i, c)) = title if let Some((i, c)) = title
.char_indices() .char_indices()
// Some emoji use variation selectors that are not included in is_emoji .find(|(_, c)| c.is_ascii() || c.is_alphanumeric())
.find(|(_, c)| !unic_emoji_char::is_emoji(*c) && !('\u{fe00}'..='\u{fe0f}').contains(c))
{ {
if i > 0 && c == ' ' { if i > 0 && c == ' ' {
title[..i + 1].clone_into(&mut title_pfx); title[..i + 1].clone_into(&mut title_pfx);