tg-tag.sh: with --tree=treeish set tag's tree
Normally when creating a tg tag, if there's only a single
independent head present, it's tagged directly resulting in
use of its tree.
When two or more independent heads are being tagged, normally
a "consolidation" commit is created that uses the empty tree.
When the --tree=treeish option is given, the tagged object
will always be one that has the specified tree. If a special
"consolidation" commit would have been created anyway, it will
just be created using the specified treeish instead.
If a "consolidation" commit would not have otherwise been created
AND the specified treeish differs from the tree of the single
independent head being tagged, then a "consolidation" commit will
be forced even though there's only the one head so that the
specified tree gets used.
This option is most useful when tg tags are serving double duty
as both a means to carry multiple refs and as a normal tag.
Signed-off-by: Kyle J. McKay <mackyle@gmail.com>