Skip to content

align tag hangs when user has tag.gpgSign = true in git config #39

@nwarlen

Description

@nwarlen

When a user has tag.gpgSign set to true in their global or local git config, running align tag hangs indefinitely. This is because GPG-signed tags are annotated tags, which require a message. Without a -m flag, git opens an editor to collect the tag message. Since align captures stdout and stderr into buffers (bytes.Buffer), the subprocess has no TTY, so the editor has nowhere to display and hangs forever.

Steps to Reproduce

  1. Enable GPG tag signing: git config --global tag.gpgSign true
  2. Run align tag -v
  3. Observe the output stops after printing the "directories" header and never completes

Expected Behavior

The command should either complete successfully or fail with a clear error message.

Suggested Fixes

  • Fail loudly: Detect tag.gpgSign in git config before running and exit with a clear error message explaining the incompatibility, rather than hanging silently.
  • Support annotated signed tags: Pass -m (or a configurable message) so that signed/annotated tags can be created without requiring an editor.
  • Add a --no-sign flag: Allow users to override their git config by passing --no-sign through to the underlying git tag command.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions