Format Ruby code blocks

This commit is contained in:
Matisse Hack
2022-06-10 20:33:35 +00:00
parent ba53785804
commit 9e24b01628
+4 -5
View File
@@ -63,17 +63,16 @@ Add the following code to the ruby file:
``` Ruby
transform "DotNetCoreCLI@2" do |item|
projects = item["projects"]
command = item['command']
command = item["command"]
run_command = []
if(projects.include?("$"))
if(command.nil?)
command = "build"
end
if projects.include?("$")
command = "build" if command.nil?
run_command << "shopt -s globstar; for f in ./**/*.csproj; do dotnet #{command} $f #{item['arguments']} ; done"
else
run_command << "dotnet #{command} #{item['projects']} #{item['arguments']}"
end
{
shell: "bash",
run: run_command.join("\n")