Skip to content

Commit

Permalink
Fix adding newlines everytime a skeleton is created.
Browse files Browse the repository at this point in the history
  • Loading branch information
UCSIG authored and UCSIG committed Feb 28, 2024
1 parent 9192a95 commit 7532b1d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/cmock_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,10 @@ def create_skeleton_source_file(mock_project)
if existing.empty?
create_source_header_section(file, fullname, blank_project)
else
file << existing << "\n"
file << existing
if existing[-1] != "\n"
file << "\n"
end
end
mock_project[:parsed_stuff][:functions].each do |function|
create_function_skeleton(file, function, existing)
Expand Down

0 comments on commit 7532b1d

Please sign in to comment.