(ctx, short=True)
| 313 | |
| 314 | |
| 315 | def _git_current_sha(ctx, short=True): |
| 316 | args = ["rev-parse"] |
| 317 | if short: |
| 318 | args.append("--short") |
| 319 | args.append("HEAD") |
| 320 | cmd = _git_command(ctx, args) |
| 321 | res = _run(cmd, check=True, capture_output=True) |
| 322 | return res.stdout.decode("utf8").strip() |
| 323 | |
| 324 | |
| 325 | def _sanitize_for_oci_tag(branch_name): |
no test coverage detected