Commit 19cae99
committed
feat: Add support for DB_PASS_FILE
This commit introduces support for reading the database password from a file specified by the `DB_PASS_FILE` environment variable or the `--pass-file` CLI flag.
- Added `--pass-file` flag and `DB_PASS_FILE` environment variable.
- Updated logic in `cmd/root.go` to read the password from the specified file.
- Ensured that an explicitly set password via `DB_PASS` or `--pass` takes precedence.
- Updated documentation in `docs/configuration.md`.
- Added tests in `cmd/dump_test.go` to cover the new functionality and precedence logic.1 parent d70d361 commit 19cae99
File tree
4 files changed
+31
-0
lines changed- cmd
- testdata
- docs
4 files changed
+31
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
43 | 57 | | |
44 | 58 | | |
45 | 59 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
167 | 167 | | |
168 | 168 | | |
169 | 169 | | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
170 | 182 | | |
171 | 183 | | |
172 | 184 | | |
| |||
222 | 234 | | |
223 | 235 | | |
224 | 236 | | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
225 | 240 | | |
226 | 241 | | |
227 | 242 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| 71 | + | |
71 | 72 | | |
72 | 73 | | |
73 | 74 | | |
| |||
0 commit comments