Logic for matching passwords ~/.pgpass passwords to db specs.
Logic for matching passwords ~/.pgpass passwords to db specs.
(parse-pgpass-line s)The .pgpass files has lines of format: hostname:port:database:username:password Return a map of fields {:pg-hostname "*" ...}
The .pgpass files has lines of format: hostname:port:database:username:password
Return a map of fields {:pg-hostname "*" ...}(pgpass-lookup spec)Look up password from ~/.pgpass based on db spec {:host ... :port ... :dbname ... :user ...}
Look up password from ~/.pgpass based on db spec {:host ... :port ... :dbname ... :user ...}
(pgpass-matches? {:keys [host port dbname user]}
{:keys [pg-hostname pg-port pg-database pg-username
pg-password]})(filter (partial pgpass-matches? spec) pgpass-lines)
(filter (partial pgpass-matches? spec) pgpass-lines)
(read-pgpass)Find ~/.pgpass, read it and parse lines into maps
Find ~/.pgpass, read it and parse lines into maps
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |