X-Git-Url: http://rtime.felk.cvut.cz/gitweb/git.git/blobdiff_plain/809780b662355a9ded05b450a07bbe79d0d2e26e..HEAD:/transport.h diff --git a/transport.h b/transport.h index 096f6e947..c59d97388 100644 --- a/transport.h +++ b/transport.h @@ -80,7 +80,12 @@ struct transport { int (*disconnect)(struct transport *connection); char *pack_lockfile; signed verbose : 3; - /* Force progress even if stderr is not a tty */ + /** + * Transports should not set this directly, and should use this + * value without having to check isatty(2), -q/--quiet + * (transport->verbose < 0), etc. - checking has already been done + * in transport_set_verbosity(). + **/ unsigned progress : 1; /* * If transport is at least potentially smart, this points to @@ -94,10 +99,9 @@ struct transport { #define TRANSPORT_PUSH_FORCE 2 #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 -#define TRANSPORT_PUSH_SET_UPSTREAM 128 +#define TRANSPORT_PUSH_PORCELAIN 16 +#define TRANSPORT_PUSH_SET_UPSTREAM 32 + #define TRANSPORT_SUMMARY_WIDTH (2 * DEFAULT_ABBREV + 3) /* Returns a transport suitable for the url */ @@ -129,6 +133,8 @@ struct transport *transport_get(struct remote *, const char *); **/ int transport_set_option(struct transport *transport, const char *name, const char *value); +void transport_set_verbosity(struct transport *transport, int verbosity, + int force_progress); int transport_push(struct transport *connection, int refspec_nr, const char **refspec, int flags,