diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2015-12-03 23:14:20 -0800 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-12-03 23:14:20 -0800 |
commit | 1cb5419a57da4c2c278e6ce364e9c10daaac2633 (patch) | |
tree | 6606b6d51e8582f59b6e3e37b49bbfc6869a4288 /subsurface-core/save-git.c | |
parent | 445dbe73bfcc1675cdbf532752bc2b8a682dc37c (diff) | |
download | subsurface-1cb5419a57da4c2c278e6ce364e9c10daaac2633.tar.gz |
Cloud storage: do not store the actual pictures in git
Adding pictures to the repository was a big mistake on my part. It's very
easy for the git repositories to reach a gigabyte and more making sync
times (and especially "first download" times) completely unreasonable.
This doesn't solve the problem for existing repositories (as the pictures
are already there, in the git history), but at least it prevents us from
storing more pictures out there.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface-core/save-git.c')
-rw-r--r-- | subsurface-core/save-git.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/subsurface-core/save-git.c b/subsurface-core/save-git.c index d3601a272..e4bf1a5cd 100644 --- a/subsurface-core/save-git.c +++ b/subsurface-core/save-git.c @@ -634,6 +634,8 @@ static int save_one_picture(git_repository *repo, struct dir *dir, struct pictur offset -= h *3600; error = blob_insert(repo, dir, &buf, "%c%02u=%02u=%02u", sign, h, FRACTION(offset, 60)); +#if 0 + /* storing pictures into git was a mistake. This makes for HUGE git repositories */ if (!error) { /* next store the actual picture; we prefix all picture names * with "PIC-" to make things easier on the parsing side */ @@ -643,6 +645,7 @@ static int save_one_picture(git_repository *repo, struct dir *dir, struct pictur error = blob_insert_fromdisk(repo, dir, localfn, mb_cstring(&namebuf)); free((void *)localfn); } +#endif return error; } |