summaryrefslogtreecommitdiff
path: root/lib/gitlab_ci_yaml_parser.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gitlab_ci_yaml_parser.rb')
-rw-r--r--lib/gitlab_ci_yaml_parser.rb31
1 files changed, 0 insertions, 31 deletions
diff --git a/lib/gitlab_ci_yaml_parser.rb b/lib/gitlab_ci_yaml_parser.rb
deleted file mode 100644
index 51458ad..0000000
--- a/lib/gitlab_ci_yaml_parser.rb
+++ /dev/null
@@ -1,31 +0,0 @@
-# Prototype of parser
-
-class GitlabCiYamlParser
- attr_reader :before_script, :jobs, :on_success
-
- def initialize(config)
- @before_script = ["pwd"]
- @jobs = [{script: "ruby -v", runner: "", name: "Rspec"}]
- @on_success = [script: "cap deploy production", refs: [], name: "Deploy"]
- end
-
- def builds
- @jobs.map do |job|
- {
- name: job[:name],
- commands: "#{@before_script.join("\n")}\n#{job[:script]}"
- }
- end
- end
-
- def deploy_builds
- @on_success.map do |job|
- {
- name: job[:name],
- commands: "#{@before_script.join("\n")}\n#{job[:script]}",
- deploy: true,
- refs: job[:refs]
- }
- end
- end
-end \ No newline at end of file