Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add --filter-jq option #1372

Merged
merged 11 commits into from
Nov 30, 2024
Merged

feat: Add --filter-jq option #1372

merged 11 commits into from
Nov 30, 2024

Conversation

aawsome
Copy link
Member

@aawsome aawsome commented Nov 30, 2024

Adds filtering using jq syntax. You can do something like --filter-jq '.summary.files_new > 51' - works similar to what you'd expect from jq.

Also puts the rhai and jq filtering into features which are enabled by default.

@aawsome aawsome requested a review from simonsan November 30, 2024 20:38
Cargo.toml Outdated Show resolved Hide resolved
src/filtering.rs Outdated Show resolved Hide resolved
src/filtering.rs Outdated Show resolved Hide resolved
simonsan
simonsan previously approved these changes Nov 30, 2024
@simonsan simonsan enabled auto-merge November 30, 2024 20:58
@simonsan simonsan disabled auto-merge November 30, 2024 21:06
@simonsan simonsan merged commit c571279 into main Nov 30, 2024
25 checks passed
@simonsan simonsan deleted the jq branch November 30, 2024 21:06
aawsome added a commit that referenced this pull request Dec 2, 2024
## 🤖 New release
* `rustic-rs`: 0.9.4 -> 0.9.5 (✓ API compatible changes)

<details><summary><i><b>Changelog</b></i></summary><p>

<blockquote>

## [0.9.5](v0.9.4...v0.9.5)
- 2024-12-02

### Added

- *(commands)* More dump options
([#1339](#1339))
- shut down gracefully with ctrl+c
([#1364](#1364))
- Add --filter-jq option
([#1372](#1372))
- *(async)* use `is_async_compatible()` to determine backend
incompatibility and error out
([#1355](#1355))
- *(commands)* Add `mount` command
([#973](#973))

### Fixed

- *(commands)* run backup hooks before checking source dir
([#1374](#1374))
- *(commands)* Use spawn_blocking in webdav when calling rustic_core
([#1365](#1365))
- *(filesystem)* Use channels to communicate within webdav filesystem
([#1361](#1361))

### Other

- Add documentation for `minutely` keep option
([#1371](#1371))
- update snapshots to include minutely configuration options
- *(deps)* update rustic_core, bytes, and libc dependencies to latest
versions
- simplify lifetime annotations in OpenFileReader and TreeIterItem
implementations
- clean up whitespace and update clippy linting allowances
- *(deps)* update dependencies to latest versions
- *(deps)* update lockfile to get rid of vulnerable `url` version
- *(mount)* rename fields for clarity, add user options for mount
([#1353](#1353))
- *(deps)* update dependencies
- *(deps)* don't use rustic_core webdav feature
([#1367](#1367))
- Revert "fix(filesystem): Use channels to communicate within webdav
filesystem ([#1361](#1361))"
- Revert "feat(async): use `is_async_compatible()` to determine backend
incompatibility and error out
([#1355](#1355))"
- move `webdavfs` from `rustic_core` to `rustic-rs`
([#1363](#1363))
- *(clippy)* comment out unused lints in lib.rs
- *(clippy)* apply fixes automatically
- use BTreeMap for env in global options
([#1360](#1360))
- add tiny framework for testing rustic's compat with latest restic
([#1303](#1303))
- use snapshot tests for default config, show-config and completions
([#1359](#1359))
- *(deps)* update dependencies rustic_core, rustic_backend,
rustic_testing, and migrate to conflate 0.3
([#1357](#1357))
- fix typos
- *(build)* add platform-dependent settings and remove ci flag for extra
features
- clarify `--use-profile` command in config by using long form
([#1344](#1344))
- *(deps)* update core and testing crates
([#1340](#1340))
</blockquote>


</p></details>

---
This PR was generated with
[release-plz](https://github.com/MarcoIeni/release-plz/).

---------

Co-authored-by: rustic-release-plz[bot] <182542030+rustic-release-plz[bot]@users.noreply.github.com>
Co-authored-by: Alexander Weiss <alex@weissfam.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants