Class GpgConfig


  • public class GpgConfig
    extends java.lang.Object
    Typed access to GPG related configuration options.
    Since:
    5.2
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  GpgConfig.GpgFormat
      Config values for gpg.format.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private Config config  
    • Constructor Summary

      Constructors 
      Constructor Description
      GpgConfig​(Config config)
      Create a new GPG config, which will read configuration from config.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      GpgConfig.GpgFormat getKeyFormat()
      Retrieves the config value of gpg.format.
      java.lang.String getSigningKey()
      Retrieves the config value of user.signingKey.
      boolean isSignCommits()
      Retrieves the config value of commit.gpgSign.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • config

        private final Config config
    • Constructor Detail

      • GpgConfig

        public GpgConfig​(Config config)
        Create a new GPG config, which will read configuration from config.
        Parameters:
        config - the config to read from
    • Method Detail

      • getSigningKey

        public java.lang.String getSigningKey()
        Retrieves the config value of user.signingKey.
        Returns:
        the value of user.signingKey (may be null)
      • isSignCommits

        public boolean isSignCommits()
        Retrieves the config value of commit.gpgSign.
        Returns:
        the value of commit.gpgSign (defaults to false)