X-Git-Url: http://git.ipfire.org/?a=blobdiff_plain;f=transport.h;h=c14da6f1e53ece9fa9ac2e68b73674c54329be5f;hb=b1b952043f8f909649fdf053c371109c84f9cf56;hp=6bbc1a82642ab9e5722cfe6ab34ec4246b3a9dd4;hpb=0d5055665ca1e76659ffa96bf972b4b0125ea069;p=thirdparty%2Fgit.git diff --git a/transport.h b/transport.h index 6bbc1a8264..c14da6f1e5 100644 --- a/transport.h +++ b/transport.h @@ -18,8 +18,9 @@ struct transport { int (*set_option)(struct transport *connection, const char *name, const char *value); - struct ref *(*get_refs_list)(struct transport *transport); + struct ref *(*get_refs_list)(struct transport *transport, int for_push); int (*fetch)(struct transport *transport, int refs_nr, const struct ref **refs); + int (*push_refs)(struct transport *transport, struct ref *refs, int flags); int (*push)(struct transport *connection, int refspec_nr, const char **refspec, int flags); int (*disconnect)(struct transport *connection); @@ -34,6 +35,8 @@ struct transport { #define TRANSPORT_PUSH_DRY_RUN 4 #define TRANSPORT_PUSH_MIRROR 8 #define TRANSPORT_PUSH_VERBOSE 16 +#define TRANSPORT_PUSH_PORCELAIN 32 +#define TRANSPORT_PUSH_QUIET 64 /* Returns a transport suitable for the url */ struct transport *transport_get(struct remote *, const char *); @@ -66,12 +69,17 @@ int transport_set_option(struct transport *transport, const char *name, const char *value); int transport_push(struct transport *connection, - int refspec_nr, const char **refspec, int flags); + int refspec_nr, const char **refspec, int flags, + int * nonfastforward); const struct ref *transport_get_remote_refs(struct transport *transport); int transport_fetch_refs(struct transport *transport, const struct ref *refs); void transport_unlock_pack(struct transport *transport); int transport_disconnect(struct transport *transport); +char *transport_anonymize_url(const char *url); + +/* Transport methods defined outside transport.c */ +int transport_helper_init(struct transport *transport, const char *name); #endif