Re: [PATCH 2/6] pretty: Add %D for script-friendly decoration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Greg Price <price@xxxxxxx> writes:

> +static void format_decoration_short(struct strbuf *sb, const struct commit *commit)
> +{
> +	const char *affixes[3] = {" (", ", ", ")"};
> +	format_decoration(sb, commit, DECORATE_SHORT_REFS, affixes);
> +}
> +
> +static void format_decoration_full(struct strbuf *sb, const struct commit *commit)
> +{
> +	const char *affixes[3] = {"", " ", ""};
> +	format_decoration(sb, commit, DECORATE_FULL_REFS, affixes);
>  }

Nice and cute abstraction. I like this part of the series.

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]