Ubuntu – How to ignore Eclipse workspace .metadata folder in Ubuntu One

eclipsesyncubuntu-one

I'm a Eclipse's user and I want synchronize my workspace on Ubuntu One. The problem is because the Eclipse creates a metadata inside of workspace, this meta have some configurations of computer that use this program.

So, when I sync my workspace folder, this meta go with all my projects, and when I download it in another computer, Ubuntu One overrides the meta folder and crashes my Eclipse.

There is some way of share a folder on Ubuntu One, but eliminate some internal folders?

Best Answer

  • There is a hidden configuration option, which you can add a list of Python (not shell) expressions to, for ignoring specific file extensions for example. In the ~/.config/ubuntuone/syncdaemon.conf file you can add the following:

    [__main__]
    ignore = \A.*\.metadata\Z
    

    This should keep the .metadata folder from being synchronized. If the file already exists, and has an existing [__ main __] (without spaces) section, don't add another one.

    You should stop ubuntuone-syncdaemon by running u1sdtool -q in a terminal, first. Then make your changes, and run u1sdtool -c to restart and connect the syncdaemon.