cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements
What’s new: end-to-end encryption, Replay and Dash updates. Find out more about these updates, new features and more here.

Create, upload, and share

Find help to solve issues with creating, uploading, and sharing files and folders in Dropbox. Get support and advice from the Dropbox Community.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

selective sync from command line

selective sync from command line

rihartley
New member | Level 2

I work on different computers, running Windows, Linux and MacOS.  I am compiling C++ programs on each computer, from the same source.  There is no use syncing compiled objects and executables across different operating systems, but I would prefer that compiled files be in the same directory (for instance, called Objects or Executables), but I do not want to sync them, otherwise compiling on one computer will overwrite the files from another.  Therefore, I want to select certain directories as being non-syncable.  There are too many of these for me to want to do this by hand (particularly having to do it repeatedly on different computers) so I wondering of there is a way of doing this by a command line, which I can then put in a script, with commands something like:

 

dropbox_config  -sync=False A/B/Objects

 

(what I am looking for here is some sort of command, like the command dropbox_config that I invented here)

 

Then I can generate and run a script to do them all at once.  A script that will run on Windows (perhaps in a Ubuntu shell), or on Linux, MacOs, or all of these would be good.

3 Replies 3

Lusil
Dropbox Staff

Hi @rihartley, thanks for dropping by!

 

What you're looking for sounds like what is described in this article, where you can set a file or folder to be "ignored" from syncing. 

 

Check it out and let me know if it helps. Cheers!


Lusil
Community Moderator @ Dropbox
dropbox.com/support


Heart Did this post help you? If so, please give it a Like below.
:arrows_counterclockwise: Still stuck? Ask me a question!
:pushpin: Tips & Tricks Find new ways to stay in flow or share your tips on how you work smarter with Dropbox.

rihartley
New member | Level 2

This is great.  I understand now how Dropbox uses Auxiliary Data Streams on Windows, with a stream called com.dropbox.ignore.

However, it leads to the follow-up:  I see that doing this will set Dropbox to "ignore" the file, meaning that it will removed

from dropbox, but just stay on the computer.  

Is there a similar way that allows you do basically the opposite -- i.e. remove the file from my computer but retain on dropbox.

This is what happens with "selective sync", that I can choose from the graphic interface, but I prefer a command-line solution.  

The same question for selecting "local / Online-only" with smart-sync.  

I am guessing that this information is present in the ADS file com.dropbox.attrs, but this appears to be a binary file, so I cannot guess

what the format is.

 

Lusil
Dropbox Staff

Thanks for getting back to me, @rihartley

 

Although there isn't direct way to do this right now, you can post this here, where other users can comment and upvote. 

 

In the meantime, if you have any other questions, don't hesitate to get back to us. 

 

Cheers!


Lusil
Community Moderator @ Dropbox
dropbox.com/support


Heart Did this post help you? If so, please give it a Like below.
:arrows_counterclockwise: Still stuck? Ask me a question!
:pushpin: Tips & Tricks Find new ways to stay in flow or share your tips on how you work smarter with Dropbox.

Need more support?
Who's talking

Top contributors to this post

  • User avatar
    Lusil Dropbox Staff
  • User avatar
    rihartley New member | Level 2
What do Dropbox user levels mean?