summaryrefslogtreecommitdiff
path: root/src/cmd/list_files.rs
AgeCommit message (Collapse)AuthorFilesLines
2022-10-23refactor: use clap instead of structoptLars Wirzenius1-3/+3
clap version 3 basically replaces structopt entirely. Sponsored-by: author
2022-03-22feat! store list of generations in a "client trust root" chunkLars Wirzenius1-1/+7
Backups made with this version can't be restored with old clients, and vice version. Sponsored-by: author
2022-03-06refactor: use new database abstraction for generationsLars Wirzenius1-2/+2
Sponsored-by: author
2022-01-16refactor: rename AsyncBackupClient to just BackupClientLars Wirzenius1-2/+2
There is only async. Sponsored-by: author
2021-12-31docs: add documentation comments to crateLars Wirzenius1-0/+5
Also, make it an error for a public symbol to not be documented. Sponsored-by: author
2021-08-01refactor: add a type alias for generation idsLars Wirzenius1-1/+1
This will make it harder to accidentally use a string. Can still be confused with a chunk id. Sponsored-by: author
2021-07-30cleanup: fix things rustc/clipppy now complain aboutLars Wirzenius1-1/+1
Mostly https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow. Sponsored-by: author
2021-07-23refactor: use async for "obnam list-files"Lars Wirzenius1-4/+10
Sponsored-by: author
2021-04-26Extend the iterator to users of LocalGeneration::files()Alexander Batischev1-1/+1
2021-04-26Expose fallibility of individual SQL resultsAlexander Batischev1-0/+1
`LocalGeneration::sql::files()` runs an SQL query, iterates over the results and collects the rows into a `Vec`. This can fail at any step: the query might fail to run, or one of the rows might fail to be fetched or processed. Right now, we lump all those failures into a `Result` that wraps the whole return value. This is only possible because we process each row before returning. Once `Vec` is replaced by an iterator, we won't have that luxury anymore, so we now wrap each individual element into its own `Result` (as well as wrapping the whole vector into a `Result` of its own).
2021-04-10refactor: struct ListFiles subcommandLars Wirzenius1-10/+19
2021-04-10refactor: move ClientConfig into its own moduleLars Wirzenius1-1/+1
2021-03-03fix: allow generation temporary files to be automatically deletedLars Wirzenius1-11/+2
By not calling NamedTempFile::persist, the files get deleted automatically when the file is closed or the struct is dropped. Previously we were deleting the temporary files manually, which meant that sometimes they weren't deleted if the program crashed at an unfortunate time.
2021-02-19feat: backup and restore named pipes (FIFOs)Lars Wirzenius1-0/+1
2021-02-19feat: back up and restore Unix domain socketsLars Wirzenius1-0/+1
2021-02-06feat: client verifies server's TLS certificate by defaultLars Wirzenius1-1/+1
Configuration setting can disable it.
2021-02-04refactor: have per-module error enumsLars Wirzenius1-5/+2
This means that a function that parses step bindings can't return an error that the document is missing a title. Such an error return would be nonsensical, and we use the Rust type system to prevent it, at a small cost of being a bit verbose. Additional benefit is that the library portion of Obnam doesn't return anyhow::Result values anymore.
2021-01-05refactor: add BackedUpFile to avoid using a tupleLars Wirzenius1-3/+4
The struct is easier to use right.
2021-01-04feat! record whether file was backed up and why, in a generationLars Wirzenius1-0/+42
This changes SQL schema.