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

Refactor AnnotateRoutes.remove_annotations #715

Conversation

nard-tech
Copy link
Collaborator

@nard-tech nard-tech commented Jan 8, 2020

I refactored AnnotateRoutes.remove_annotations.

Summary

  • Build new_text in .remove_annotations
  • Add trailing new line in .strip_on_removal
  • Use .rewrite_contents for comparing existing_text and new_text, and write new_text to the file.

@nard-tech
Copy link
Collaborator Author

I will refactor and finally remove AnnotateRoutes.rewrite_contents_with_header in another PR because it is similar to .rewrite_contents.

@drwl drwl merged commit 966bff0 into ctran:develop Jan 16, 2020
@nard-tech nard-tech deleted the feature/refactor_annotate_routes/remove_annotations branch January 17, 2020 10:20
vfonic pushed a commit to vfonic/annotate_models that referenced this pull request May 8, 2020
* Refactor AnnotateRoutes.rewrite_contents and .remove_annotations

* Refactor AnnotateRoutes.remove_annotations and .strip_on_removal
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.

None yet

2 participants