Commit aebf2ca9 authored by Amy Qualls's avatar Amy Qualls Committed by Marcel Amirault

URLs in curl commands should be quoted

Attempts to create a Vale rule for identifying curl commands with
URLs that are not escaped in quotation marks.
parent 3b51b911
---
# Error: gitlab.CurlStringsQuoted
#
# Ensures all codeblocks using curl quote any URL strings.
#
# For a list of all options, see https://errata-ai.github.io/vale/styles/
extends: existence
message: 'Curl commands must wrap URLs in double quotes ("): %s'
link: https://docs.gitlab.com/ee/development/documentation/styleguide.html#code-blocks
level: warning
scope: code
raw:
- 'curl.*[^"=]https?://.*'
......@@ -1614,7 +1614,7 @@ Rendered example:
- Wherever needed use this personal access token: `<your_access_token>`.
- Always put the request first. `GET` is the default so you don't have to
include it.
- Use double quotes to the URL when it includes additional parameters.
- Wrap the URL in double quotes (`"`).
- Prefer to use examples using the personal access token and don't pass data of
username and password.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment