git: 0505ef1f910e - main - devel/git-cinnabar: update to 0.5.9
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 15 Jul 2022 22:53:00 UTC
The branch main has been updated by jbeich: URL: https://cgit.FreeBSD.org/ports/commit/?id=0505ef1f910e2bbaf87f7a9748edec4088892632 commit 0505ef1f910e2bbaf87f7a9748edec4088892632 Author: Jan Beich <jbeich@FreeBSD.org> AuthorDate: 2022-07-15 21:17:31 +0000 Commit: Jan Beich <jbeich@FreeBSD.org> CommitDate: 2022-07-15 22:52:07 +0000 devel/git-cinnabar: update to 0.5.9 Changes: https://github.com/glandium/git-cinnabar/releases/tag/0.5.9 Reported by: GitHub (watch releases) --- devel/git-cinnabar/Makefile | 3 +- devel/git-cinnabar/distinfo | 6 +- devel/git-cinnabar/files/patch-git-2.35 | 88 -------------------- devel/git-cinnabar/files/patch-git-2.36 | 131 ------------------------------ devel/git-cinnabar/files/patch-git-2.37 | 57 ------------- devel/git-cinnabar/files/patch-no-wrapper | 50 ++++++++---- 6 files changed, 37 insertions(+), 298 deletions(-) diff --git a/devel/git-cinnabar/Makefile b/devel/git-cinnabar/Makefile index 802e4f553671..a8b9eeb96d86 100644 --- a/devel/git-cinnabar/Makefile +++ b/devel/git-cinnabar/Makefile @@ -1,6 +1,5 @@ PORTNAME= git-cinnabar -DISTVERSION= 0.5.8 -PORTREVISION= 7 +DISTVERSION= 0.5.9 CATEGORIES= devel MAINTAINER= jbeich@FreeBSD.org diff --git a/devel/git-cinnabar/distinfo b/devel/git-cinnabar/distinfo index 8811ce54c4ed..9a49f65b3bee 100644 --- a/devel/git-cinnabar/distinfo +++ b/devel/git-cinnabar/distinfo @@ -1,3 +1,3 @@ -TIMESTAMP = 1637356993 -SHA256 (glandium-git-cinnabar-0.5.8_GH0.tar.gz) = 7971c2ae17d2b919f915efab35e3aba583b951d53ca2bc6ebf69bbd0c22f1067 -SIZE (glandium-git-cinnabar-0.5.8_GH0.tar.gz) = 181517 +TIMESTAMP = 1657919851 +SHA256 (glandium-git-cinnabar-0.5.9_GH0.tar.gz) = 83374ff2c7e9ccbb5e866c6fb350ad3202cab4856841afbadaded1f1bef4d534 +SIZE (glandium-git-cinnabar-0.5.9_GH0.tar.gz) = 183800 diff --git a/devel/git-cinnabar/files/patch-git-2.35 b/devel/git-cinnabar/files/patch-git-2.35 deleted file mode 100644 index 1b71c59813cf..000000000000 --- a/devel/git-cinnabar/files/patch-git-2.35 +++ /dev/null @@ -1,88 +0,0 @@ -https://github.com/glandium/git-cinnabar/commit/612e11da5def - ---- helper/GIT-VERSION.mk.orig 2021-11-19 21:23:13 UTC -+++ helper/GIT-VERSION.mk -@@ -1,2 +1,2 @@ --GIT_VERSION ?= v2.34.0 -+GIT_VERSION ?= v2.35.1 - WINDOWS_GIT_VERSION ?= $(GIT_VERSION).windows.1 ---- helper/cinnabar-fast-import.c.orig 2021-11-19 21:23:13 UTC -+++ helper/cinnabar-fast-import.c -@@ -522,8 +522,13 @@ static void do_set(struct string_list *args) - } - } - -+#ifdef _WIN32 -+int write_object_file_flags(const void *buf, size_t len, const char *type, -+ struct object_id *oid, unsigned flags) -+#else - int write_object_file_flags(const void *buf, unsigned long len, const char *type, - struct object_id *oid, unsigned flags) -+#endif - { - struct strbuf data; - enum object_type t; ---- helper/cinnabar-helper.c.orig 2021-11-19 21:23:13 UTC -+++ helper/cinnabar-helper.c -@@ -2411,13 +2411,10 @@ static void init_git_config() - * might be important configuration items there (like http.sslcainfo - * on git for windows). - * Trick git into giving us the path to it system gitconfig. */ -- const char *argv[] = { -- "git", "config", "--system", "-e", NULL -- }; - if (env && *env) { - setup_path(); - } -- proc.argv = argv; -+ strvec_pushl(&proc.args, "git", "config", "--system", "-e", NULL); - strvec_push(&proc.env_array, "GIT_EDITOR=echo"); - proc.no_stdin = 1; - proc.no_stderr = 1; ---- helper/cinnabar-util.c.orig 2021-11-19 21:23:13 UTC -+++ helper/cinnabar-util.c -@@ -227,7 +227,7 @@ void pipe_writer(struct writer *writer, const char **a - - writer_close(writer); - child_process_init(&context->proc); -- context->proc.argv = argv; -+ strvec_pushv(&context->proc.args, argv); - context->proc.in = -1; - context->proc.out = fileno((FILE*)writer->context); - context->proc.no_stderr = 1; ---- helper/hg-connect-stdio.c.orig 2021-11-19 21:23:13 UTC -+++ helper/hg-connect-stdio.c -@@ -215,7 +215,7 @@ struct hg_connection *hg_connect_stdio(const char *url - if (looks_like_command_line_option(path)) - die("strange pathname '%s' blocked", path); - -- proc->env = local_repo_env; -+ strvec_pushv(&proc->env_array, (const char **)local_repo_env); - proc->use_shell = 1; - proc->in = proc->out = proc->err = -1; - ---- helper/object-file.c.patch.orig 2021-11-19 21:23:13 UTC -+++ helper/object-file.c.patch -@@ -1,13 +1,13 @@ - diff --git a/object-file.c b/object-file.c --index c3d866a287..904149ce90 100644 -+index 8be57f48de..52315414f3 100644 - --- a/object-file.c - +++ b/object-file.c --@@ -1954,7 +1954,7 @@ static int freshen_packed_object(const struct object_id *oid) -- return 1; -- } -+@@ -34,6 +34,8 @@ -+ #include "promisor-remote.h" -+ #include "submodule.h" - ---int write_object_file_flags(const void *buf, unsigned long len, --+int real_write_object_file_flags(const void *buf, unsigned long len, -- const char *type, struct object_id *oid, -- unsigned flags) -- { -++#define write_object_file_flags real_write_object_file_flags -++ -+ /* The maximum size for an object header. */ -+ #define MAX_HEADER_LEN 32 -+ diff --git a/devel/git-cinnabar/files/patch-git-2.36 b/devel/git-cinnabar/files/patch-git-2.36 deleted file mode 100644 index 89144ecdc2bf..000000000000 --- a/devel/git-cinnabar/files/patch-git-2.36 +++ /dev/null @@ -1,131 +0,0 @@ -https://github.com/glandium/git-cinnabar/commit/16d11703acfe - ---- helper/GIT-VERSION.mk.orig 2021-11-19 21:23:13 UTC -+++ helper/GIT-VERSION.mk -@@ -1,2 +1,2 @@ --GIT_VERSION ?= v2.35.1 -+GIT_VERSION ?= v2.36.0 - WINDOWS_GIT_VERSION ?= $(GIT_VERSION).windows.1 ---- helper/cinnabar-fast-import.c.orig 2021-11-19 21:23:13 UTC -+++ helper/cinnabar-fast-import.c -@@ -523,30 +523,18 @@ static void do_set(struct string_list *args) - } - - #ifdef _WIN32 --int write_object_file_flags(const void *buf, size_t len, const char *type, -+int write_object_file_flags(const void *buf, size_t len, enum object_type type, - struct object_id *oid, unsigned flags) - #else --int write_object_file_flags(const void *buf, unsigned long len, const char *type, -+int write_object_file_flags(const void *buf, unsigned long len, enum object_type type, - struct object_id *oid, unsigned flags) - #endif - { - struct strbuf data; -- enum object_type t; -- if (type == tree_type) { -- t = OBJ_TREE; -- } else if (type == blob_type) { -- t = OBJ_BLOB; -- } else if (type == commit_type) { -- t = OBJ_COMMIT; -- } else if (type == tag_type) { -- t = OBJ_TAG; -- } else { -- die("Unknown type"); -- } - data.buf = (void *)buf; - data.len = len; - data.alloc = len; -- store_object(t, &data, NULL, oid, 0); -+ store_object(type, &data, NULL, oid, 0); - return 0; - } - ---- helper/fast-import.c.patch.orig 2021-11-19 21:23:13 UTC -+++ helper/fast-import.c.patch -@@ -1,16 +1,25 @@ diff --git a/builtin/fast-import.c b/builtin/fast-impo - diff --git a/builtin/fast-import.c b/builtin/fast-import.c --index 20406f6775..7ff0911c2c 100644 -+index 28d3193c38..2b3aeaa4d5 100644 - --- a/builtin/fast-import.c - +++ b/builtin/fast-import.c --@@ -19,6 +19,7 @@ -- #include "mem-pool.h" -+@@ -20,6 +20,7 @@ - #include "commit-reach.h" - #include "khash.h" -+ #include "date.h" - +#include "shallow.h" - - #define PACK_ID_BITS 16 - #define MAX_PACK_ID ((1<<PACK_ID_BITS)-1) --@@ -737,7 +738,7 @@ static struct tree_content *dup_tree_content(struct tree_content *s) -+@@ -257,7 +258,7 @@ static struct string_list sub_marks_to = STRING_LIST_INIT_DUP; -+ static kh_oid_map_t *sub_oid_map; -+ -+ /* Where to write output of cat-blob commands */ -+-static int cat_blob_fd = STDOUT_FILENO; -++int cat_blob_fd = STDOUT_FILENO; -+ -+ static void parse_argv(void); -+ static void parse_get_mark(const char *p); -+@@ -746,7 +747,7 @@ static struct tree_content *dup_tree_content(struct tree_content *s) - return d; - } - -@@ -19,7 +28,7 @@ +static void real_start_packfile(void) - { - struct strbuf tmp_file = STRBUF_INIT; - struct packed_git *p; --@@ -838,7 +839,7 @@ static int loosen_small_pack(const struct packed_git *p) -+@@ -847,7 +848,7 @@ static int loosen_small_pack(const struct packed_git *p) - return run_command(&unpack); - } - -@@ -28,15 +37,15 @@ +static void real_end_packfile(void) - { - static int running; - --@@ -857,6 +858,7 @@ static void end_packfile(void) -+@@ -866,6 +867,7 @@ static void end_packfile(void) - - close_pack_windows(pack_data); -- finalize_hashfile(pack_file, cur_pack_oid.hash, 0); -+ finalize_hashfile(pack_file, cur_pack_oid.hash, FSYNC_COMPONENT_PACK, 0); - + pack_file = NULL; - fixup_pack_header_footer(pack_data->pack_fd, pack_data->hash, - pack_data->pack_name, object_count, - cur_pack_oid.hash, pack_size); --@@ -956,6 +958,9 @@ static int store_object( -+@@ -965,6 +967,9 @@ static int store_object( - e->pack_id = MAX_PACK_ID; - e->idx.offset = 1; /* just not zero! */ - duplicate_count_by_type[type]++; -@@ -46,7 +55,7 @@ + } - return 1; - } - --@@ -1639,7 +1644,7 @@ static int update_branch(struct branch *b) -+@@ -1648,7 +1653,7 @@ static int update_branch(struct branch *b) - return 0; - } - -@@ -55,7 +64,7 @@ +void dump_branches(void) - { - unsigned int i; - struct branch *b; --@@ -2208,7 +2213,9 @@ static int parse_mapped_oid_hex(const char *hex, struct object_id *oid, const ch -+@@ -2217,7 +2222,9 @@ static int parse_mapped_oid_hex(const char *hex, struct object_id *oid, const ch - * Complain if the following character is not what is expected, - * either a space or end of the string. - */ -@@ -66,7 +75,7 @@ +static uintmax_t real_parse_mark_ref(const char *p, c - { - uintmax_t mark; - --@@ -2272,9 +2279,8 @@ static void file_change_m(const char *p, struct branch *b) -+@@ -2281,9 +2288,8 @@ static void file_change_m(const char *p, struct branch *b) - case S_IFDIR: - case S_IFGITLINK: - /* ok */ diff --git a/devel/git-cinnabar/files/patch-git-2.37 b/devel/git-cinnabar/files/patch-git-2.37 deleted file mode 100644 index 5783b8c7e86e..000000000000 --- a/devel/git-cinnabar/files/patch-git-2.37 +++ /dev/null @@ -1,57 +0,0 @@ -https://github.com/glandium/git-cinnabar/commit/7d6f93efb9a8 - ---- helper/GIT-VERSION.mk.orig 2021-11-19 21:23:13 UTC -+++ helper/GIT-VERSION.mk -@@ -1,2 +1,2 @@ --GIT_VERSION ?= v2.36.0 -+GIT_VERSION ?= v2.37.0 - WINDOWS_GIT_VERSION ?= $(GIT_VERSION).windows.1 ---- helper/cinnabar-helper.c.orig 2021-11-19 21:23:13 UTC -+++ helper/cinnabar-helper.c -@@ -2415,7 +2415,7 @@ static void init_git_config() - setup_path(); - } - strvec_pushl(&proc.args, "git", "config", "--system", "-e", NULL); -- strvec_push(&proc.env_array, "GIT_EDITOR=echo"); -+ strvec_push(&proc.env, "GIT_EDITOR=echo"); - proc.no_stdin = 1; - proc.no_stderr = 1; - /* We don't really care about the capture_command return value. If -@@ -2583,3 +2583,8 @@ int main(int argc, const char *argv[]) - hashmap_clear_and_free(&git_tree_cache, struct oid_map_entry, ent); - return 0; - } -+ -+int common_exit(const char *file, int line, int code) -+{ -+ return code; -+} ---- helper/hg-connect-stdio.c.orig 2021-11-19 21:23:13 UTC -+++ helper/hg-connect-stdio.c -@@ -215,7 +215,7 @@ struct hg_connection *hg_connect_stdio(const char *url, int flags) - if (looks_like_command_line_option(path)) - die("strange pathname '%s' blocked", path); - -- strvec_pushv(&proc->env_array, (const char **)local_repo_env); -+ strvec_pushv(&proc->env, (const char **)local_repo_env); - proc->use_shell = 1; - proc->in = proc->out = proc->err = -1; - ---- tests/ls-remote.t.orig 2021-11-19 21:23:13.000000000 +0000 -+++ tests/ls-remote.t -@@ -323,7 +323,6 @@ - 23bcc26b9fea7e37426260465bed35eac54af5e1 refs/heads/branches/foo/tip - - $ git -c fetch.prune=true -C repo-git remote update -- Fetching origin - From hg::.*/ls-remote.t/repo (re) - - [deleted] (none) -> origin/branches/default/636e60525868096cbdc961870493510558f41d2f - + 5c5b259...445bd26 branches/default/tip -> origin/branches/default/tip (forced update) -@@ -450,7 +449,6 @@ - $ cd .. - - $ git -c fetch.prune=true -C repo-git remote update -- Fetching origin - From hg::.*/ls-remote.t/repo (re) - 445bd26..66e3a05 branches/default/tip -> origin/branches/default/tip - * [new branch] bookmarks/@ -> origin/bookmarks/@ diff --git a/devel/git-cinnabar/files/patch-no-wrapper b/devel/git-cinnabar/files/patch-no-wrapper index 7811dd7d609a..d24e02a196b1 100644 --- a/devel/git-cinnabar/files/patch-no-wrapper +++ b/devel/git-cinnabar/files/patch-no-wrapper @@ -1,17 +1,17 @@ Disable wrappers as Python version is controlled by FLAVORS ---- README.md.orig 2021-11-19 21:23:13 UTC +--- README.md.orig 2022-07-15 21:17:31 UTC +++ README.md -@@ -53,17 +53,6 @@ Setup: +@@ -53,17 +53,6 @@ - A native helper is used for faster operations. You c If you want to build git along the helper, you can run `make git`. -Python: -------- - --git-cinnabar will use one of `python3`, `python2.7` or `python2`, whichever has --mercurial libraries. If none of them does, it will use the first that can be --found. +-git-cinnabar will use one of `python3`, `python`, `python2.7` or `python2`, +-whichever has mercurial libraries. If none of them does, it will use the first +-that can be found. - -You may force a specific python through the `GIT_CINNABAR_PYTHON` environment -variable. @@ -20,50 +20,66 @@ Disable wrappers as Python version is controlled by FLAVORS Usage: ------ ---- git-cinnabar.orig 2021-11-19 21:23:13 UTC +--- git-cinnabar.orig 2022-07-15 21:17:31 UTC +++ git-cinnabar -@@ -1,21 +1,4 @@ +@@ -1,29 +1,4 @@ -#!/bin/sh -''':' -py="$GIT_CINNABAR_PYTHON" -if test -z "$py"; then -- for py in python3 python2.7 python2; do +- for py in python3 python python2.7 python2; do - "$py" -c "from mercurial import hg" >/dev/null 2>&1 && break - py= - done -fi -if test -z "$py"; then -- for py in python3 python2.7 python2; do -- command -v "$py" > /dev/null && break +- for py in python3 python python2.7 python2 "py -3" "py -2"; do +- # Make sure this Python actually works. On Windows, python.exe, etc. might +- # try to run the Windows Store app even if it's not installed. +- $py -c "import sys" >/dev/null 2>&1 && break - py=python3 - done -fi --exec "$py" "$0" "$@" +-if test -n "$GIT_CINNABAR_PYTHON"; then +- # $GIT_CINNABAR_PYTHON is an executable which might contain spaces. +- exec "$GIT_CINNABAR_PYTHON" "$0" "$@" +-else +- # If $py contains spaces, these will be arguments. +- exec $py "$0" "$@" +-fi -exit 1 -''' +#!/usr/bin/env python import os import sys ---- git-remote-hg.orig 2021-11-19 21:23:13 UTC +--- git-remote-hg.orig 2022-07-15 21:17:31 UTC +++ git-remote-hg -@@ -1,21 +1,4 @@ +@@ -1,29 +1,4 @@ -#!/bin/sh -''':' -py="$GIT_CINNABAR_PYTHON" -if test -z "$py"; then -- for py in python3 python2.7 python2; do +- for py in python3 python python2.7 python2; do - "$py" -c "from mercurial import hg" >/dev/null 2>&1 && break - py= - done -fi -if test -z "$py"; then -- for py in python3 python2.7 python2; do -- command -v "$py" > /dev/null && break +- for py in python3 python python2.7 python2 "py -3" "py -2"; do +- # Make sure this Python actually works. On Windows, python.exe, etc. might +- # try to run the Windows Store app even if it's not installed. +- $py -c "import sys" >/dev/null 2>&1 && break - py=python3 - done -fi --exec "$py" "$0" "$@" +-if test -n "$GIT_CINNABAR_PYTHON"; then +- # $GIT_CINNABAR_PYTHON is an executable which might contain spaces. +- exec "$GIT_CINNABAR_PYTHON" "$0" "$@" +-else +- # If $py contains spaces, these will be arguments. +- exec $py "$0" "$@" +-fi -exit 1 -''' +#!/usr/bin/env python