forked from Gazler/githug
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
cf34f08
commit 6f6065b
Showing
2 changed files
with
17 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
difficulty 3 | ||
|
||
description "We have a file called oldFile.txt. We want to rename it to newFile.txt and stage this change." | ||
|
||
setup do | ||
repo.init | ||
FileUtils.touch("oldFile.txt") | ||
end | ||
|
||
solution do | ||
repo.status["oldFile.txt"].type == "D" && repo.status["newFile.txt"].type == "A" && repo.status["oldFile.txt"].stage.nil? | ||
end | ||
|
||
hint do | ||
puts "Take a look at `git mv`" | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters