diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 9af24f5de..e1efee589 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,4 +1,4 @@ -**Commit Message**: +**Commit Message** -**Related Issues/PRs (if applicable)**: +**Related Issues/PRs (if applicable)** -**Special notes for reviewers (if applicable)**: +**Special notes for reviewers (if applicable)** " ]]; then + if [[ $BODY =~ "-->" ]]; then echo "PR description contains '-->'. Please remove all the comment out lines in the template after carefully reading them." exit 1 fi - if [[ ! $TITLE =~ "**Commit Message**:" ]]; then - echo "PR description must begin with '**Commit Message**:'." - exit 1 + - name: Check the first line matches '**Commit Message**' + run: | + first_line=$(echo -n "$BODY" | head -n 1) + trimmed_first_line=$(echo "$first_line" | sed 's/[[:space:]]*$//') + echo "$trimmed_first_line='$trimmed_first_line'" + if [[ "$trimmed_first_line" != "**Commit Message**" ]]; then + echo "The first line of the PR description must be '**Commit Message**'" + exit 1 fi title: @@ -63,3 +68,16 @@ jobs: The subject "{subject}" found in the pull request title "{title}" didn't match the configured pattern. Please ensure that the subject doesn't start with an uppercase character. + + - name: Check length of PR title + env: + # Do not use ${{ github.event.pull_request.title }} directly in run command. + TITLE: ${{ github.event.pull_request.title }} + # We want to make sure that each commit "subject" is under 60 characters not to + # be truncated in the git log as well as in the GitHub UI. + # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?id=bc7938deaca7f474918c41a0372a410049bd4e13#n664 + run: | + if (( ${#TITLE} >= 60 )); then + echo "The PR title is too long. Please keep it under 60 characters." + exit 1 + fi diff --git a/site/docs/getting-started/installation.md b/site/docs/getting-started/installation.md index 5325feae5..8983116a2 100644 --- a/site/docs/getting-started/installation.md +++ b/site/docs/getting-started/installation.md @@ -19,8 +19,6 @@ helm upgrade -i aieg oci://ghcr.io/envoyproxy/ai-gateway/ai-gateway-helm \ --namespace envoy-ai-gateway-system \ --create-namespace -kubectl wait --timeout=2m -n envoy-ai-gateway-system deployment/ai-gateway-controller --for=create - kubectl wait --timeout=2m -n envoy-ai-gateway-system deployment/ai-gateway-controller --for=condition=Available ```