Single Global .sync\ignorelist File


Dantounet

Recommended Posts

For a local solution to this I wrote an AutoIt3 script. The only issue it addresses is ensuring that my "authoritative" IgnoreList is duplicated to all my local Sync folders. Gives me a splash text telling me what share is missing, and waits till I have resolved that before launching Sync. I thought maybe someone else might be able to use it till there's a native Sync solution, so here it is.

#include <Array.au3>;    The 0-index element of the array contains the path to BTSync.exeLocal $paths[] = [@AppDataDir&"\BitTorrent Sync\BTSync.exe"];    The 1-index element of the array contains the path to the share containing the authoritative ignore list_ArrayAdd($paths, @UserProfileDir&"\BTSync")_ArrayAdd($paths, @UserProfileDir&"\KeePass")_ArrayAdd($paths, "O:\O_BTSync")_ArrayAdd($paths, "P:\P_BTSync");    The subdirectory of the ignore list$ignore = "\.sync\IgnoreList"$dynWidth = Round(@DesktopWidth / 16, 0)$dynHeight = Round(@DesktopHeight / 16, 0)SplashTextOn(@ScriptName, "", $dynWidth * 4, $dynHeight * 2, @DesktopWidth - ($dynWidth * 5), @DesktopHeight - ($dynHeight * 3), 5, "", 8)$splashId = "Static1"While 1    $ready = True    $splashFill = ""    For $i = 0 To UBound($paths) - 1 Step + 1        If FileExists($paths[$i]) = 1 Then            $splashFill &= "Verified: "&$paths[$i]&@CRLF            If $i = 1 Then                If FileExists($paths[$i]&$ignore) = 1 Then                    $splashFill &= "Verified: "&$paths[$i]&$ignore&@CRLF                Else                    $ready = False                    $splashFill &= "MISSING: "&$paths[$i]&$ignore&@CRLF                EndIf            EndIf        Else            $ready = False            $splashFill &= "MISSING: "&$paths[$i]&@CRLF        EndIf        Sleep(125)    Next    ControlSetText(@ScriptName, "" ,$splashId, $splashFill)    If $ready = True Then        For $i = 0 To UBound($paths) - 1 Step + 1            If $i > 0 Then                FileCopy($paths[1]&$ignore, $paths[$i]&$ignore, 9)            EndIf            Sleep(125)        Next        ExitLoop    EndIfWEndRun($paths[0])Exit
Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...

+1

 

Can we please have a Synced Ignore file, similar to the old .SyncIgnore or git's .gitignore. Its is a huge pain to have to copy paste .sync/IgnoreList across every shared folder on every device (this is asking for trouble/accidents). Imagine if you use git for a project, and the .gitignore file is not automatically synced.

 

I understand the .sync/IgnoreList solved a problem of having client specific ignore files, which is great. But i completely disagree with removing the project (im going to call a shared folder a project) specific ignore file (like the .SyncIgnore).

 

Can we please have such feature again? heck, you can add a .sync/SyncIgnoreList (or /.SyncIgnoreList), a file that syncs across all shared devices and combines with the client specific .sync/IgnoreList when looking for files to ignore. Heck, if anyone has a problem with a Synced Ignore file, you can build a feature so that users can add .SyncIgnoreList to the client specific .sync/IgnoreList file to ignore the rules of the Synced .SyncIgnoreList file.

Link to comment
Share on other sites

  • 4 weeks later...
  • 3 weeks later...
  • 3 weeks later...
On 2/5/2016 at 2:36 PM, houman1209 said:

+1

I think having .sync/IgnoreList as a machine specific and .syncignore as global setting (can be put into any folder). 

This will be same as Git and I believe it is the most logical and powerful solution.

This, Git already has everything figured out

Link to comment
Share on other sites

  • 4 weeks later...
  • 4 months later...

+1 ... Keep the existing local .sync/ignoreList and allow for an overridable one that itself is synced to all devices.

This would be very handy when adding new devices, and with all the random disconnection problems we've been seeing, it would make reconnecting a folder slightly less painful.

Link to comment
Share on other sites

  • 2 months later...
  • 3 months later...
  • 5 months later...

I'd also love this as I specifically bought BTSync/Resilio because of it's git like ignore syntax that allowed me to sync my development folder without the million node_modules and build artifacts. 
I just set up a new machine today and noticed it syncing loads of crud before I caught it and updated the .sync/IgnoreList file. Considering git brings it's ignore with it, I also expect some method for git-like ignore lists to be synced as well.

Just give us an option, or another file like .sync/SyncedIgnoreList

Link to comment
Share on other sites

  • 1 month later...
  • 1 month later...
  • 4 weeks later...

+ 1
Yep I like a global ignore file next to the local ignore file too. In case the local and global collide the local entry should be used.

At the moment I am fixing this by copying the ignore file to the root of the sync folder so I can distribute it quickly over multiple machines. This speeds things up but I still have to start up en login on every machine.

Link to comment
Share on other sites

  • 8 months later...
  • 2 weeks later...

I have a solution to this problem (part of it).

You can move that file out of .sync and create a symbolic link to it.

For Windows, assuming your folder is c:\foo:

1. Stop Resilio Sync
2. Open up cmd.exe as administrator 
3. Type these commands:

cd /D c:\foo\.sync
move IgnoreList ..
mklink IgnoreList ..\IgnoreList

4. Start Resilio Sync

This will cause Resilio Sync to sync the Ignore List when changes happen to it, but it will be viewing a Symbolic Link to the IgnoreList when reading what to ignore.

Link to comment
Share on other sites

  • 1 year later...

Please make this happen.

Seems simple to me, but I'm a web developer not a software developer.

ignoreList is local

ignoreListGlobal is global

I understand that nothing in the .sync folder is synced between devices, so that would require some reworking.

Edited by Narfe
Link to comment
Share on other sites

  • 6 months later...

+1

 

Not having this feature is especially painful when you setup a headless server and share an identity. It basically creates a situation where anytime you add a "share" you need to login to headless server to make sure the ignorelist is accurate.

This is primarily a pain because of the default exclusion of ~* and *~.

We use tilde (~) quite a bit and the fact that is was added to the default ignore list is pretty ridiculous given how massive the wildcard inclusion is. Defaults should be much more specific.

Link to comment
Share on other sites

  • 1 month later...
On 2/5/2016 at 2:36 PM, houman1209 said:

+1

I think having .sync/IgnoreList as a machine specific and .syncignore as global setting (can be put into any folder). 

This will be same as Git and I believe it is the most logical and powerful solution.

This would be perfect!

On 5/26/2020 at 9:36 PM, tcf909 said:

This is primarily a pain because of the default exclusion of ~* and *~.

Agreed. I also have a need to be able to add my own rules that are synced, so simply removing these default rules wouldn't be enough for me.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.