BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
99ee39bf
Commit
99ee39bf
authored
Jun 09, 2016
by
Grzegorz Bizon
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add comments to new CI config classes and modules
parent
20ccd446
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
35 additions
and
2 deletions
+35
-2
config.rb
lib/gitlab/ci/config.rb
+3
-2
configurable.rb
lib/gitlab/ci/config/node/configurable.rb
+11
-0
entry.rb
lib/gitlab/ci/config/node/entry.rb
+3
-0
global.rb
lib/gitlab/ci/config/node/global.rb
+4
-0
null.rb
lib/gitlab/ci/config/node/null.rb
+6
-0
script.rb
lib/gitlab/ci/config/node/script.rb
+8
-0
No files found.
lib/gitlab/ci/config.rb
View file @
99ee39bf
module
Gitlab
module
Ci
##
# Base GitLab CI Configuration facade
#
class
Config
class
LoaderError
<
StandardError
;
end
delegate
:valid?
,
:errors
,
to: :@global
##
...
...
lib/gitlab/ci/config/node/configurable.rb
View file @
99ee39bf
...
...
@@ -2,6 +2,17 @@ module Gitlab
module
Ci
class
Config
module
Node
##
# This mixin is responsible for adding DSL, which purpose is to
# simplifly process of adding child nodes.
#
# This can be used only if parent node is a configuration entry that
# holds a hash as a configuration value, for example:
#
# job:
# script: ...
# artifacts: ...
#
module
Configurable
extend
ActiveSupport
::
Concern
...
...
lib/gitlab/ci/config/node/entry.rb
View file @
99ee39bf
...
...
@@ -2,6 +2,9 @@ module Gitlab
module
Ci
class
Config
module
Node
##
# Base abstract class for each configuration entry node.
#
class
Entry
class
InvalidError
<
StandardError
;
end
...
...
lib/gitlab/ci/config/node/global.rb
View file @
99ee39bf
...
...
@@ -2,6 +2,10 @@ module Gitlab
module
Ci
class
Config
module
Node
##
# This class represents a global entry - root node for entire
# GitLab CI Configuration file.
#
class
Global
<
Entry
include
Configurable
...
...
lib/gitlab/ci/config/node/null.rb
View file @
99ee39bf
module
Gitlab
module
Ci
class
Config
##
# This class represents a configuration entry that is not being used
# in configuration file.
#
# This implements Null Object pattern.
#
module
Node
class
Null
<
Entry
def
value
...
...
lib/gitlab/ci/config/node/script.rb
View file @
99ee39bf
...
...
@@ -2,6 +2,14 @@ module Gitlab
module
Ci
class
Config
module
Node
##
# Entry that represents a script.
#
# Each element in the value array is a command that will be executed
# by GitLab Runner. Currently we concatenate this commands with
# new line character as a separator what is compatbile with
# implementation in Runner.
#
class
Script
<
Entry
include
ValidationHelpers
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment