Skip to content

Commit f475266

Browse files
committed
Include elasticsearch-xpack changes in CHANGELOG as part of update_verson rake task
1 parent 57fe5c2 commit f475266

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

Rakefile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ task :update_version, :old, :new do |task, args|
142142
log_entries[:api] = log.select { |l| l =~ /\[API\]/ }
143143
log_entries[:dsl] = log.select { |l| l =~ /\[DSL\]/ }
144144
log_entries[:ext] = log.select { |l| l =~ /\[EXT\]/ }
145+
log_entries[:xpack] = log.select { |l| l =~ /\[XPACK\]/ }
145146

146147
changelog = File.read(File.open('CHANGELOG.md', 'r'))
147148

@@ -187,6 +188,15 @@ task :update_version, :old, :new do |task, args|
187188
changelog_update << "\n\n"
188189
end
189190

191+
unless log_entries[:xpack].empty?
192+
changelog_update << "## XPACK:#{args[:new]}\n\n"
193+
changelog_update << log_entries[:xpack]
194+
.map { |l| l.gsub /\[XPACK\] /, '' }
195+
.map { |l| "#{l}" }
196+
.join("\n")
197+
changelog_update << "\n\n"
198+
end
199+
190200
File.open('CHANGELOG.md', 'w+') { |f| f.write changelog_update and f.write changelog }
191201

192202
puts "\n\n", "= DIFF ".ansi(:faint) + ('='*93).ansi(:faint)

0 commit comments

Comments
 (0)