Syncthing Can't find Files in Folder

I am using an LG 3 Phone with Android 6.0 installed. I created a link connection to my internal photo directory which is located at:

/storage/0123-4567/DCIM/Camera/filename_jpg

I have two files in my Camera directory and when I point the Android version of Syncthing to this directory, it does not find the two files. This is the default location for the default camera app that is loaded on my phone.

I have another camera app called OpenCamera. It uses:

/storage/emulated/0/DCIM/OpenCamera/

All jpg and video files located in this directory can be read by Syncthing. What is the problem here?

Assuming filename_jpg is the directory containing the 2 files you want to sync, you need to add a forward slash “/” at the end of the path as follows:

/storage/0123-4567/DCIM/Camera/filename_jpg/

I want to sync all files within this folder so no filename is given in the path. As I’m sure you know, in the Android version you can only browse to folders that have already been created. You can not type in wildcards or file names.

Yep. I understand that you want to sync all the files in the existing folder “filename_jpg” on your Android device.

I believe that you might have a simple syntax error … there is a missing “/” at the end of your path. That was what I was suggesting.

Did you try this? What happened?

The slash shouldn’t be critical. Is this external storage? If so, there are a few threads about Android and external storage around.

That seems to be external SD Card. That doesn’t work with Syncthing.

@calmh In my experience, whether or not the user actually types the “/” at the end of the path, the Android app appears to add one anyway after the re-start - as seen in the “Folders” screen. Works either way. Maybe the trailing / is unnecessary - perhaps @Nutomic can clarify this.

@wweich When the OP referred to “internal”, I never considered SD was the location. Thanks

We don’t do anything with the path in syncthing-android, we only pass it to Syncthing. So unless Syncthing cares about the trailing slash, it shouldn’t make a difference.

Here’s a couple of screenshots to illustrate what is confusing at least … to me:

In the above pic, I have created a new folder SlashTest, and as you can see, the path ends without a “/”. Then I saved and the St-Android app re-started.

After the app restart, I navigated to the “Folders” side of the screen, and the path now ends with a “/”.

I might be nitpicking … but it is somewhat confusing when the app adds an additional character (that I didn’t enter) to the end of the path. It’s unclear if the trailing slash is required or not.

Thanks.

It’s added as it’s required for consistency.

2 Likes

There are cases when the slash is required (i.e., when the thing being named is something other than a normal directory). There are no cases where it hurts. So we add it when missing.

1 Like

Thanks - solved for me! :sunglasses:

And it probably means that the OP’s problem was related to an external SD card - already discussed in other threads.

1 Like