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

Allow to control flags of the rsync command #80

Open
Dimfred opened this issue Jun 16, 2023 · 6 comments
Open

Allow to control flags of the rsync command #80

Dimfred opened this issue Jun 16, 2023 · 6 comments
Labels
enhancement New feature or request

Comments

@Dimfred
Copy link
Contributor

Dimfred commented Jun 16, 2023

Would be nice to have this, e.g. I sometimes don't want --delete to be called, since it would clear my build folder (only if it is not in the .gitignore) on the remote.
I think this could maybe give some more flexibility?

What do you think of having a function one can set, that function receives the project_path, and the destination_path (per command, RsyncUp RsyncDown...) and the user could build his own string and else the default could be provided.

I am still looking at the code, but I think that would be a very flexible approach.
Love the idea btw if I haven't said it yet, and thank you for writing it <3

@OscarCreator
Copy link
Owner

Hmm. I have to think about this one. I have #29 where you then could just add an ignore file to ignore the build folder.

Also could you explain the reason for not having the build folder on the ignore file?

@Dimfred
Copy link
Contributor Author

Dimfred commented Jun 17, 2023

There was none, i just forgot to add it and wiped the remote. I think there could be usecases maybe and just don't have one yet, also it would solve the other problem with the different rsync versions, since everyone could just use their own command.

I think it depends on how you want the plugin to be, completely work out of the box, or make it more configurable. I normally prefer the latter. All power to the user.

@OscarCreator
Copy link
Owner

Generally I want it to work out of the box but still be easy to extend if needed.

@Dimfred
Copy link
Contributor Author

Dimfred commented Jun 23, 2023

Okay so, I just wiped my whole remote folder, because I set the wrong path, I would really like to disable --delete on my end. Obviously my error, but still could have been mitigated.

@OscarCreator
Copy link
Owner

Okay, sure we could add this. But I can tell you the reason why it's there. Say you have a git repo synced up to a remote and I delete a file locally. That file will still exist on the remote side.

If I for example have multiple git branches locally (which adds or removes files) then the remote will be a mess with lots of files not representing the local state.

@Dimfred
Copy link
Contributor Author

Dimfred commented Jun 24, 2023

Don't get me wrong, I see that thats an issue and I think delete makes sense, but e.g. I probably would create myself a custom command for deletions, and run deletions manually, I just want to decide when I do that.

@OscarCreator OscarCreator added the enhancement New feature or request label Nov 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants