mirror of
https://github.com/ben-grande/qusal.git
synced 2025-07-26 16:05:26 -04:00
fix: lint GitHub issue and pull request templates
This commit is contained in:
parent
f46504afcb
commit
2a4b453b58
5 changed files with 49 additions and 28 deletions
10
.github/ISSUE_TEMPLATE/bug.md
vendored
10
.github/ISSUE_TEMPLATE/bug.md
vendored
|
@ -10,11 +10,11 @@ assignees: ''
|
||||||
|
|
||||||
I confirm that I have read the following resources:
|
I confirm that I have read the following resources:
|
||||||
|
|
||||||
- [How to troubleshoot Qusal](https://github.com/ben-grande/qusal/blob/main/docs/TROUBLESHOOT.md)
|
* [How to troubleshoot Qusal](https://github.com/ben-grande/qusal/blob/main/docs/TROUBLESHOOT.md)
|
||||||
- [How to ask questions The Smart Way](http://catb.org/esr/faqs/smart-questions.html)
|
* [How to ask questions The Smart Way](http://catb.org/esr/faqs/smart-questions.html)
|
||||||
- [Writing the perfect question](https://codeblog.jonskeet.uk/2010/08/29/writing-the-perfect-question/)
|
* [Writing the perfect question](https://codeblog.jonskeet.uk/2010/08/29/writing-the-perfect-question/)
|
||||||
- [Question checklist](https://codeblog.jonskeet.uk/2012/11/24/stack-overflow-question-checklist/)
|
* [Question checklist](https://codeblog.jonskeet.uk/2012/11/24/stack-overflow-question-checklist/)
|
||||||
- [Could you please make my preference the default?](https://www.qubes-os.org/faq/#could-you-please-make-my-preference-the-default)
|
* [Could you please make my preference the default?](https://www.qubes-os.org/faq/#could-you-please-make-my-preference-the-default)
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
If it doesn't affect a large user base, you will have more chance to get our
|
If it doesn't affect a large user base, you will have more chance to get our
|
||||||
|
|
12
.github/ISSUE_TEMPLATE/feat.md
vendored
12
.github/ISSUE_TEMPLATE/feat.md
vendored
|
@ -10,12 +10,12 @@ assignees: ''
|
||||||
|
|
||||||
I confirm that I have read the following resources:
|
I confirm that I have read the following resources:
|
||||||
|
|
||||||
- [How to contribute to Qusal](https://github.com/ben-grande/qusal/blob/main/docs/CONTRIBUTE.md)
|
* [How to contribute to Qusal](https://github.com/ben-grande/qusal/blob/main/docs/CONTRIBUTE.md)
|
||||||
- [How Qusal is designed](https://github.com/ben-grande/qusal/blob/main/docs/DESIGN.md)
|
* [How Qusal is designed](https://github.com/ben-grande/qusal/blob/main/docs/DESIGN.md)
|
||||||
- [How to ask questions The Smart Way](http://catb.org/esr/faqs/smart-questions.html)
|
* [How to ask questions The Smart Way](http://catb.org/esr/faqs/smart-questions.html)
|
||||||
- [Writing the perfect question](https://codeblog.jonskeet.uk/2010/08/29/writing-the-perfect-question/)
|
* [Writing the perfect question](https://codeblog.jonskeet.uk/2010/08/29/writing-the-perfect-question/)
|
||||||
- [Question checklist](https://codeblog.jonskeet.uk/2012/11/24/stack-overflow-question-checklist/)
|
* [Question checklist](https://codeblog.jonskeet.uk/2012/11/24/stack-overflow-question-checklist/)
|
||||||
- [Could you please make my preference the default?](https://www.qubes-os.org/faq/#could-you-please-make-my-preference-the-default)
|
* [Could you please make my preference the default?](https://www.qubes-os.org/faq/#could-you-please-make-my-preference-the-default)
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
If it doesn't affect a large user base, you will have more chance to get our
|
If it doesn't affect a large user base, you will have more chance to get our
|
||||||
|
|
10
.github/ISSUE_TEMPLATE/question.md
vendored
10
.github/ISSUE_TEMPLATE/question.md
vendored
|
@ -10,11 +10,11 @@ assignees: ''
|
||||||
|
|
||||||
I confirm that I have read the following resources:
|
I confirm that I have read the following resources:
|
||||||
|
|
||||||
- [How to troubleshoot Qusal](https://github.com/ben-grande/qusal/blob/main/docs/TROUBLESHOOT.md)
|
* [How to troubleshoot Qusal](https://github.com/ben-grande/qusal/blob/main/docs/TROUBLESHOOT.md)
|
||||||
- [How to ask questions The Smart Way](http://catb.org/esr/faqs/smart-questions.html)
|
* [How to ask questions The Smart Way](http://catb.org/esr/faqs/smart-questions.html)
|
||||||
- [Writing the perfect question](https://codeblog.jonskeet.uk/2010/08/29/writing-the-perfect-question/)
|
* [Writing the perfect question](https://codeblog.jonskeet.uk/2010/08/29/writing-the-perfect-question/)
|
||||||
- [Question checklist](https://codeblog.jonskeet.uk/2012/11/24/stack-overflow-question-checklist/)
|
* [Question checklist](https://codeblog.jonskeet.uk/2012/11/24/stack-overflow-question-checklist/)
|
||||||
- [Could you please make my preference the default?](https://www.qubes-os.org/faq/#could-you-please-make-my-preference-the-default)
|
* [Could you please make my preference the default?](https://www.qubes-os.org/faq/#could-you-please-make-my-preference-the-default)
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
If it doesn't affect a large user base, you will have more chance to get our
|
If it doesn't affect a large user base, you will have more chance to get our
|
||||||
|
|
4
.github/pull_request_template.md
vendored
4
.github/pull_request_template.md
vendored
|
@ -12,11 +12,11 @@ Before contributing, I, the opener of this request:
|
||||||
Lacking to check any of the above can result in the rejection of the
|
Lacking to check any of the above can result in the rejection of the
|
||||||
contribution without no further comment.
|
contribution without no further comment.
|
||||||
|
|
||||||
## What does this PR aims to accomplish?
|
## What does this PR aims to accomplish
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## What does this PR change?
|
## What does this PR change
|
||||||
<!-- Issues must be referenced if they exist
|
<!-- Issues must be referenced if they exist
|
||||||
https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/using-keywords-in-issues-and-pull-requests
|
https://docs.github.com/en/get-started/writing-on-github/working-with-advanced-formatting/using-keywords-in-issues-and-pull-requests
|
||||||
-->
|
-->
|
||||||
|
|
|
@ -12,6 +12,8 @@ command -v git >/dev/null ||
|
||||||
cd "$(git rev-parse --show-toplevel)" || exit 1
|
cd "$(git rev-parse --show-toplevel)" || exit 1
|
||||||
./scripts/requires-program.sh mdl
|
./scripts/requires-program.sh mdl
|
||||||
|
|
||||||
|
extra_files_rules="~MD002,~MD012,~MD022,~MD032,~MD041"
|
||||||
|
|
||||||
find_tool="find"
|
find_tool="find"
|
||||||
if command -v fd; then
|
if command -v fd; then
|
||||||
find_tool="fd"
|
find_tool="fd"
|
||||||
|
@ -21,21 +23,40 @@ fi
|
||||||
|
|
||||||
if test -n "${1-}"; then
|
if test -n "${1-}"; then
|
||||||
files=""
|
files=""
|
||||||
|
extra_files=""
|
||||||
for f in "$@"; do
|
for f in "$@"; do
|
||||||
test -f "$f" || continue
|
test -f "$f" || continue
|
||||||
extension="${f##*.}"
|
extension="${f##*.}"
|
||||||
case "$extension" in
|
case "$extension" in
|
||||||
md) files="$files $f";;
|
md)
|
||||||
*) continue;;
|
case "${f}" in
|
||||||
|
.github/*) extra_files="$extra_files $f"; continue;;
|
||||||
|
esac
|
||||||
|
files="$files $f";;
|
||||||
|
*)
|
||||||
|
continue
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
if test -n "${extra_files}"; then
|
||||||
|
mdl --rules ${extra_files_rules} ${extra_files}
|
||||||
|
fi
|
||||||
test -n "$files" || exit 0
|
test -n "$files" || exit 0
|
||||||
exec mdl ${files}
|
exec mdl ${files}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
case "${find_tool}" in
|
case "${find_tool}" in
|
||||||
fd|fdfind) files="$(${find_tool} . --extension=md)";;
|
fd|fdfind)
|
||||||
find) files="$(find minion.d/ -type f -name "*.md")";;
|
files="$(${find_tool} . --hidden --exclude .github --type=f --extension=md)"
|
||||||
|
extra_files="$(${find_tool} . --hidden --type=f --extension=md .github)"
|
||||||
|
;;
|
||||||
|
find)
|
||||||
|
files="$(find . -not -path './.github/*' -type f -name "*.md")"
|
||||||
|
extra_files="$(find .github -type f -name "*.md")"
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
if test -n "${extra_files}"; then
|
||||||
|
mdl --rules ${extra_files_rules} ${extra_files}
|
||||||
|
fi
|
||||||
exec mdl ${files}
|
exec mdl ${files}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue