NewPassProvider creates a new PassProvider instance. It verifies that `pass` is available and stores the resolved absolute path.
()
| 19 | // NewPassProvider creates a new PassProvider instance. |
| 20 | // It verifies that `pass` is available and stores the resolved absolute path. |
| 21 | func NewPassProvider() (*PassProvider, error) { |
| 22 | path, err := lookupBinary("pass", PassNotAvailableError{}) |
| 23 | if err != nil { |
| 24 | return nil, err |
| 25 | } |
| 26 | return &PassProvider{binaryPath: path}, nil |
| 27 | } |
| 28 | |
| 29 | // Get retrieves the value of a secret by its name using the `pass` CLI. |
| 30 | // The name corresponds to the path in the `pass` store. |
no test coverage detected