File tree Expand file tree Collapse file tree 4 files changed +13
-2
lines changed Expand file tree Collapse file tree 4 files changed +13
-2
lines changed Original file line number Diff line number Diff line change 22
33[ Unreleased changes] ( https://github.com/bkeepers/dotenv/compare/v3.1.6...main )
44
5+ ## 3.1.7
6+
7+ * Fix issue with repeated linebreaks when normalizing line endings by @bkeepers in https://github.com/bkeepers/dotenv/pull/523
8+
9+ ** Full Changelog** : https://github.com/bkeepers/dotenv/compare/v3.1.6...v3.1.7
10+
511## 3.1.6
612
713* Fix: Restore previous parser behavior of returning existing variables by @bkeepers in https://github.com/bkeepers/dotenv/pull/519
Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ def call(...)
4343
4444 def initialize ( string , overwrite : false )
4545 # Convert line breaks to same format
46- @string = string . gsub ( /[ \n \r ]+ / , "\n " )
46+ @string = string . gsub ( /\r \n ? / , "\n " )
4747 @hash = { }
4848 @overwrite = overwrite
4949 end
Original file line number Diff line number Diff line change 11module Dotenv
2- VERSION = "3.1.6 " . freeze
2+ VERSION = "3.1.7 " . freeze
33end
Original file line number Diff line number Diff line change @@ -158,6 +158,11 @@ def env(...)
158158 . to eql ( "foo" => "bar" , "fizz" => "buzz" )
159159 end
160160
161+ it "does not ignore empty lines in quoted string" do
162+ value = "a\n \n b\n \n c"
163+ expect ( env ( "FOO=\" #{ value } \" " ) ) . to eql ( "FOO" => value )
164+ end
165+
161166 it "ignores inline comments" do
162167 expect ( env ( "foo=bar # this is foo" ) ) . to eql ( "foo" => "bar" )
163168 end
You can’t perform that action at this time.
0 commit comments