Skip to content

Commit

Permalink
linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
johndbritton committed Dec 15, 2020
1 parent 4446c9b commit 477f555
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cmd/bundle.rb
Original file line number Diff line number Diff line change
@@ -110,7 +110,7 @@ def bundle
when "add"
Bundle::Commands::Add.run(
global: args.global?,
file: args.file
file: args.file,
)
when "dump"
Bundle::Commands::Dump.run(
3 changes: 2 additions & 1 deletion lib/bundle/commands/add.rb
Original file line number Diff line number Diff line change
@@ -19,12 +19,13 @@ def run(*args, global: false, file: nil)
parsed_entries.each do |entry|
# raise an error if the entry already exists in the Brewfile
# this could also be a noop, or print a friendly message
opoo "'#{name}' already exists in Brewfile."
raise RuntimeError if entry.name == name
end

# need some help / pointers here
# is it possible to use Bundle::Dsl to create an in memory representation
#of the brewfile that we read, add an entry and then dump that back to the file?
# of the brewfile that we read, add an entry and then dump that back to the file?
end
end
end
4 changes: 2 additions & 2 deletions spec/bundle/commands/add_command_spec.rb
Original file line number Diff line number Diff line change
@@ -23,11 +23,11 @@

context "the formula is not in the Brewfile" do
it "does not raise an error" do
expect { described_class.run("wget") }.to_not raise_error
expect { described_class.run("wget") }.not_to raise_error
end

it "adds the formula to the Brewfile" do
#TODO
# TODO
end
end

0 comments on commit 477f555

Please sign in to comment.