Sha256: a85b3f54202a2c4ac4c020f4fc76addb2960c05f4c597250a6e944a1152b8aee

Contents?: true

Size: 649 Bytes

Versions: 1

Compression:

Stored size: 649 Bytes

Contents

difficulty 2

description "A file has been removed from the working tree, but not from the repository. Identify this file and remove it."

setup do
  repo.init
  file = File.new("deleteme.rb", "w")
  file.close
  system "git branch -m master"
  repo.add("deleteme.rb")
  repo.commit_all("Added a temp file")
  File.delete("deleteme.rb")
end

solution do
  repo.status.files["deleteme.rb"].nil? || repo.status.files["deleteme.rb"].stage.nil?
end

hint do
  puts ["You may need to use more than one command to complete this.",
    "You have checked your staging area in a previous level.",
    "Don't forget to run `git` for a list of commands."]
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
githug-0.5.1 levels/rm.rb