mirror of
https://github.com/Stone-Red-Code/dvc.git
synced 2026-11-26 07:18:31 +01:00
scm: implement gitignore (#5243)
* scm: implement gitignore; use `pygit2` backend * Add is_ignored implementation on `pygit2` and `gitpython` backends. * Also implement `._reset()` on `repo.scm` which is most of the changes. * fix tests * use _backend_func * minor fixups
This commit is contained in:
@@ -78,10 +78,12 @@ def test_ignore(tmp_dir, scm):
|
||||
|
||||
scm.ignore(foo)
|
||||
assert (tmp_dir / ".gitignore").is_file()
|
||||
scm._reset()
|
||||
assert _count_gitignore_entries(target) == 1
|
||||
|
||||
scm.ignore(foo)
|
||||
assert (tmp_dir / ".gitignore").is_file()
|
||||
scm._reset()
|
||||
assert _count_gitignore_entries(target) == 1
|
||||
|
||||
scm.ignore_remove(foo)
|
||||
|
||||
Reference in New Issue
Block a user