nextcloud / nextcloud/android

Prevent duplicate uploads when files are moved between subfolders; detect changes and update existing uploads accordingly

Open
#10,646 1 comment 0 reactions 0 assignees View on GitHub
enhancement feature: auto upload
Dominant language
Kotlin
Stars
5.6k
Forks
2k
Avg merge
2d 18h
Merged PRs (30d)
92

Description

### Is your feature request related to a problem? Please describe.
I use the auto upload feature with subfolders enabled to synchronize the photos of my camera folder automatically to my Nextcloud server. So all photos are stored in the subfolders of the year and the month.

Sometimes I want to share some photos for example I made on a hiking trip with my friends but as it is not possible to choose some photos and share them with one link I always create a subfolder in the subfolder of the month for the specific event. Then I move the photos of the specific event from the month folder to the event folder.

So for example there are three images in the folder /2022/06 called IMG1.jpg, IMG2.jpg and IMG3.jpg. The first two images where made at the hiking trip so I move those to the folder /2022/06/hiking-trip. (see in the screenshot below)

![folder_with_photos_and_subfolders](https://user-images.githubusercontent.com/63782380/185391026-052c45cf-9130-436e-a654-326877cb0be8.png)

The problem is now that if I would switch to a new smartphone and had to reinstall the Nextcloud client app or would move the photos to a new SD-Card when re-scanning the images in the camera folder the Nextcloud app won't recognize that those photos in the folder /2022/06/hiking-trip are already uploaded and it would upload them again to the folder /2022/06 and that's not the behavior that I want.

The second thing is that usually the Nextcloud client app detects when a change has been made to a photo (for example when I edit a gps tag in the metadata) and asks me which version of the photo to keep and then it re-uploads the new edited version.
But when the photo was moved to a subfolder like above the change wouldn't be recognized and you would have to upload the new to the server manually.

### Describe the solution you'd like
With the auto upload function, there should be an option to specify whether files in subfolders should also be viewed.
If a file already exists either in the /2022/06 folder or in any subfolder of this folder, it will no longer be uploaded during a filescan.

In addition, changes to the local file should also be recognized and adapted to the corresponding file in the subfolder.
But I think this feature is more complex to implement.

### Describe alternatives you've considered
Alternatively another option could the the function to share selected images without using a folder like in Google Photos.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.