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

sync virtual file without opening #7264

Open
r2evans opened this issue Oct 3, 2024 · 0 comments
Open

sync virtual file without opening #7264

r2evans opened this issue Oct 3, 2024 · 0 comments
Labels
0. Needs triage enhancement enhancement of a already implemented feature/code

Comments

@r2evans
Copy link
Contributor

r2evans commented Oct 3, 2024

How to use GitHub

  • Please use the 👍 reaction to show that you are interested into the same feature.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Feature request

Which Nextcloud Version are you currently using: 29.0.7

Describe the solution you'd like

The ability to initiate sync of file but without opening it.

The current mechanism relies on using xdg-open (or mimeopen) for opening a file: the .nextcloud file extension (on linux) chains through several mime-related files, eventually resolving to using /usr/bin/nextcloud on the file. Its behavior is to sync it to the local directory and then open the file. (If you're curious to which files, read #3668 (comment).)

However, in my use-case I need to open it within the VM, which is certainly not something nextcloud should try to implement. Currently I have to open it in linux, which opens in what linux thinks is the appropriate app (it's insufficient but doesn't crash). I then close the app, then open the file from within the windows-guest VM (with a shared-folder to get to the real file).

A clear and concise description of what you want to happen.

Describe alternatives you've considered

  • nextcloudcmd only syncs whole directories, it does not support individual files; even if it did, I'm not certain that it signals that the file is the realization of a virtual file, and therefore not a change. I would not want this to cause an unnecessary false-signal that the newly downloaded is "new" and needs to be uploaded.
  • anything using webdav falls prey to the same false-signal that the downloaded file is "new" or "changed", which would overwrite the file on the server; at best this is inefficient.
  • I have tried to hack a script that "opens" it (using the default xdg-open/mimeopen mechanism) and immediately close the mime-defined application, but this is just a hack and often doesn't catch it quite in time.

Additional context

  • It is not unheard of that opening the file imposes some change on its contents, either by accident (such as imperfect MS-Office emulation in LibreOffice/OpenOffice, bug reports almost certainly) or by design (I have no example at this time). In this case, syncing the file is the only thing desired, anything more is irreversible.
  • My use-case to open it within a VM is just mine, I think the request is still relevant. For instance, if I'm syncing to the local drive and will then take it to another machine (on which I'm not running a nextcloud desktop client), it might be that the file cannot be run on the local system due to any number of reasons (memory comes to mind, where the software might be installed but to open it would tend towards OOM).
@r2evans r2evans added 0. Needs triage enhancement enhancement of a already implemented feature/code labels Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0. Needs triage enhancement enhancement of a already implemented feature/code
Projects
None yet
Development

No branches or pull requests

1 participant