TAG-DISTANCE-gHEX[-dirty]. Like 'git describe --tags --dirty --always -long'. The distance/hash is unconditional. Exceptions: 1: no tags. HEX[-dirty] (note: no 'g' prefix)
(pieces)
| 556 | |
| 557 | |
| 558 | def render_git_describe_long(pieces): |
| 559 | """TAG-DISTANCE-gHEX[-dirty]. |
| 560 | |
| 561 | Like 'git describe --tags --dirty --always -long'. |
| 562 | The distance/hash is unconditional. |
| 563 | |
| 564 | Exceptions: |
| 565 | 1: no tags. HEX[-dirty] (note: no 'g' prefix) |
| 566 | """ |
| 567 | if pieces["closest-tag"]: |
| 568 | rendered = pieces["closest-tag"] |
| 569 | rendered += "-%d-g%s" % (pieces["distance"], pieces["short"]) |
| 570 | else: |
| 571 | # exception #1 |
| 572 | rendered = pieces["short"] |
| 573 | if pieces["dirty"]: |
| 574 | rendered += "-dirty" |
| 575 | return rendered |
| 576 | |
| 577 | |
| 578 | def render(pieces, style): |
no outgoing calls
no test coverage detected
searching dependent graphs…