Skip to content

Check current sync status from command line #6345

Open
@fabianostermann

Description

Feature description

Hi all,

I am looking for a way to determine the current state of the nextcloud client (mainly: "syncing.." vs "all synced") in a bash script.
I use that to wait for syncing to end and then automatically trigger shutdown.
Dropbox, which I used for a long time, has a python script command for that: $ dropbox status
That just returns a string, that can be captured and interpreted.

If there isn't such a functionality in the nextcloud client (and my searches indicate nothing useful), I would like to give it a try.
For my use case, it could mean to just perform a hacky lookup of some log files (I saw I can enable logging to /tmp/Nextcloud-logdir/) or anything similar.
So has anyone, who is more into the code, an idea how to cleverly approach this for now?

Also, I would suggest to consider such a utility a super enhancement for this project. If a simple approach could be found for now, I would like to look into integrating this to the project in a smoother way.

Thx in advance for any suggestions!


The information I want to obtain seems to be stored in src/common/syncfilestatus.h

What happened to nextcloudcmd? Is src/cmd working or not? Sorry, but I cannot find up-to-date information about it. Thx!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions