Skip to content

Commit

Permalink
Merge pull request #41 from AckslD/fix-r-arguments
Browse files Browse the repository at this point in the history
fix: skip comma nodes
  • Loading branch information
AckslD authored Dec 23, 2024
2 parents e2f483d + 90e1c57 commit 86445d0
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lua/trevj.lua
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,11 @@ local settings = {
parameter_call_list = make_default_opts(),
},
r = {
arguments = make_no_final_sep_opts(),
arguments = {
final_separator = false,
final_end_line = true,
skip = { comma = true },
},
},
}, make_javascript_typescript_containers()),
}
Expand Down Expand Up @@ -226,7 +230,7 @@ local join_without_newline = function(opts, child, new_lines, lines)
else
sep = ""
end
new_lines[#new_lines] = new_lines[#new_lines] .. (sep or "") .. table.remove(lines, 1)
new_lines[#new_lines] = new_lines[#new_lines] .. sep .. table.remove(lines, 1)
vim.list_extend(new_lines, lines)
end

Expand Down

0 comments on commit 86445d0

Please sign in to comment.