diff options
| author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-03 18:08:29 +0000 |
|---|---|---|
| committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-03 18:08:29 +0000 |
| commit | 592223823c8ebf6e32d98e4b12620ba8ff043cca (patch) | |
| tree | 1c665b754b1487df374d9cb28cfc61ff40a6b317 /doc/development/documentation/styleguide.md | |
| parent | 0e13b2c71563d578805fc01fda9a4361f9f9d053 (diff) | |
| download | gitlab-ce-592223823c8ebf6e32d98e4b12620ba8ff043cca.tar.gz | |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/development/documentation/styleguide.md')
| -rw-r--r-- | doc/development/documentation/styleguide.md | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/doc/development/documentation/styleguide.md b/doc/development/documentation/styleguide.md index 949b6c19563..81f6ef43372 100644 --- a/doc/development/documentation/styleguide.md +++ b/doc/development/documentation/styleguide.md @@ -305,7 +305,7 @@ Do not include the same information in multiple places. ### References across documents -- Give each folder an index.md page that introduces the topic, introduces the +- Give each folder an `index.md` page that introduces the topic, introduces the pages within, and links to the pages within (including to the index pages of any next-level subpaths). - To ensure discoverability, ensure each new or renamed doc is linked from its @@ -642,8 +642,8 @@ Additional examples are available in the [Pajamas guide for punctuation](https:/ ### Placeholder text -Often in examples, a writer will provide a command or configuration that is -complete apart from a value specific to the reader. +Often in examples, a writer will provide a command or configuration that +uses values specific to the reader. In these cases, use [`<` and `>`](https://en.wikipedia.org/wiki/Usage_message#Pattern) to call out where a reader must replace text with their own value. @@ -1943,7 +1943,7 @@ METHOD /endpoint Example request: ```shell -curl --header "PRIVATE-TOKEN: <your_access_token>" 'https://gitlab.example.com/api/v4/endpoint?parameters' +curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/endpoint?parameters" ``` Example response: @@ -2038,7 +2038,7 @@ you can use in the API documentation. Get the details of a group: ```shell -curl --header "PRIVATE-TOKEN: <your_access_token>" https://gitlab.example.com/api/v4/groups/gitlab-org +curl --header "PRIVATE-TOKEN: <your_access_token>" "https://gitlab.example.com/api/v4/groups/gitlab-org" ``` #### cURL example with parameters passed in the URL @@ -2066,7 +2066,7 @@ In this example we create a new group. Watch carefully the single and double quotes. ```shell -curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" --header "Content-Type: application/json" --data '{"path": "my-group", "name": "My group"}' https://gitlab.example.com/api/v4/groups +curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" --header "Content-Type: application/json" --data '{"path": "my-group", "name": "My group"}' "https://gitlab.example.com/api/v4/groups" ``` #### Post data using form-data @@ -2075,7 +2075,7 @@ Instead of using JSON or urlencode you can use multipart/form-data which properly handles data encoding: ```shell -curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" --form "title=ssh-key" --form "key=ssh-rsa AAAAB3NzaC1yc2EA..." https://gitlab.example.com/api/v4/users/25/keys +curl --request POST --header "PRIVATE-TOKEN: <your_access_token>" --form "title=ssh-key" --form "key=ssh-rsa AAAAB3NzaC1yc2EA..." "https://gitlab.example.com/api/v4/users/25/keys" ``` The above example is run by and administrator and will add an SSH public key @@ -2101,7 +2101,7 @@ exclude specific users when requesting a list of users for a project, you would do something like this: ```shell -curl --request PUT --header "PRIVATE-TOKEN: <your_access_token>" --data "skip_users[]=<user_id>" --data "skip_users[]=<user_id>" https://gitlab.example.com/api/v4/projects/<project_id>/users +curl --request PUT --header "PRIVATE-TOKEN: <your_access_token>" --data "skip_users[]=<user_id>" --data "skip_users[]=<user_id>" "https://gitlab.example.com/api/v4/projects/<project_id>/users" ``` ## GraphQL API |
