summaryrefslogtreecommitdiff
path: root/tasks
diff options
context:
space:
mode:
authorTom Duffield <tom@chef.io>2017-07-20 13:57:28 -0500
committerTom Duffield <tom@chef.io>2017-07-24 10:15:17 -0500
commit43616bb699dccad598c88df55682d2a7821ad7ee (patch)
tree084c41ee85a9036beee53ac9effc96c43ec1df7b /tasks
parent89d13b94b7de1d4d16304065425c3349d1222148 (diff)
downloadchef-43616bb699dccad598c88df55682d2a7821ad7ee.tar.gz
Update Expeditor config to use new Merge and Artifact Actionstduffield/use-new-artifact-actions
Chef Expeditor now supports built in merge and artifact actions which allow us to reduce the burden of duplicating common processes across all our repositories. This change introduces several of these built_in functions, replacing functionality that was previously kept in our Rakefile. Signed-off-by: Tom Duffield <tom@chef.io>
Diffstat (limited to 'tasks')
-rw-r--r--tasks/changelog.rb37
-rw-r--r--tasks/version.rb41
2 files changed, 0 insertions, 78 deletions
diff --git a/tasks/changelog.rb b/tasks/changelog.rb
deleted file mode 100644
index 74ac704abf..0000000000
--- a/tasks/changelog.rb
+++ /dev/null
@@ -1,37 +0,0 @@
-begin
- require "github_changelog_generator/task"
- require "mixlib/install"
-
- namespace :changelog do
- # Fetch the latest version from mixlib-install
- def latest_stable_version
- # for 13.1, a 12.20 release was made after 13.0, which is busting the changelog generator. Reset this post 13.1 release
- "13.0.118"
- # Mixlib::Install.available_versions("chef", "stable").last
- end
-
- # Take the changelog from the latest stable release and put it into history.
- task :archive do
- changelog = Net::HTTP.get(URI("https://raw.githubusercontent.com/chef/chef/v#{latest_stable_version}/CHANGELOG.md")).chomp.split("\n")
- File.open("HISTORY.md", "w+") { |f| f.write(changelog[2..-4].join("\n")) }
- end
-
- # Run this to just update the changelog for the current release. This will
- # take what is in HISTORY and generate a changelog of PRs between the most
- # recent stable version and HEAD.
- GitHubChangelogGenerator::RakeTask.new :update do |config|
- config.future_release = "v#{Chef::VERSION}"
- config.between_tags = ["v#{latest_stable_version}", "v#{Chef::VERSION}"]
- config.max_issues = 0
- config.add_issues_wo_labels = false
- config.enhancement_labels = "enhancement,Enhancement,New Feature,Feature".split(",")
- config.bug_labels = "bug,Bug,Improvement,Upstream Bug".split(",")
- config.exclude_labels = "duplicate,question,invalid,wontfix,no_changelog,Exclude From Changelog,Question,Discussion,Meta: Exclude From Changelog".split(",")
- config.header = "This changelog reflects the current state of chef's master branch on github and may not reflect the current released version of chef, which is [![Gem Version](https://badge.fury.io/rb/chef.svg)](https://badge.fury.io/rb/chef)."
- end
- end
-
- task :changelog => "changelog:update"
-rescue LoadError
- puts "github_changelog_generator is not available. gem install github_changelog_generator to generate changelogs"
-end
diff --git a/tasks/version.rb b/tasks/version.rb
deleted file mode 100644
index e1fd538f68..0000000000
--- a/tasks/version.rb
+++ /dev/null
@@ -1,41 +0,0 @@
-#
-# Copyright:: Copyright 2017 Chef Software, Inc.
-# License:: Apache License, Version 2.0
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-#     http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-#
-
-task :ci_version_bump do
- begin
- require "rake"
-
- Rake::Task["version:bump_patch"].invoke
- Rake::Task["version:update"].invoke
-
- # We want to log errors that occur in the following tasks, but we don't
- # want them to stop an otherwise valid version bump from progressing.
- begin
- Rake::Task["changelog:update"].invoke
- rescue Exception => e
- puts "There was an error updating the CHANGELOG"
- puts e
- end
-
- begin
- Rake::Task["update_dockerfile"].invoke
- rescue Exception => e
- puts "There was an error updating the Dockerfile"
- puts e
- end
- end
-end