Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add: cleanup .gitignore decorator #1673

Merged
merged 2 commits into from
Mar 13, 2019
Merged

add: cleanup .gitignore decorator #1673

merged 2 commits into from
Mar 13, 2019

Conversation

pared
Copy link
Contributor

@pared pared commented Mar 1, 2019

Fixes #1641

@pared pared force-pushed the 1641 branch 4 times, most recently from c6d1f53 to a47b136 Compare March 1, 2019 15:27
@pared pared requested review from efiop and dmpetrov March 1, 2019 15:50
Copy link
Contributor

@efiop efiop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! 🙂

dvc/repo/add.py Outdated Show resolved Hide resolved
dvc/repo/add.py Outdated Show resolved Hide resolved
dvc/repo/add.py Outdated Show resolved Hide resolved
@pared pared force-pushed the 1641 branch 4 times, most recently from d3941da to 2c4fcd5 Compare March 5, 2019 13:17
@pared pared changed the title [WPI] add: cleanup .gitignore decorator add: cleanup .gitignore decorator Mar 5, 2019
@pared pared requested a review from efiop March 5, 2019 13:44
Copy link
Contributor

@efiop efiop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks really good! Is it worth creating something like @scm_context(or some better name) decorator that would do what revert_ignores_on_failure does and also remind_to_git_add logic that we've been talking about? What do you think?

dvc/scm/git.py Outdated Show resolved Hide resolved
dvc/repo/run.py Outdated Show resolved Hide resolved
dvc/scm/base.py Outdated Show resolved Hide resolved
@pared pared force-pushed the 1641 branch 4 times, most recently from 6724072 to c59df4a Compare March 6, 2019 09:52
Copy link
Contributor

@efiop efiop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! A few more comments down below.

dvc/scm/__init__.py Outdated Show resolved Hide resolved
dvc/repo/add.py Show resolved Hide resolved
Copy link
Contributor

@efiop efiop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#1673 (comment)

Unit tests for that should be enough. E.g. something like mock add/run/imp/etc to raise an exception and check that scm_context did its job. No need to setup a full blown error scenario.

dvc/repo/imp.py Show resolved Hide resolved
dvc/repo/move.py Show resolved Hide resolved
dvc/repo/reproduce.py Show resolved Hide resolved
dvc/repo/run.py Show resolved Hide resolved
Copy link
Contributor

@efiop efiop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please rebase?

Copy link
Contributor

@efiop efiop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@efiop efiop merged commit ca64845 into iterative:master Mar 13, 2019
@pared pared deleted the 1641 branch April 3, 2019 11:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants