Skip to content
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

feat: 「?」「!」のあとに全角スペースがない文章を検出する #621

Merged
merged 4 commits into from
Mar 3, 2025

Conversation

azusa-harashima
Copy link
Contributor

@azusa-harashima azusa-harashima commented Feb 26, 2025

課題・背景

https://smarthr.atlassian.net/browse/SD-991

やったこと

やらなかったこと

  • とくになし

動作確認

「?」「!」のあとに全角スペースがない文章を検出したい。が、下記を除外したい

  • 行頭が1つ以上の#で始まる文
  • 文頭がQで始まる文
  • 「?」「!」のあとに]や」で終わる文

検証文字列

Q.これは正しい例文です?はい。
注意!すぐに対応してください。
どうしましょうか?早急に決定が必要です。
本当に? ほんまにかい
# なぜなぜ?
彼は「なぜ?」と尋ねました。
[なぜ?]と尋ねました。

検証結果

https://rubular.com/

  • 「!」と「?」の後に全角スペースを入れず、文章が続くケースが検出される

screenshot 49

@chick-p chick-p changed the title SD-991にともなうtextlintルールの追加 feat: SD-991にともなうtextlintルールの追加 Feb 27, 2025
Copy link
Contributor

@chick-p chick-p left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

気になったところをコメントしました!

Copy link
Contributor

@chick-p chick-p left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@azusa-harashima
Copy link
Contributor Author

azusa-harashima commented Feb 28, 2025

メモ:マージするタイミングになったらpiyoさんに連絡する

@chick-p chick-p changed the title feat: SD-991にともなうtextlintルールの追加 feat: 「?」「!」のあとに全角スペースがない文章を検出する Mar 3, 2025
@chick-p chick-p merged commit 46975d4 into main Mar 3, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants