Commit Graph

1583 Commits

Author SHA1 Message Date
simonsan
20ca9fc902
chore: remove -dev description from version for release-plz to work
Signed-off-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-24 12:58:00 +02:00
simonsan
e5eaa6f34a
ci: remove release-pr workflow and replace with release-plz
Signed-off-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-24 12:55:28 +02:00
simonsan
3102d93795
ci(cd): try fixing nightly release pipeline
Signed-off-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-24 12:39:46 +02:00
aawsome
baeb27adfa
chore(deps): Update to new releases (#1255) 2024-09-24 10:32:58 +02:00
aawsome
5ec9652511
feat(commands): Add list indexpacks and list indexcontent commands (#1254)
This allows better analysis of reported bugs related to the index.
2024-09-24 00:36:45 +02:00
aawsome
f5499db21b
perf: Reduce memory usage of restore (#1069)
reduce memory usage of the `restore` command by removing the data
entries from the index before doing the actual restore.

see https://github.com/rustic-rs/rustic/issues/1067

TODO:
- [x] remove Cargo changes once
https://github.com/rustic-rs/rustic_core/pull/166 is merged
2024-09-23 19:54:28 +00:00
aawsome
4c4e820400
chore: Update to newest rustic_core (#1248)
Signed-off-by: simonsan <14062932+simonsan@users.noreply.github.com>
Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-23 21:34:51 +02:00
aawsome
49e12a5af6
feat(commands): Add option --only-identical for diff to allow for bitrot check (#1250)
see https://github.com/rustic-rs/rustic/discussions/1246

Discussion: Is `--only-identical` a good name?

---------

Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-23 15:07:20 +00:00
aawsome
86fa8551f4
fix(config)!: use multiple options only as array in config profile (#1240)
Consistently uses singular and plural names for options in config and
CLI

BREAKING CHANGE: This requires to adapt CLI calls and config keys.

Affected options:
- `glob` -> `globs` in config profile
- `iglob` -> `iglobs` in config profile
- `glob`-file -> `glob-files` in config profile
- `iglob-file` -> `iglob-files` in config profile
- `custom-ignore-file` -> `custom-ignore-files` in config profile
- `tag`-> `tags` in config profile
- `keep-tags` -> now only array
- `keep-ids` -> now only array
- `use-profile`-> `use-profiles` in config profile
- `backup.sources` -> `backup.snapshots` in config profile
- `filter-host` -> `filter-hosts` in config profile
- `filter-label` -> `filter-labels` in config profile

---------

Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-23 15:04:45 +00:00
aawsome
14e4c66edb
fix(interactive): Allow snapshots to be modified and marked to forget (#1253)
closes #1252
2024-09-23 14:49:39 +00:00
Krzysztof Małysa
7421d0acf3
fix: make ls and find show the year of mtime date (#1249)
Fixes #1239

Co-authored-by: aawsome <37850842+aawsome@users.noreply.github.com>
2024-09-22 21:09:46 +00:00
Krzysztof Małysa
63d5f166cd
feat(commands): ls: Add option --json (#1251)
Co-authored-by: aawsome <37850842+aawsome@users.noreply.github.com>
2024-09-22 21:03:29 +00:00
Krzysztof Małysa
a21c991b33
fix: ls: Remove printing trailing space (#1247)
Paths are separated by a newline, printing space only hinders parsing.
Also paths are now displayed using `Path::display()`.
2024-09-21 22:35:45 +00:00
aawsome
ee6380e0b3
feat(commands)!: copy: Use config profile as target (#1131)
Breaking change: Targets for the `copy` command must now be given by
using config profile(s).

---------

Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-18 19:10:36 +00:00
aawsome
959c0576bc
feat(commands): backup: Add option --long (#1159)
closes #1156

Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-18 19:04:55 +00:00
nardoor
b865901a0c
fix: webdav/forget: correctly use application config (#1241)
The `inner_run` implementation used `self`
to read its config when it should use `RUSTIC_APP.config()`.

Some might say this is counterintuitive.
fixes #1163
also now correctly respects having `prune = true` in the config profile.

---------

Co-authored-by: Alexander Weiss <alex@weissfam.de>
Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-18 14:42:18 +00:00
Marti Raudsepp
abf1835cbd
doc: update RepositoryErrorKind rustdoc following rustic_core change (#1237)
Companion PR for https://github.com/rustic-rs/rustic_core/pull/265

It renames `PasswordCommandParsingFailed` to
`PasswordCommandExecutionFailed`
2024-09-13 22:04:28 +02:00
Alexander Weiss
77ca7ff72f set development version 2024-09-10 22:39:16 +02:00
simonsan
e762270eb6
ci: add flag for building with self-update feature for nightly and CD 2024-09-10 14:36:59 +02:00
Caleb Maclennan
ab13071e07
chore: Remove self-update from default crate features (#1139)
The self-updater feature is problematic for distro package builders
where the executable does not have permission and should not be trying
to monkey with the system installed binaries. Distros have their own
update mechanisms that shouldn't be tampered with by every app that
comes along. This means distro have to build with --no-default-features
for apps that include self-updaters by default, but that also means we
have to maintain a list of features we do want. This is not only tedious
it is error-prone because there is a very good chance of new features
getting overlooked when doing version bumps.

Setting up a feature group like this makes it much easier for distros to
build without the unwanted features without getting out of sync with
upstream enhancements over time.

Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-09-10 12:14:14 +00:00
aawsome
152c256bcf
prepare release 0.8.1 (#1231)
Co-authored-by: github-actions <github-actions@github.com>
2024-09-08 21:28:13 +02:00
aawsome
740cb4699d
feat(interactive): Allow to view text files (#1216)
Adds the possibility to view text files up to 1MiB in the interactive
snapshot tree view. Note this is a quick-and-dirty implementation which
could be improved better non-text-files and which could be optimized to
read files of all sizes
2024-09-08 17:32:44 +00:00
aawsome
12660103a9
feat(interactive): Allow to modify filters (#1210)
Adds the possibility to edit the filter used in the interactive
snapshots view:
- use 'V' to view or change the filter
- use 'Ctrl-v' to reset to the filter as given to the command

---------

Co-authored-by: nardor <nard0r@protonmail.com>
2024-09-08 17:31:28 +00:00
aawsome
ffe05f58d0
fix: return exitcode (#1220)
rustic now returns an error code for failing command.

Note: Some command do not fail yet fail in every cases user would expect
is. Most notably the `check` ckommand producing `error` messages may
still return error code 0.

closes #927
2024-09-07 05:28:59 +00:00
renovate[bot]
9cada7eab4
chore(deps): update actions/download-artifact digest to fa0a91b (#1212)
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[actions/download-artifact](https://togithub.com/actions/download-artifact)
| action | digest | `6b208ae` -> `fa0a91b` |

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View the
[repository job log](https://developer.mend.io/github/rustic-rs/rustic).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOC4yNi4xIiwidXBkYXRlZEluVmVyIjoiMzguMjYuMSIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOlsiQS1kZXBlbmRlbmNpZXMiXX0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: aawsome <37850842+aawsome@users.noreply.github.com>
2024-09-06 21:50:26 +02:00
aawsome
fc6f7ac847
chore: dependency updates (#1227) 2024-09-06 21:29:01 +02:00
nardoor
590b624ae3
feat: Add autocompletion hints (#1225)
## Feature

**Add auto completion hints**

This helps some shells to propose better completions.
For instance on `zsh`, no completion were proposed when doing `rustic
backup <...>[TAB]`

## Hints added
- `rustic backup <...>[TAB]`
- `rustic backup --as-path [TAB] <...>`
- `rustic backup --stdin-filename [TAB] <...>` This one is for comfort,
as the compl might not help (or might), but my opinion is that it's
better than nothing.
- `rustic diff <snapshot_id> <...>[TAB]`
- `rustic find --path <...>[TAB]`
- rustic --log-file <...>[TAB]`
2024-09-06 06:04:57 +00:00
dependabot[bot]
7e3b52049d
build(deps): bump quinn-proto from 0.11.6 to 0.11.8 (#1223)
Bumps [quinn-proto](https://github.com/quinn-rs/quinn) from 0.11.6 to
0.11.8.
<details>
<summary>Commits</summary>
<ul>
<li><a
href="7c09b02073"><code>7c09b02</code></a>
proto: bump version to 0.11.8 for release (<a
href="https://redirect.github.com/quinn-rs/quinn/issues/1981">#1981</a>)</li>
<li><a
href="59bccd2e7e"><code>59bccd2</code></a>
Version bump <code>quinn</code> to enforce patched
<code>quinn-proto</code></li>
<li><a
href="a8ec510fd1"><code>a8ec510</code></a>
proto: avoid panicking on rustls server config errors</li>
<li><a
href="c26e8cd2f7"><code>c26e8cd</code></a>
Bump versions</li>
<li><a
href="e01609ccd8"><code>e01609c</code></a>
Merge commit from fork</li>
<li><a
href="c292a3c6a6"><code>c292a3c</code></a>
Fix and test validation of IDCID length</li>
<li><a
href="bb02a12a84"><code>bb02a12</code></a>
fix(.github/android): use API level 26</li>
<li><a
href="5e5cc93645"><code>5e5cc93</code></a>
fix(.github/android): pass matrix.target and increase api to v26</li>
<li><a
href="cef42cccef"><code>cef42cc</code></a>
fix(udp): typo in sendmsg error log</li>
<li><a
href="edf16a6f10"><code>edf16a6</code></a>
ci(rust.yml): add workflow testing feature permutations</li>
<li>Additional commits viewable in <a
href="https://github.com/quinn-rs/quinn/compare/quinn-proto-0.11.6...quinn-proto-0.11.8">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=quinn-proto&package-manager=cargo&previous-version=0.11.6&new-version=0.11.8)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
You can disable automated security fix PRs for this repo from the
[Security Alerts
page](https://github.com/rustic-rs/rustic/network/alerts).

</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-04 08:00:18 +00:00
aawsome
678ab12942
doc: Update config profile readme (#1221) 2024-09-03 12:18:12 +02:00
renovate[bot]
48857246a1
chore(deps): update actions/checkout digest to 692973e (#1172)
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [actions/checkout](https://togithub.com/actions/checkout) | action |
digest | `b4ffde6` -> `692973e` |

---

> [!WARNING]
> Some dependencies could not be looked up. Check the Dependency
Dashboard for more information.

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/rustic-rs/rustic).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40MjAuMSIsInVwZGF0ZWRJblZlciI6IjM3LjQyMC4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJBLWRlcGVuZGVuY2llcyJdfQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: simonsan <14062932+simonsan@users.noreply.github.com>
2024-08-27 11:47:58 +00:00
renovate[bot]
009e57ec2e
chore(deps): update taiki-e/install-action digest to f172798 (#1042)
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [taiki-e/install-action](https://togithub.com/taiki-e/install-action)
| action | digest | `8984d60` -> `f172798` |

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Never, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View the
[repository job log](https://developer.mend.io/github/rustic-rs/rustic).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4xNTMuMiIsInVwZGF0ZWRJblZlciI6IjM4LjI2LjEiLCJ0YXJnZXRCcmFuY2giOiJtYWluIn0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-08-27 11:40:57 +00:00
aawsome
a88afdd4af
fix(build): Use cargo --locked in CI pipeline (#1207)
closes #1204
2024-08-24 19:02:16 +00:00
aawsome
3f2b7a0b78
fix(build): allow to compile without tui feature (#1208)
closes #1206
2024-08-24 19:01:42 +00:00
Alexander Weiss
f72285d81d set development version 2024-08-23 13:10:46 +02:00
aawsome
78189895f3
prepare release 0.8.0 (#1202)
Co-authored-by: github-actions <github-actions@github.com>
2024-08-22 08:37:30 +02:00
aawsome
5423186657
chore: update rustic_core and rustic_backend (#1201) 2024-08-20 19:59:10 +00:00
nardoor
1c9969cc1f
feat(diff): show diff statistics (#1178)
closes rustic-rs/rustic#440

### Description

The proposed code contains:
- a DiffStatistics structure used to hold count of stats
- this structure offers a few helping functions that will look at a
given NodeType to increment the associated counter
- it has a Display implementation used to display the statistics in
STDOUT
- this structure is used in the `diff` function

### Exemple

```bash
rustic --log-level debug -r test-repo --password password diff 8e57051d:config ./config
[INFO] using no config file, none of these exist: /home/nardor/.config/rustic/rustic.toml, /etc/rustic/rustic.toml, ./rustic.toml
[INFO] repository local:test-repo: password is correct.
[INFO] using cache at /home/nardor/.cache/rustic/3797e1fe324e97ac068e303e672da3d34af09cd73888bcfd09538cd72692bf7d
[00:00:00] reading index...               ████████████████████████████████████████          2/2                               
[00:00:00] getting snapshot...            ████████████████████████████████████████          0                                
[INFO] getting snapshot...
[00:00:00] getting snapshot...            ████████████████████████████████████████          0                                 
-    "README.md"
M    "bar"
+    "new_dir"
+    "new_dir/new_file"
-    "services"
-    "services/b2.toml"
-    "services/rclone_ovh-hot-cold.toml"
-    "services/s3_aws.toml"
-    "services/s3_idrive.toml"
-    "services/sftp.toml"
-    "services/sftp_hetzner_sbox.toml"
-    "services/webdav_owncloud_nextcloud.toml"
Files:	1 new,	8 removed, 	1 changed
Dirs:	1 new,	1 removed
Others:	0 new,	0 removed
```

### Testing

I am not sure what tests I can add.
Please let me know if you think of any test about this.

Thanks in advance for any feedback.

---------

Co-authored-by: Alexander Weiss <alex@weissfam.de>
Co-authored-by: aawsome <37850842+aawsome@users.noreply.github.com>
2024-08-10 07:51:45 +00:00
aawsome
9bdb7fe02c
chore(deps): Update dependencies (#1196)
closes #1195
2024-08-10 04:13:38 +02:00
Yonas Yanfa
402aa7c5d3
docs: Fix typo in find.rs (#1187) 2024-07-31 13:59:22 +02:00
Daniel Oliveira
cb8c3760b5
fix(tui): reset terminal no matter what (#1175)
Currently if you run `rustic snapshots -i` without a repository
configured `rustic` will leave the terminal in raw mode.

This is a simple fix to make sure the terminal is properly reset in all
situations.

close #1166

Co-authored-by: aawsome <37850842+aawsome@users.noreply.github.com>
2024-07-10 04:12:05 +00:00
Alexander Weiss
599e61a900 fix clippy lints 2024-07-10 05:50:56 +02:00
aawsome
fc8e3c5539
feat(interactive): Add better progress bars (#1152) 2024-05-14 01:13:44 +02:00
Alexander Weiss
cfd15ea52a feat: document opendal options connections and throttle 2024-05-07 16:44:45 +02:00
aawsome
7665b84f74
fix: Respect delete-protection when running forget with ids (#1149)
closes #1148
2024-05-07 10:16:50 +02:00
aawsome
7ff4d2f6ff
fix clippy lints (#1150) 2024-05-07 09:57:25 +02:00
aawsome
dcd240a50a
feat(interactive): Prompt before exiting (#1146) 2024-05-01 00:20:37 +02:00
aawsome
6bf5069d0c
add find command (#1136)
Adds the new command `find`.
This commands allows to search for glob pattern using `--glob`/`--iglob`
or given paths using `--path` in a list of snapshots.
It displays all finds and is able accumulate snapshots with identical
search result. This allows to use this command as a history search:
`rustic find --path /my/path` shows (only) all changes of that path.
2024-04-30 11:54:43 +02:00
aawsome
a6bd54c7cb
more interactive improvements (#1145)
restore:
- propose path from snapshot as target
- handle empty target

write snapshots:
- clarify that you can enter (y/n)
2024-04-29 21:44:33 +02:00
aawsome
bd726839d9
interactive improvements: reset screen on panic; key bindings (#1144)
If a panic happens, the interactive screen is now reset so the terminal
can show the panic output.
Moreover, "to-delete" was renamed to "to-forget" and the key bindings
were changed to f / Ctrl-f.
2024-04-29 18:21:34 +02:00
aawsome
23a634d06a
feat(interactive): Allow to delete snapshots (#1143) 2024-04-28 23:16:22 +02:00