diff --git a/CHANGELOG.md b/CHANGELOG.md
index 9ba50ce..262eb8d 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,6 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## [Unreleased]
+### Fixed
+
+* Parse the new rustfmt file and line number format
+
+ The format changed in https://github.com/rust-lang/rustfmt/pull/5971
+
+ Thanks to @0xcypher02 for pointing out the problem.
+
## [1.1.0] - 2022-11-21
### Added
diff --git a/action.yml b/action.yml
index 7b5816e..2ed6026 100644
--- a/action.yml
+++ b/action.yml
@@ -41,12 +41,12 @@ runs:
echo "${CARGO_OUTPUT}" |
# Strip color codes
- sed 's/\x1B\[[0-9;]*[A-Za-z]//g' |
+ sed 's/\x1B\[[0-9;]*[A-Za-z]\x0f\?//g' |
# Strip (some) cursor movements
sed 's/\x1B.[A-G]//g' |
tr "\n" "\r" |
# Wrap each location into a HTML details
- sed -E 's#Diff in ([^\r]*?) at line ([[:digit:]]+):\r((:?[ +-][^\r]*\r)+)#\n\1:\2
\n\n```diff\n\3```\n\n \n\n#g' |
+ sed -E 's#Diff in ([^\r]*?)( at line |:)([[:digit:]]+):\r((:?[ +-][^\r]*\r)+)#\n\1:\3
\n\n```diff\n\4```\n\n \n\n#g' |
tr "\r" "\n" >> $GITHUB_STEP_SUMMARY
fi