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

Issue: Deleted content does not get added in git when syncing #465

Closed
albbus-stack opened this issue Nov 23, 2022 · 3 comments
Closed

Issue: Deleted content does not get added in git when syncing #465

albbus-stack opened this issue Nov 23, 2022 · 3 comments
Labels
bug Something isn't working Project: v8.2.0
Projects

Comments

@albbus-stack
Copy link
Contributor

albbus-stack commented Nov 23, 2022

All the deleted content, this being articles or images, is not added to git when syncing. Only the modified and not added files are being added to the git commit.

Steps to reproduce
To reproduce the behavior:

  1. Create a new file
  2. Commit it
  3. Delete it and perform a sync with front matter

You are going to notice that the deleted file has not been committed.

Expected Behaviour
Even the deleted files should be added in the git commit since it's a clear modification of the contents of the cms.

Solution
Around these lines of GitListener.ts, in the push() method, there should be another for loop iterating through the files contained in status.deleted adding them to the git commit.

Please let me know if I'm missing on something, I'll be happy to contribute in first person to the fix for this.

@albbus-stack albbus-stack added the bug Something isn't working label Nov 23, 2022
@estruyf
Copy link
Owner

estruyf commented Nov 24, 2022

Thank you @albbus-stack, for opening the issue and taking a look at it. If you feel you can fix it, and want to do a PR, you are more than welcome to do so.

@albbus-stack
Copy link
Contributor Author

I've gone ahead and added the modification in the above PR, further details are explained there. I've assumed the dev branch was the correct place, if not just merge it elsewere at your liking and close this issue. Thank you and keep up the great work :octocat:

@estruyf
Copy link
Owner

estruyf commented Nov 24, 2022

Thanks @albbus-stack, your changes looked good and are now available in the latest beta version of the extension.

v8.2.0 automation moved this from Planned to Done Nov 24, 2022
@estruyf estruyf mentioned this issue Dec 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Project: v8.2.0
Projects
No open projects
Development

No branches or pull requests

2 participants