diff --git a/app/graphql/resolvers/echo_resolver.rb b/app/graphql/resolvers/echo_resolver.rb index 2ce55544254e0ab5d899f9b43e067a51444c6536..fe0b1893a232b8e7a33f01b9beee381e1c00e65e 100644 --- a/app/graphql/resolvers/echo_resolver.rb +++ b/app/graphql/resolvers/echo_resolver.rb @@ -2,9 +2,11 @@ module Resolvers class EchoResolver < BaseResolver - argument :text, GraphQL::STRING_TYPE, required: true # rubocop:disable Graphql/Descriptions description 'Testing endpoint to validate the API with' + argument :text, GraphQL::STRING_TYPE, required: true, + description: 'Text to echo back' + def resolve(**args) username = context[:current_user]&.username diff --git a/app/graphql/resolvers/issues_resolver.rb b/app/graphql/resolvers/issues_resolver.rb index 0ecf5f50e86e30c3eb25d9c14a1a59074ccc0901..664e0955535e1d31f05dc60c90e20856dc76da72 100644 --- a/app/graphql/resolvers/issues_resolver.rb +++ b/app/graphql/resolvers/issues_resolver.rb @@ -4,17 +4,17 @@ module Resolvers class IssuesResolver < BaseResolver argument :iid, GraphQL::STRING_TYPE, required: false, - description: 'The IID of the issue, e.g., "1"' + description: 'IID of the issue. For example, "1"' argument :iids, [GraphQL::STRING_TYPE], required: false, - description: 'The list of IIDs of issues, e.g., [1, 2]' + description: 'List of IIDs of issues. For example, [1, 2]' argument :state, Types::IssuableStateEnum, required: false, - description: 'Current state of Issue' + description: 'Current state of this issue' argument :label_name, GraphQL::STRING_TYPE.to_list_type, required: false, - description: 'Labels applied to the Issue' + description: 'Labels applied to this issue' argument :created_before, Types::TimeType, required: false, description: 'Issues created before this date' @@ -33,8 +33,9 @@ module Resolvers argument :closed_after, Types::TimeType, required: false, description: 'Issues closed after this date' - argument :search, GraphQL::STRING_TYPE, # rubocop:disable Graphql/Descriptions - required: false + argument :search, GraphQL::STRING_TYPE, + required: false, + description: 'Search query for finding issues by title or description' argument :sort, Types::IssueSortEnum, description: 'Sort issues by this criteria', required: false, diff --git a/app/graphql/types/diff_refs_type.rb b/app/graphql/types/diff_refs_type.rb index 33a5780cd68380be4e0a581c8023008e7ac8b3b1..03d080d784bb8ad995137373f52925afcf449b47 100644 --- a/app/graphql/types/diff_refs_type.rb +++ b/app/graphql/types/diff_refs_type.rb @@ -6,9 +6,12 @@ module Types class DiffRefsType < BaseObject graphql_name 'DiffRefs' - field :head_sha, GraphQL::STRING_TYPE, null: false, description: 'The sha of the head at the time the comment was made' - field :base_sha, GraphQL::STRING_TYPE, null: false, description: 'The merge base of the branch the comment was made on' - field :start_sha, GraphQL::STRING_TYPE, null: false, description: 'The sha of the branch being compared against' + field :head_sha, GraphQL::STRING_TYPE, null: false, + description: 'SHA of the HEAD at the time the comment was made' + field :base_sha, GraphQL::STRING_TYPE, null: false, + description: 'Merge base of the branch the comment was made on' + field :start_sha, GraphQL::STRING_TYPE, null: false, + description: 'SHA of the branch being compared against' end # rubocop: enable Graphql/AuthorizeTypes end diff --git a/app/graphql/types/notes/diff_position_type.rb b/app/graphql/types/notes/diff_position_type.rb index cab8c750dc04cb59e4c81a856ff533fee42c4c91..654562da0a7a04fe4c27bc6cde3d80d1d9c36199 100644 --- a/app/graphql/types/notes/diff_position_type.rb +++ b/app/graphql/types/notes/diff_position_type.rb @@ -7,36 +7,38 @@ module Types class DiffPositionType < BaseObject graphql_name 'DiffPosition' - field :diff_refs, Types::DiffRefsType, null: false # rubocop:disable Graphql/Descriptions + field :diff_refs, Types::DiffRefsType, null: false, + description: 'Information about the branch, HEAD, and base at the time of commenting' field :file_path, GraphQL::STRING_TYPE, null: false, - description: "The path of the file that was changed" + description: 'Path of the file that was changed' field :old_path, GraphQL::STRING_TYPE, null: true, - description: "The path of the file on the start sha." + description: 'Path of the file on the start SHA' field :new_path, GraphQL::STRING_TYPE, null: true, - description: "The path of the file on the head sha." - field :position_type, Types::Notes::PositionTypeEnum, null: false # rubocop:disable Graphql/Descriptions + description: 'Path of the file on the HEAD SHA' + field :position_type, Types::Notes::PositionTypeEnum, null: false, + description: 'Type of file the position refers to' # Fields for text positions field :old_line, GraphQL::INT_TYPE, null: true, - description: "The line on start sha that was changed", + description: 'Line on start SHA that was changed', resolve: -> (position, _args, _ctx) { position.old_line if position.on_text? } field :new_line, GraphQL::INT_TYPE, null: true, - description: "The line on head sha that was changed", + description: 'Line on HEAD SHA that was changed', resolve: -> (position, _args, _ctx) { position.new_line if position.on_text? } # Fields for image positions field :x, GraphQL::INT_TYPE, null: true, - description: "The X postion on which the comment was made", + description: 'X position on which the comment was made', resolve: -> (position, _args, _ctx) { position.x if position.on_image? } field :y, GraphQL::INT_TYPE, null: true, - description: "The Y position on which the comment was made", + description: 'Y position on which the comment was made', resolve: -> (position, _args, _ctx) { position.y if position.on_image? } field :width, GraphQL::INT_TYPE, null: true, - description: "The total width of the image", + description: 'Total width of the image', resolve: -> (position, _args, _ctx) { position.width if position.on_image? } field :height, GraphQL::INT_TYPE, null: true, - description: "The total height of the image", + description: 'Total height of the image', resolve: -> (position, _args, _ctx) { position.height if position.on_image? } end # rubocop: enable Graphql/AuthorizeTypes diff --git a/app/graphql/types/notes/discussion_type.rb b/app/graphql/types/notes/discussion_type.rb index ab87f8280aca83182b2e60f04b338bee8762ff6e..74a233e9d261f53e7b3d894aa1cd3a5a8432d43b 100644 --- a/app/graphql/types/notes/discussion_type.rb +++ b/app/graphql/types/notes/discussion_type.rb @@ -7,10 +7,14 @@ module Types authorize :read_note - field :id, GraphQL::ID_TYPE, null: false # rubocop:disable Graphql/Descriptions - field :reply_id, GraphQL::ID_TYPE, null: false, description: 'The ID used to reply to this discussion' - field :created_at, Types::TimeType, null: false # rubocop:disable Graphql/Descriptions - field :notes, Types::Notes::NoteType.connection_type, null: false, description: "All notes in the discussion" + field :id, GraphQL::ID_TYPE, null: false, + description: "ID of this discussion" + field :reply_id, GraphQL::ID_TYPE, null: false, + description: 'ID used to reply to this discussion' + field :created_at, Types::TimeType, null: false, + description: "Timestamp of the discussion's creation" + field :notes, Types::Notes::NoteType.connection_type, null: false, + description: 'All notes in the discussion' # The gem we use to generate Global IDs is hard-coded to work with # `id` properties. To generate a GID for the `reply_id` property, diff --git a/app/graphql/types/notes/note_type.rb b/app/graphql/types/notes/note_type.rb index 4edf6ed90f762af9161b3f6aef8b6d6d55b46c0e..b60fc96bd031786edf529dd0e0d3fb4c71e8756d 100644 --- a/app/graphql/types/notes/note_type.rb +++ b/app/graphql/types/notes/note_type.rb @@ -9,40 +9,48 @@ module Types expose_permissions Types::PermissionTypes::Note - field :id, GraphQL::ID_TYPE, null: false # rubocop:disable Graphql/Descriptions + field :id, GraphQL::ID_TYPE, null: false, + description: 'ID of the note' field :project, Types::ProjectType, null: true, - description: "The project this note is associated to", + description: 'Project associated with the note', resolve: -> (note, args, context) { Gitlab::Graphql::Loaders::BatchModelLoader.new(Project, note.project_id).find } field :author, Types::UserType, null: false, - description: "The user who wrote this note", + description: 'User who wrote this note', resolve: -> (note, args, context) { Gitlab::Graphql::Loaders::BatchModelLoader.new(User, note.author_id).find } field :resolved_by, Types::UserType, null: true, - description: "The user that resolved the discussion", + description: 'User that resolved the discussion', resolve: -> (note, _args, _context) { Gitlab::Graphql::Loaders::BatchModelLoader.new(User, note.resolved_by_id).find } field :system, GraphQL::BOOLEAN_TYPE, null: false, - description: "Whether or not this note was created by the system or by a user" + description: 'Indicates whether this note was created by the system or by a user' field :body, GraphQL::STRING_TYPE, null: false, method: :note, - description: "The content note itself" + description: 'Content of the note' markdown_field :body_html, null: true, method: :note - field :created_at, Types::TimeType, null: false # rubocop:disable Graphql/Descriptions - field :updated_at, Types::TimeType, null: false # rubocop:disable Graphql/Descriptions - field :discussion, Types::Notes::DiscussionType, null: true, description: "The discussion this note is a part of" - field :resolvable, GraphQL::BOOLEAN_TYPE, null: false, method: :resolvable? # rubocop:disable Graphql/Descriptions - field :resolved_at, Types::TimeType, null: true, description: "The time the discussion was resolved" - field :position, Types::Notes::DiffPositionType, null: true, description: "The position of this note on a diff" + field :created_at, Types::TimeType, null: false, + description: 'Timestamp of the note creation' + field :updated_at, Types::TimeType, null: false, + description: "Timestamp of the note's last activity" + field :discussion, Types::Notes::DiscussionType, null: true, + description: 'The discussion this note is a part of' + field :resolvable, GraphQL::BOOLEAN_TYPE, null: false, + description: 'Indicates if this note can be resolved. That is, if it is a resolvable discussion or simply a standalone note', + method: :resolvable? + field :resolved_at, Types::TimeType, null: true, + description: "Timestamp of the note's resolution" + field :position, Types::Notes::DiffPositionType, null: true, + description: 'The position of this note on a diff' end end end diff --git a/app/graphql/types/query_type.rb b/app/graphql/types/query_type.rb index 06188d99490a816e0cf7a0949217c64627a8ff5f..199a6226c6d6970fb3638252d30fc56456e13904 100644 --- a/app/graphql/types/query_type.rb +++ b/app/graphql/types/query_type.rb @@ -35,6 +35,8 @@ module Types resolver: Resolvers::SnippetsResolver, description: 'Find Snippets visible to the current user' - field :echo, GraphQL::STRING_TYPE, null: false, resolver: Resolvers::EchoResolver # rubocop:disable Graphql/Descriptions + field :echo, GraphQL::STRING_TYPE, null: false, + description: 'Text to echo back', + resolver: Resolvers::EchoResolver end end diff --git a/doc/api/graphql/reference/gitlab_schema.graphql b/doc/api/graphql/reference/gitlab_schema.graphql index 1c3902aafcc5d7981918dc4c0044a0147ddaf19f..3cbc489f46449c53bc2e9fd6fe3f773c6b97388f 100644 --- a/doc/api/graphql/reference/gitlab_schema.graphql +++ b/doc/api/graphql/reference/gitlab_schema.graphql @@ -237,7 +237,7 @@ Autogenerated input type of CreateDiffNote """ input CreateDiffNoteInput { """ - The content note itself + Content of the note """ body: String! @@ -357,7 +357,7 @@ Autogenerated input type of CreateImageDiffNote """ input CreateImageDiffNoteInput { """ - The content note itself + Content of the note """ body: String! @@ -402,7 +402,7 @@ Autogenerated input type of CreateNote """ input CreateNoteInput { """ - The content note itself + Content of the note """ body: String! @@ -969,17 +969,17 @@ type DetailedStatus { input DiffImagePositionInput { """ - The merge base of the branch the comment was made on + Merge base of the branch the comment was made on """ baseSha: String """ - The sha of the head at the time the comment was made + SHA of the HEAD at the time the comment was made """ headSha: String! """ - The total height of the image + Total height of the image """ height: Int! @@ -990,22 +990,22 @@ input DiffImagePositionInput { paths: DiffPathsInput! """ - The sha of the branch being compared against + SHA of the branch being compared against """ startSha: String! """ - The total width of the image + Total width of the image """ width: Int! """ - The X postion on which the comment was made + X position on which the comment was made """ x: Int! """ - The Y position on which the comment was made + Y position on which the comment was made """ y: Int! } @@ -1023,73 +1023,80 @@ input DiffPathsInput { } type DiffPosition { + """ + Information about the branch, HEAD, and base at the time of commenting + """ diffRefs: DiffRefs! """ - The path of the file that was changed + Path of the file that was changed """ filePath: String! """ - The total height of the image + Total height of the image """ height: Int """ - The line on head sha that was changed + Line on HEAD SHA that was changed """ newLine: Int """ - The path of the file on the head sha. + Path of the file on the HEAD SHA """ newPath: String """ - The line on start sha that was changed + Line on start SHA that was changed """ oldLine: Int """ - The path of the file on the start sha. + Path of the file on the start SHA """ oldPath: String + + """ + Type of file the position refers to + """ positionType: DiffPositionType! """ - The total width of the image + Total width of the image """ width: Int """ - The X postion on which the comment was made + X position on which the comment was made """ x: Int """ - The Y position on which the comment was made + Y position on which the comment was made """ y: Int } input DiffPositionInput { """ - The merge base of the branch the comment was made on + Merge base of the branch the comment was made on """ baseSha: String """ - The sha of the head at the time the comment was made + SHA of the HEAD at the time the comment was made """ headSha: String! """ - The line on head sha that was changed + Line on HEAD SHA that was changed """ newLine: Int! """ - The line on start sha that was changed + Line on start SHA that was changed """ oldLine: Int @@ -1100,7 +1107,7 @@ input DiffPositionInput { paths: DiffPathsInput! """ - The sha of the branch being compared against + SHA of the branch being compared against """ startSha: String! } @@ -1115,23 +1122,30 @@ enum DiffPositionType { type DiffRefs { """ - The merge base of the branch the comment was made on + Merge base of the branch the comment was made on """ baseSha: String! """ - The sha of the head at the time the comment was made + SHA of the HEAD at the time the comment was made """ headSha: String! """ - The sha of the branch being compared against + SHA of the branch being compared against """ startSha: String! } type Discussion { + """ + Timestamp of the discussion's creation + """ createdAt: Time! + + """ + ID of this discussion + """ id: ID! """ @@ -1160,7 +1174,7 @@ type Discussion { ): NoteConnection! """ - The ID used to reply to this discussion + ID used to reply to this discussion """ replyId: ID! } @@ -1259,12 +1273,12 @@ type Epic implements Noteable { first: Int """ - The IID of the epic, e.g., "1" + IID of the epic, e.g., "1" """ iid: ID """ - The list of IIDs of epics, e.g., [1, 2] + List of IIDs of epics, e.g., [1, 2] """ iids: [ID!] @@ -1672,7 +1686,15 @@ type EpicIssue implements Noteable { The GitLab Flavored Markdown rendering of `description` """ descriptionHtml: String + + """ + Collection of design images associated with this issue + """ designCollection: DesignCollection + + """ + Deprecated. Use `design_collection`. + """ designs: DesignCollection @deprecated(reason: "use design_collection") """ @@ -1716,13 +1738,17 @@ type EpicIssue implements Noteable { dueDate: Time """ - The epic to which issue belongs + Epic to which this issue belongs """ epic: Epic + + """ + ID of the epic-issue relation + """ epicIssueId: ID! """ - The global id of the epic-issue relation + Global ID of the epic-issue relation """ id: ID @@ -1820,6 +1846,10 @@ type EpicIssue implements Noteable { """ full: Boolean = false ): String! + + """ + URI path of the epic-issue relation + """ relationPath: String """ @@ -1891,6 +1921,10 @@ type EpicIssue implements Noteable { Web URL of the issue """ webUrl: String! + + """ + Weight of the issue + """ weight: Int } @@ -2135,6 +2169,10 @@ type Group { The GitLab Flavored Markdown rendering of `description` """ descriptionHtml: String + + """ + Find a single epic + """ epic( """ Filter epics by author @@ -2148,12 +2186,12 @@ type Group { endDate: Time """ - The IID of the epic, e.g., "1" + IID of the epic, e.g., "1" """ iid: ID """ - The list of IIDs of epics, e.g., [1, 2] + List of IIDs of epics, e.g., [1, 2] """ iids: [ID!] @@ -2183,6 +2221,10 @@ type Group { """ state: EpicState ): Epic + + """ + Find epics + """ epics( """ Returns the elements in the list that come after the specified cursor. @@ -2211,12 +2253,12 @@ type Group { first: Int """ - The IID of the epic, e.g., "1" + IID of the epic, e.g., "1" """ iid: ID """ - The list of IIDs of epics, e.g., [1, 2] + List of IIDs of epics, e.g., [1, 2] """ iids: [ID!] @@ -2459,7 +2501,15 @@ type Issue implements Noteable { The GitLab Flavored Markdown rendering of `description` """ descriptionHtml: String + + """ + Collection of design images associated with this issue + """ designCollection: DesignCollection + + """ + Deprecated. Use `design_collection`. + """ designs: DesignCollection @deprecated(reason: "use design_collection") """ @@ -2503,7 +2553,7 @@ type Issue implements Noteable { dueDate: Time """ - The epic to which issue belongs + Epic to which this issue belongs """ epic: Epic @@ -2671,6 +2721,10 @@ type Issue implements Noteable { Web URL of the issue """ webUrl: String! + + """ + Weight of the issue + """ weight: Int } @@ -3966,12 +4020,12 @@ type Namespace { type Note { """ - The user who wrote this note + User who wrote this note """ author: User! """ - The content note itself + Content of the note """ body: String! @@ -3979,12 +4033,20 @@ type Note { The GitLab Flavored Markdown rendering of `note` """ bodyHtml: String + + """ + Timestamp of the note creation + """ createdAt: Time! """ The discussion this note is a part of """ discussion: Discussion + + """ + ID of the note + """ id: ID! """ @@ -3993,25 +4055,33 @@ type Note { position: DiffPosition """ - The project this note is associated to + Project associated with the note """ project: Project + + """ + Indicates if this note can be resolved. That is, if it is a resolvable discussion or simply a standalone note + """ resolvable: Boolean! """ - The time the discussion was resolved + Timestamp of the note's resolution """ resolvedAt: Time """ - The user that resolved the discussion + User that resolved the discussion """ resolvedBy: User """ - Whether or not this note was created by the system or by a user + Indicates whether this note was created by the system or by a user """ system: Boolean! + + """ + Timestamp of the note's last activity + """ updatedAt: Time! """ @@ -4339,19 +4409,23 @@ type Project { createdBefore: Time """ - The IID of the issue, e.g., "1" + IID of the issue. For example, "1" """ iid: String """ - The list of IIDs of issues, e.g., [1, 2] + List of IIDs of issues. For example, [1, 2] """ iids: [String!] """ - Labels applied to the Issue + Labels applied to this issue """ labelName: [String] + + """ + Search query for finding issues by title or description + """ search: String """ @@ -4360,7 +4434,7 @@ type Project { sort: IssueSort = created_desc """ - Current state of Issue + Current state of this issue """ state: IssuableState @@ -4415,17 +4489,17 @@ type Project { first: Int """ - The IID of the issue, e.g., "1" + IID of the issue. For example, "1" """ iid: String """ - The list of IIDs of issues, e.g., [1, 2] + List of IIDs of issues. For example, [1, 2] """ iids: [String!] """ - Labels applied to the Issue + Labels applied to this issue """ labelName: [String] @@ -4433,6 +4507,10 @@ type Project { Returns the last _n_ elements from the list. """ last: Int + + """ + Search query for finding issues by title or description + """ search: String """ @@ -4441,7 +4519,7 @@ type Project { sort: IssueSort = created_desc """ - Current state of Issue + Current state of this issue """ state: IssuableState @@ -5031,9 +5109,14 @@ type Query { currentUser: User """ - Testing endpoint to validate the API with + Text to echo back """ - echo(text: String!): String! + echo( + """ + Text to echo back + """ + text: String! + ): String! """ Find a group @@ -6183,7 +6266,7 @@ Autogenerated input type of UpdateNote """ input UpdateNoteInput { """ - The content note itself + Content of the note """ body: String! diff --git a/doc/api/graphql/reference/gitlab_schema.json b/doc/api/graphql/reference/gitlab_schema.json index 0d24f80cde06141ebe450148084f81b8c1d04cad..e47e2c8056c2a881cdb84772a0c4c8b6c0237492 100644 --- a/doc/api/graphql/reference/gitlab_schema.json +++ b/doc/api/graphql/reference/gitlab_schema.json @@ -50,11 +50,11 @@ }, { "name": "echo", - "description": "Testing endpoint to validate the API with", + "description": "Text to echo back", "args": [ { "name": "text", - "description": null, + "description": "Text to echo back", "type": { "kind": "NON_NULL", "name": null, @@ -494,7 +494,7 @@ "args": [ { "name": "iid", - "description": "The IID of the issue, e.g., \"1\"", + "description": "IID of the issue. For example, \"1\"", "type": { "kind": "SCALAR", "name": "String", @@ -504,7 +504,7 @@ }, { "name": "iids", - "description": "The list of IIDs of issues, e.g., [1, 2]", + "description": "List of IIDs of issues. For example, [1, 2]", "type": { "kind": "LIST", "name": null, @@ -522,7 +522,7 @@ }, { "name": "state", - "description": "Current state of Issue", + "description": "Current state of this issue", "type": { "kind": "ENUM", "name": "IssuableState", @@ -532,7 +532,7 @@ }, { "name": "labelName", - "description": "Labels applied to the Issue", + "description": "Labels applied to this issue", "type": { "kind": "LIST", "name": null, @@ -606,7 +606,7 @@ }, { "name": "search", - "description": null, + "description": "Search query for finding issues by title or description", "type": { "kind": "SCALAR", "name": "String", @@ -639,7 +639,7 @@ "args": [ { "name": "iid", - "description": "The IID of the issue, e.g., \"1\"", + "description": "IID of the issue. For example, \"1\"", "type": { "kind": "SCALAR", "name": "String", @@ -649,7 +649,7 @@ }, { "name": "iids", - "description": "The list of IIDs of issues, e.g., [1, 2]", + "description": "List of IIDs of issues. For example, [1, 2]", "type": { "kind": "LIST", "name": null, @@ -667,7 +667,7 @@ }, { "name": "state", - "description": "Current state of Issue", + "description": "Current state of this issue", "type": { "kind": "ENUM", "name": "IssuableState", @@ -677,7 +677,7 @@ }, { "name": "labelName", - "description": "Labels applied to the Issue", + "description": "Labels applied to this issue", "type": { "kind": "LIST", "name": null, @@ -751,7 +751,7 @@ }, { "name": "search", - "description": null, + "description": "Search query for finding issues by title or description", "type": { "kind": "SCALAR", "name": "String", @@ -2973,11 +2973,11 @@ }, { "name": "epic", - "description": null, + "description": "Find a single epic", "args": [ { "name": "iid", - "description": "The IID of the epic, e.g., \"1\"", + "description": "IID of the epic, e.g., \"1\"", "type": { "kind": "SCALAR", "name": "ID", @@ -2987,7 +2987,7 @@ }, { "name": "iids", - "description": "The list of IIDs of epics, e.g., [1, 2]", + "description": "List of IIDs of epics, e.g., [1, 2]", "type": { "kind": "LIST", "name": null, @@ -3092,11 +3092,11 @@ }, { "name": "epics", - "description": null, + "description": "Find epics", "args": [ { "name": "iid", - "description": "The IID of the epic, e.g., \"1\"", + "description": "IID of the epic, e.g., \"1\"", "type": { "kind": "SCALAR", "name": "ID", @@ -3106,7 +3106,7 @@ }, { "name": "iids", - "description": "The list of IIDs of epics, e.g., [1, 2]", + "description": "List of IIDs of epics, e.g., [1, 2]", "type": { "kind": "LIST", "name": null, @@ -3693,7 +3693,7 @@ "args": [ { "name": "iid", - "description": "The IID of the epic, e.g., \"1\"", + "description": "IID of the epic, e.g., \"1\"", "type": { "kind": "SCALAR", "name": "ID", @@ -3703,7 +3703,7 @@ }, { "name": "iids", - "description": "The list of IIDs of epics, e.g., [1, 2]", + "description": "List of IIDs of epics, e.g., [1, 2]", "type": { "kind": "LIST", "name": null, @@ -4887,7 +4887,7 @@ "fields": [ { "name": "author", - "description": "The user who wrote this note", + "description": "User who wrote this note", "args": [ ], @@ -4905,7 +4905,7 @@ }, { "name": "body", - "description": "The content note itself", + "description": "Content of the note", "args": [ ], @@ -4937,7 +4937,7 @@ }, { "name": "createdAt", - "description": null, + "description": "Timestamp of the note creation", "args": [ ], @@ -4969,7 +4969,7 @@ }, { "name": "id", - "description": null, + "description": "ID of the note", "args": [ ], @@ -5001,7 +5001,7 @@ }, { "name": "project", - "description": "The project this note is associated to", + "description": "Project associated with the note", "args": [ ], @@ -5015,7 +5015,7 @@ }, { "name": "resolvable", - "description": null, + "description": "Indicates if this note can be resolved. That is, if it is a resolvable discussion or simply a standalone note", "args": [ ], @@ -5033,7 +5033,7 @@ }, { "name": "resolvedAt", - "description": "The time the discussion was resolved", + "description": "Timestamp of the note's resolution", "args": [ ], @@ -5047,7 +5047,7 @@ }, { "name": "resolvedBy", - "description": "The user that resolved the discussion", + "description": "User that resolved the discussion", "args": [ ], @@ -5061,7 +5061,7 @@ }, { "name": "system", - "description": "Whether or not this note was created by the system or by a user", + "description": "Indicates whether this note was created by the system or by a user", "args": [ ], @@ -5079,7 +5079,7 @@ }, { "name": "updatedAt", - "description": null, + "description": "Timestamp of the note's last activity", "args": [ ], @@ -6608,7 +6608,7 @@ "fields": [ { "name": "createdAt", - "description": null, + "description": "Timestamp of the discussion's creation", "args": [ ], @@ -6626,7 +6626,7 @@ }, { "name": "id", - "description": null, + "description": "ID of this discussion", "args": [ ], @@ -6701,7 +6701,7 @@ }, { "name": "replyId", - "description": "The ID used to reply to this discussion", + "description": "ID used to reply to this discussion", "args": [ ], @@ -6916,7 +6916,7 @@ "fields": [ { "name": "diffRefs", - "description": null, + "description": "Information about the branch, HEAD, and base at the time of commenting", "args": [ ], @@ -6934,7 +6934,7 @@ }, { "name": "filePath", - "description": "The path of the file that was changed", + "description": "Path of the file that was changed", "args": [ ], @@ -6952,7 +6952,7 @@ }, { "name": "height", - "description": "The total height of the image", + "description": "Total height of the image", "args": [ ], @@ -6966,7 +6966,7 @@ }, { "name": "newLine", - "description": "The line on head sha that was changed", + "description": "Line on HEAD SHA that was changed", "args": [ ], @@ -6980,7 +6980,7 @@ }, { "name": "newPath", - "description": "The path of the file on the head sha.", + "description": "Path of the file on the HEAD SHA", "args": [ ], @@ -6994,7 +6994,7 @@ }, { "name": "oldLine", - "description": "The line on start sha that was changed", + "description": "Line on start SHA that was changed", "args": [ ], @@ -7008,7 +7008,7 @@ }, { "name": "oldPath", - "description": "The path of the file on the start sha.", + "description": "Path of the file on the start SHA", "args": [ ], @@ -7022,7 +7022,7 @@ }, { "name": "positionType", - "description": null, + "description": "Type of file the position refers to", "args": [ ], @@ -7040,7 +7040,7 @@ }, { "name": "width", - "description": "The total width of the image", + "description": "Total width of the image", "args": [ ], @@ -7054,7 +7054,7 @@ }, { "name": "x", - "description": "The X postion on which the comment was made", + "description": "X position on which the comment was made", "args": [ ], @@ -7068,7 +7068,7 @@ }, { "name": "y", - "description": "The Y position on which the comment was made", + "description": "Y position on which the comment was made", "args": [ ], @@ -7095,7 +7095,7 @@ "fields": [ { "name": "baseSha", - "description": "The merge base of the branch the comment was made on", + "description": "Merge base of the branch the comment was made on", "args": [ ], @@ -7113,7 +7113,7 @@ }, { "name": "headSha", - "description": "The sha of the head at the time the comment was made", + "description": "SHA of the HEAD at the time the comment was made", "args": [ ], @@ -7131,7 +7131,7 @@ }, { "name": "startSha", - "description": "The sha of the branch being compared against", + "description": "SHA of the branch being compared against", "args": [ ], @@ -8116,7 +8116,7 @@ }, { "name": "designCollection", - "description": null, + "description": "Collection of design images associated with this issue", "args": [ ], @@ -8130,7 +8130,7 @@ }, { "name": "designs", - "description": null, + "description": "Deprecated. Use `design_collection`.", "args": [ ], @@ -8251,7 +8251,7 @@ }, { "name": "epic", - "description": "The epic to which issue belongs", + "description": "Epic to which this issue belongs", "args": [ ], @@ -8265,7 +8265,7 @@ }, { "name": "epicIssueId", - "description": null, + "description": "ID of the epic-issue relation", "args": [ ], @@ -8283,7 +8283,7 @@ }, { "name": "id", - "description": "The global id of the epic-issue relation", + "description": "Global ID of the epic-issue relation", "args": [ ], @@ -8519,7 +8519,7 @@ }, { "name": "relationPath", - "description": null, + "description": "URI path of the epic-issue relation", "args": [ ], @@ -8777,7 +8777,7 @@ }, { "name": "weight", - "description": null, + "description": "Weight of the issue", "args": [ ], @@ -9546,7 +9546,7 @@ }, { "name": "designCollection", - "description": null, + "description": "Collection of design images associated with this issue", "args": [ ], @@ -9560,7 +9560,7 @@ }, { "name": "designs", - "description": null, + "description": "Deprecated. Use `design_collection`.", "args": [ ], @@ -9681,7 +9681,7 @@ }, { "name": "epic", - "description": "The epic to which issue belongs", + "description": "Epic to which this issue belongs", "args": [ ], @@ -10161,7 +10161,7 @@ }, { "name": "weight", - "description": null, + "description": "Weight of the issue", "args": [ ], @@ -18139,7 +18139,7 @@ }, { "name": "body", - "description": "The content note itself", + "description": "Content of the note", "type": { "kind": "NON_NULL", "name": null, @@ -18265,7 +18265,7 @@ }, { "name": "body", - "description": "The content note itself", + "description": "Content of the note", "type": { "kind": "NON_NULL", "name": null, @@ -18314,7 +18314,7 @@ "inputFields": [ { "name": "headSha", - "description": "The sha of the head at the time the comment was made", + "description": "SHA of the HEAD at the time the comment was made", "type": { "kind": "NON_NULL", "name": null, @@ -18328,7 +18328,7 @@ }, { "name": "baseSha", - "description": "The merge base of the branch the comment was made on", + "description": "Merge base of the branch the comment was made on", "type": { "kind": "SCALAR", "name": "String", @@ -18338,7 +18338,7 @@ }, { "name": "startSha", - "description": "The sha of the branch being compared against", + "description": "SHA of the branch being compared against", "type": { "kind": "NON_NULL", "name": null, @@ -18366,7 +18366,7 @@ }, { "name": "oldLine", - "description": "The line on start sha that was changed", + "description": "Line on start SHA that was changed", "type": { "kind": "SCALAR", "name": "Int", @@ -18376,7 +18376,7 @@ }, { "name": "newLine", - "description": "The line on head sha that was changed", + "description": "Line on HEAD SHA that was changed", "type": { "kind": "NON_NULL", "name": null, @@ -18513,7 +18513,7 @@ }, { "name": "body", - "description": "The content note itself", + "description": "Content of the note", "type": { "kind": "NON_NULL", "name": null, @@ -18562,7 +18562,7 @@ "inputFields": [ { "name": "headSha", - "description": "The sha of the head at the time the comment was made", + "description": "SHA of the HEAD at the time the comment was made", "type": { "kind": "NON_NULL", "name": null, @@ -18576,7 +18576,7 @@ }, { "name": "baseSha", - "description": "The merge base of the branch the comment was made on", + "description": "Merge base of the branch the comment was made on", "type": { "kind": "SCALAR", "name": "String", @@ -18586,7 +18586,7 @@ }, { "name": "startSha", - "description": "The sha of the branch being compared against", + "description": "SHA of the branch being compared against", "type": { "kind": "NON_NULL", "name": null, @@ -18614,7 +18614,7 @@ }, { "name": "x", - "description": "The X postion on which the comment was made", + "description": "X position on which the comment was made", "type": { "kind": "NON_NULL", "name": null, @@ -18628,7 +18628,7 @@ }, { "name": "y", - "description": "The Y position on which the comment was made", + "description": "Y position on which the comment was made", "type": { "kind": "NON_NULL", "name": null, @@ -18642,7 +18642,7 @@ }, { "name": "width", - "description": "The total width of the image", + "description": "Total width of the image", "type": { "kind": "NON_NULL", "name": null, @@ -18656,7 +18656,7 @@ }, { "name": "height", - "description": "The total height of the image", + "description": "Total height of the image", "type": { "kind": "NON_NULL", "name": null, @@ -18762,7 +18762,7 @@ }, { "name": "body", - "description": "The content note itself", + "description": "Content of the note", "type": { "kind": "NON_NULL", "name": null, diff --git a/doc/api/graphql/reference/index.md b/doc/api/graphql/reference/index.md index 7e4ce1698627e92678ded28bdf59b68fe8908571..9ddbd08f32bea8bb3f3b1634630f98c7c8de9a11 100644 --- a/doc/api/graphql/reference/index.md +++ b/doc/api/graphql/reference/index.md @@ -178,33 +178,33 @@ The API can be explored interactively using the [GraphiQL IDE](../index.md#graph | Name | Type | Description | | --- | ---- | ---------- | -| `diffRefs` | DiffRefs! | | -| `filePath` | String! | The path of the file that was changed | -| `oldPath` | String | The path of the file on the start sha. | -| `newPath` | String | The path of the file on the head sha. | -| `positionType` | DiffPositionType! | | -| `oldLine` | Int | The line on start sha that was changed | -| `newLine` | Int | The line on head sha that was changed | -| `x` | Int | The X postion on which the comment was made | -| `y` | Int | The Y position on which the comment was made | -| `width` | Int | The total width of the image | -| `height` | Int | The total height of the image | +| `diffRefs` | DiffRefs! | Information about the branch, HEAD, and base at the time of commenting | +| `filePath` | String! | Path of the file that was changed | +| `oldPath` | String | Path of the file on the start SHA | +| `newPath` | String | Path of the file on the HEAD SHA | +| `positionType` | DiffPositionType! | Type of file the position refers to | +| `oldLine` | Int | Line on start SHA that was changed | +| `newLine` | Int | Line on HEAD SHA that was changed | +| `x` | Int | X position on which the comment was made | +| `y` | Int | Y position on which the comment was made | +| `width` | Int | Total width of the image | +| `height` | Int | Total height of the image | ### DiffRefs | Name | Type | Description | | --- | ---- | ---------- | -| `headSha` | String! | The sha of the head at the time the comment was made | -| `baseSha` | String! | The merge base of the branch the comment was made on | -| `startSha` | String! | The sha of the branch being compared against | +| `headSha` | String! | SHA of the HEAD at the time the comment was made | +| `baseSha` | String! | Merge base of the branch the comment was made on | +| `startSha` | String! | SHA of the branch being compared against | ### Discussion | Name | Type | Description | | --- | ---- | ---------- | -| `id` | ID! | | -| `replyId` | ID! | The ID used to reply to this discussion | -| `createdAt` | Time! | | +| `id` | ID! | ID of this discussion | +| `replyId` | ID! | ID used to reply to this discussion | +| `createdAt` | Time! | Timestamp of the discussion's creation | ### Epic @@ -281,13 +281,13 @@ The API can be explored interactively using the [GraphiQL IDE](../index.md#graph | `createdAt` | Time! | Timestamp of when the issue was created | | `updatedAt` | Time! | Timestamp of when the issue was last updated | | `taskCompletionStatus` | TaskCompletionStatus! | Task completion status of the issue | -| `epic` | Epic | The epic to which issue belongs | -| `weight` | Int | | -| `designs` | DesignCollection | | -| `designCollection` | DesignCollection | | -| `epicIssueId` | ID! | | -| `relationPath` | String | | -| `id` | ID | The global id of the epic-issue relation | +| `epic` | Epic | Epic to which this issue belongs | +| `weight` | Int | Weight of the issue | +| `designs` | DesignCollection | Deprecated. Use `design_collection`. | +| `designCollection` | DesignCollection | Collection of design images associated with this issue | +| `epicIssueId` | ID! | ID of the epic-issue relation | +| `relationPath` | String | URI path of the epic-issue relation | +| `id` | ID | Global ID of the epic-issue relation | ### EpicPermissions @@ -338,7 +338,7 @@ The API can be explored interactively using the [GraphiQL IDE](../index.md#graph | `parent` | Group | Parent group | | `epicsEnabled` | Boolean | Indicates if Epics are enabled for namespace | | `groupTimelogsEnabled` | Boolean | Indicates if Group timelogs are enabled for namespace | -| `epic` | Epic | | +| `epic` | Epic | Find a single epic | ### GroupPermissions @@ -376,10 +376,10 @@ The API can be explored interactively using the [GraphiQL IDE](../index.md#graph | `createdAt` | Time! | Timestamp of when the issue was created | | `updatedAt` | Time! | Timestamp of when the issue was last updated | | `taskCompletionStatus` | TaskCompletionStatus! | Task completion status of the issue | -| `epic` | Epic | The epic to which issue belongs | -| `weight` | Int | | -| `designs` | DesignCollection | | -| `designCollection` | DesignCollection | | +| `epic` | Epic | Epic to which this issue belongs | +| `weight` | Int | Weight of the issue | +| `designs` | DesignCollection | Deprecated. Use `design_collection`. | +| `designCollection` | DesignCollection | Collection of design images associated with this issue | ### IssuePermissions @@ -577,18 +577,18 @@ The API can be explored interactively using the [GraphiQL IDE](../index.md#graph | Name | Type | Description | | --- | ---- | ---------- | | `userPermissions` | NotePermissions! | Permissions for the current user on the resource | -| `id` | ID! | | -| `project` | Project | The project this note is associated to | -| `author` | User! | The user who wrote this note | -| `resolvedBy` | User | The user that resolved the discussion | -| `system` | Boolean! | Whether or not this note was created by the system or by a user | -| `body` | String! | The content note itself | +| `id` | ID! | ID of the note | +| `project` | Project | Project associated with the note | +| `author` | User! | User who wrote this note | +| `resolvedBy` | User | User that resolved the discussion | +| `system` | Boolean! | Indicates whether this note was created by the system or by a user | +| `body` | String! | Content of the note | | `bodyHtml` | String | The GitLab Flavored Markdown rendering of `note` | -| `createdAt` | Time! | | -| `updatedAt` | Time! | | +| `createdAt` | Time! | Timestamp of the note creation | +| `updatedAt` | Time! | Timestamp of the note's last activity | | `discussion` | Discussion | The discussion this note is a part of | -| `resolvable` | Boolean! | | -| `resolvedAt` | Time | The time the discussion was resolved | +| `resolvable` | Boolean! | Indicates if this note can be resolved. That is, if it is a resolvable discussion or simply a standalone note | +| `resolvedAt` | Time | Timestamp of the note's resolution | | `position` | DiffPosition | The position of this note on a diff | ### NotePermissions diff --git a/doc/api/projects.md b/doc/api/projects.md index 0327c458ca1f362b328c322cf4fce9414566f2e0..f2b5ed65cdad9d29e7142ba0fae3a10c0486a86e 100644 --- a/doc/api/projects.md +++ b/doc/api/projects.md @@ -1009,6 +1009,7 @@ POST /projects | `template_project_id` | integer | no | **(PREMIUM)** When used with `use_custom_template`, project ID of a custom project template. This is preferable to using `template_name` since `template_name` may be ambiguous. | | `use_custom_template` | boolean | no | **(PREMIUM)** Use either custom [instance](../user/admin_area/custom_project_templates.md) or [group](../user/group/custom_project_templates.md) (with `group_with_project_templates_id`) project template | | `group_with_project_templates_id` | integer | no | **(PREMIUM)** For group-level custom templates, specifies ID of group from which all the custom project templates are sourced. Leave empty for instance-level templates. Requires `use_custom_template` to be true | +| `packages_enabled` | boolean | no | **(PREMIUM ONLY)** Enable or disable packages repository feature | NOTE: **Note:** If your HTTP repository is not publicly accessible, add authentication information to the URL: `https://username:password@gitlab.company.com/group/project.git` @@ -1071,6 +1072,7 @@ POST /projects/user/:user_id | `template_name` | string | no | When used without `use_custom_template`, name of a [built-in project template](../gitlab-basics/create-project.md#built-in-templates). When used with `use_custom_template`, name of a custom project template | | `use_custom_template` | boolean | no | **(PREMIUM)** Use either custom [instance](../user/admin_area/custom_project_templates.md) or [group](../user/group/custom_project_templates.md) (with `group_with_project_templates_id`) project template | | `group_with_project_templates_id` | integer | no | **(PREMIUM)** For group-level custom templates, specifies ID of group from which all the custom project templates are sourced. Leave empty for instance-level templates. Requires `use_custom_template` to be true | +| `packages_enabled` | boolean | no | **(PREMIUM ONLY)** Enable or disable packages repository feature | NOTE: **Note:** If your HTTP repository is not publicly accessible, add authentication information to the URL: `https://username:password@gitlab.company.com/group/project.git` diff --git a/doc/ci/yaml/README.md b/doc/ci/yaml/README.md index cbfda209a897556d58c561f6bc32ccf4b49624ef..b718a745e47c525d382ca5d81831d3341d6d9306 100644 --- a/doc/ci/yaml/README.md +++ b/doc/ci/yaml/README.md @@ -2478,12 +2478,13 @@ sequentially from `job_name 1/N` to `job_name N/N`. For every job, `CI_NODE_INDEX` and `CI_NODE_TOTAL` [environment variables](../variables/README.md#predefined-environment-variables) are set. -Marking a job to be run in parallel requires only a simple addition to your configuration file: +Marking a job to be run in parallel requires adding `parallel` to your configuration +file. For example: -```diff - test: - script: rspec -+ parallel: 5 +```yaml +test: + script: rspec + parallel: 5 ``` TIP: **Tip:** @@ -2531,7 +2532,7 @@ triggers being used. #### Simple `trigger` syntax -The most simple way to configure a downstream trigger to use `trigger` keyword +The simplest way to configure a downstream trigger is to use `trigger` keyword with a full path to a downstream project: ```yaml @@ -2563,7 +2564,7 @@ staging: It is possible to mirror the status from a triggered pipeline: -``` +```yaml trigger_job: trigger: project: my/project @@ -2572,7 +2573,7 @@ trigger_job: It is possible to mirror the status from an upstream pipeline: -``` +```yaml upstream_bridge: stage: test needs: @@ -3286,7 +3287,7 @@ There are three possible values: `none`, `normal`, and `recursive`: - `normal` means that only the top-level submodules will be included. It is equivalent to: - ``` + ```shell git submodule sync git submodule update --init ``` @@ -3296,7 +3297,7 @@ There are three possible values: `none`, `normal`, and `recursive`: GitLab Runner with an executor not based on Docker, make sure the Git version meets that requirement. It is equivalent to: - ``` + ```shell git submodule sync --recursive git submodule update --init --recursive ``` @@ -3557,7 +3558,7 @@ Read more about the various [YAML features](https://learnxinyminutes.com/docs/ya If you want to temporarily 'disable' a job, rather than commenting out all the lines where the job is defined: -``` +```yaml #hidden_job: # script: # - run test diff --git a/doc/gitlab-basics/README.md b/doc/gitlab-basics/README.md index 258a85d04743e3b718c001d61f60c7a107273870..0f95c9e0cb632de479fe58bbc4abf0d1fe2f559b 100644 --- a/doc/gitlab-basics/README.md +++ b/doc/gitlab-basics/README.md @@ -38,7 +38,7 @@ The following are guides to basic GitLab functionality: If you're familiar with Git on the command line, you can interact with your GitLab projects just as you would with any other Git repository. -These resources will help get further acclimated to working on the command line. +These resources will help you get further acclimated to working on the command line. - [Start using Git on the command line](start-using-git.md), for some simple Git commands. - [Command line basics](command-line-commands.md), to create and edit files using the command line. diff --git a/doc/user/analytics/cycle_analytics.md b/doc/user/analytics/cycle_analytics.md index c75f101b0e11127ae7b173be09dc2d853e7976ee..796cae708032e0a3e61083e2f35a026eed31dd27 100644 --- a/doc/user/analytics/cycle_analytics.md +++ b/doc/user/analytics/cycle_analytics.md @@ -153,6 +153,27 @@ A few notes: cycles, calculate their median time and the result is what the dashboard of Cycle Analytics is showing. +## Days to completion chart + +> [Introduced](https://gitlab.com/gitlab-org/gitlab/merge_requests/21631) in GitLab 12.6. + +This chart visually depicts the total number of days it takes for cycles to be completed. + +This chart uses the global page filters for displaying data based on the selected +group, projects, and timeframe. In addition, specific stages can be selected +from within the chart itself. + +### Enabling chart + +By default, this chart is disabled for self-managed instances. To enable it, ask an +administrator with Rails console access to run the following: + +```ruby +Feature.enable(:cycle_analytics_scatterplot_enabled) +``` + +This chart is enabled by default on GitLab.com. + ## Permissions The current permissions on the Project Cycle Analytics dashboard are: