lib/checklister/gitlab/project.rb
def all(options = {})
        query_options = DEFAULT_OPTIONS.merge options
        projects = []
        page = 1
        while page <= MAX_PAGES
          projects_per_page = @client.projects(query_options.merge(page: page))
          if projects_per_page == false || projects_per_page.empty?
            page = MAX_PAGES
            return projects
          else
            projects += projects_per_page.map { |p| ProjectDecorator.new(p).to_hash }
            page += 1
          end
        end
        projects
      end
# Get all gitlab's projects
# @param options [optional, Hash] query options
# @return [Array] and array of project's properties as Hash
Get all gitlab's projects
Get all gitlab ' s projects
def all(options = {})
        query_options = DEFAULT_OPTIONS.merge options
        projects = []
        page = 1
        while page <= MAX_PAGES
          projects_per_page = @client.projects(query_options.merge(page: page))
          if projects_per_page == false || projects_per_page.empty?
            page = MAX_PAGES
            return projects
          else
            projects += projects_per_page.map { |p| ProjectDecorator.new(p).to_hash }
            page += 1
          end
        end
        projects
      end
def all ( options = { } ) query_options = DEFAULT_OPTIONS . merge options projects = [ ] page = 1 while page <= MAX_PAGES projects_per_page = @client . projects ( query_options . merge ( page : page ) ) if projects_per_page == false || projects_per_page . empty? page = MAX_PAGES return projects else projects += projects_per_page . map { | p | ProjectDecorator . new ( p ) . to_hash } page += 1 end end projects end
Get all gitlab's projects
Get all gitlab ' s projects
and array of project's properties as Hash
and array of project ' s properties as Hash
Array
options
None