lint: Set repository variable in tools/lint-commits.

refer to:
zulip/zulip#17506
This commit is contained in:
LoopThrough-i-j 2021-05-06 20:50:35 +05:30 committed by Tim Abbott
parent 4083849b5d
commit 470967cfdb

View file

@ -9,10 +9,12 @@
# The rules can be found in /.gitlint # The rules can be found in /.gitlint
repository="zulip/python-zulip-api"
if [[ " if [[ "
$(git remote -v) $(git remote -v)
" =~ ' " =~ '
'([^[:space:]]*)[[:space:]]*(https://github\.com/|ssh://git@github\.com/|git@github\.com:)zulip/python-zulip-api(\.git|/)?\ \(fetch\)' '([^[:space:]]*)[[:space:]]*(https://github\.com/|ssh://git@github\.com/|git@github\.com:)"$repository"(\.git|/)?\ \(fetch\)'
' ]]; then ' ]]; then
range="${BASH_REMATCH[1]}/master..HEAD" range="${BASH_REMATCH[1]}/master..HEAD"
else else