You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: strip spaces and newlines from the comment before matching
We are now stripping spaces and newlines from the beginning and the end to make
sure that the regex matches correctly. The ^ will match the beginning of the
comment and $ will match the end of the comment without newlines or space.
Signed-off-by: Chmouel Boudjnah <[email protected]>
Copy file name to clipboardExpand all lines: docs/content/docs/guide/gitops_commands.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -104,9 +104,9 @@ grep "string" /tmp/comment
104
104
105
105
## Custom GitOps Commands
106
106
107
-
Using the [on-comment]({{< relref "/docs/guide/matchingevents.md#matching-a-pipelinerun-on-a-regexp-in-a-comment" >}}) annotation on your `PipelineRun`, you can define custom GitOps commands that will be triggered by comments on the Pull Request.
107
+
Using the [on-comment]({{< relref "/docs/guide/matchingevents.md#matching-a-pipelinerun-on-a-regex-in-a-comment" >}}) annotation on your `PipelineRun`, you can define custom GitOps commands that will be triggered by comments on the Pull Request.
108
108
109
-
See the [on-comment]({{< relref "/docs/guide/matchingevents.md#matching-a-pipelinerun-on-a-regexp-in-a-comment" >}}) guide for more detailed information.
109
+
See the [on-comment]({{< relref "/docs/guide/matchingevents.md#matching-a-pipelinerun-on-a-regex-in-a-comment" >}}) guide for more detailed information.
110
110
111
111
For a complete example, you can see how Pipelines-as-Code's own repo implemented some prow comments via the `on-comment` annotation:
You can match a PipelineRun on a comment on a Pull Request or a [Pushed Commit]({{< relref "/docs/guide/running.md#gitops-commands-on-pushed-commits">}})
184
-
with the annotation `pipelinesascode.tekton.dev/on-comment`.
183
+
You can trigger a PipelineRun based on a comment on a Pull Request or a [Pushed
184
+
Commit]({{< relref
185
+
"/docs/guide/running.md#gitops-commands-on-pushed-commits">}}) using the
0 commit comments