diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2015-02-13 22:06:57 -0800 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2015-02-13 22:06:57 -0800 |
commit | da60867ae3765dce3fbbfe85682e6157f9fd5ed7 (patch) | |
tree | 2c2b3f5a17279f8ee47b3c2684dba0980a7e2939 /save-git.c | |
parent | 6dd6e9068452dc12666aa45cf464031c8a8b0d57 (diff) | |
download | subsurface-da60867ae3765dce3fbbfe85682e6157f9fd5ed7.tar.gz |
Always print dive site uuids as 8 digits / leading 0s in git format
Otherwise there are ugly spaces in the file names. This didn't break
anything, per se, it's mostly cosmetic.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'save-git.c')
-rw-r--r-- | save-git.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/save-git.c b/save-git.c index 2069b4c29..cf6bd37e9 100644 --- a/save-git.c +++ b/save-git.c @@ -388,7 +388,7 @@ static void create_dive_buffer(struct dive *dive, struct membuffer *b) SAVE("visibility", visibility); cond_put_format(dive->tripflag == NO_TRIP, b, "notrip\n"); save_tags(b, dive->tag_list); - cond_put_format(dive->dive_site_uuid, b, "divesiteid %8x\n", dive->dive_site_uuid); + cond_put_format(dive->dive_site_uuid, b, "divesiteid %08x\n", dive->dive_site_uuid); save_overview(b, dive); save_cylinder_info(b, dive); @@ -829,7 +829,7 @@ static void save_divesites(git_repository *repo, struct dir *tree) struct dive_site *ds = get_dive_site(i); int size = sizeof("Site-012345678"); char name[size]; - snprintf(name, size, "Site-%8x", ds->uuid); + snprintf(name, size, "Site-%08x", ds->uuid); show_utf8(&b, "name ", ds->name, "\n"); show_utf8(&b, "description ", ds->description, "\n"); show_utf8(&b, "notes ", ds->notes, "\n"); |