summaryrefslogtreecommitdiff
path: root/app/graphql/types/tree/entry_type.rb
blob: b40e38ec9d1e7ab254014021cca58b3313023a7e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# frozen_string_literal: true
module Types
  module Tree
    module EntryType
      include Types::BaseInterface

      field :id, GraphQL::ID_TYPE, null: false,
            description: 'ID of the entry'
      field :sha, GraphQL::STRING_TYPE, null: false,
            description: 'Last commit sha for the entry', method: :id
      field :name, GraphQL::STRING_TYPE, null: false,
            description: 'Name of the entry'
      field :type, Tree::TypeEnum, null: false,
            description: 'Type of tree entry'
      field :path, GraphQL::STRING_TYPE, null: false,
            description: 'Path of the entry'
      field :flat_path, GraphQL::STRING_TYPE, null: false,
            description: 'Flat path of the entry'
    end
  end
end