diff options
author | Dennis Hoppe <github@debian-solutions.de> | 2019-12-06 15:22:49 +0100 |
---|---|---|
committer | Dennis Hoppe <github@debian-solutions.de> | 2019-12-06 15:22:49 +0100 |
commit | d4106af027780bf3573b0ff8956caf3aa9f0e9bc (patch) | |
tree | 0c3596678b81e3241bcf8878004aed3e5160a3ce /Rakefile | |
parent | dd8ac301ea28927fd0494d9028ff059a836080a7 (diff) | |
download | puppet-ferm-d4106af027780bf3573b0ff8956caf3aa9f0e9bc.tar.gz puppet-ferm-d4106af027780bf3573b0ff8956caf3aa9f0e9bc.tar.bz2 |
modulesync 2.9.0
Diffstat (limited to 'Rakefile')
-rw-r--r-- | Rakefile | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -77,6 +77,19 @@ begin metadata = JSON.load(File.read(metadata_json)) config.project = metadata['name'] end + + # Workaround for https://github.com/github-changelog-generator/github-changelog-generator/issues/715 + require 'rbconfig' + if RbConfig::CONFIG['host_os'] =~ /linux/ + task :changelog do + puts 'Fixing line endings...' + changelog_file = File.join(__dir__, 'CHANGELOG.md') + changelog_txt = File.read(changelog_file) + new_contents = changelog_txt.gsub(%r{\r\n}, "\n") + File.open(changelog_file, "w") {|file| file.puts new_contents } + end + end + rescue LoadError end # vim: syntax=ruby |