You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
TRaSH-Guides/docs/Hardlinks/Replace-copies-with-hardlin...

49 lines
1.7 KiB

# Replace copies with hardlinks
You recently switched to a proper setup that supports Hardlinks and Instant Moves (Atomic-Moves).
And you would like to replace copies with hardlinks ?
If your Operating System supports it you could make use of [Jdupes](https://codeberg.org/jbruchon/jdupes).
## Usage
!!! info ""
chore(editorconfig): Add more extensions (#1410) * Add more extensions to editorconfig Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat(editorconfig): update indent size * Revert "feat(editorconfig): update indent size" This reverts commit 30e5918efe499ebf05559b19bdb140e75bd0d31b. * style: :lipstick: format json files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format yaml files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format other files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: editorconfig lint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * revert: :fire: remove deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: fix incorrect prior merges Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: change json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * style: :lipstick: format json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * update(formatting/py): run pep8 formatting --------- Signed-off-by: Eric Nemchik <eric@nemchik.com> Signed-off-by: GitHub <noreply@github.com> Co-authored-by: FonduemangVI <15520607+FonduemangVI@users.noreply.github.com> Co-authored-by: FonduemangVI <michael.thomas@vualtlabs1226.com> Co-authored-by: zakary <zak@ary.dev>
3 weeks ago
I won't cover every command :bangbang:
If you want to know what else [Jdupes](https://codeberg.org/jbruchon/jdupes) can do please read the manual.
!!! tip
chore(editorconfig): Add more extensions (#1410) * Add more extensions to editorconfig Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat(editorconfig): update indent size * Revert "feat(editorconfig): update indent size" This reverts commit 30e5918efe499ebf05559b19bdb140e75bd0d31b. * style: :lipstick: format json files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format yaml files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format other files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: editorconfig lint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * revert: :fire: remove deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: fix incorrect prior merges Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: change json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * style: :lipstick: format json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * update(formatting/py): run pep8 formatting --------- Signed-off-by: Eric Nemchik <eric@nemchik.com> Signed-off-by: GitHub <noreply@github.com> Co-authored-by: FonduemangVI <15520607+FonduemangVI@users.noreply.github.com> Co-authored-by: FonduemangVI <michael.thomas@vualtlabs1226.com> Co-authored-by: zakary <zak@ary.dev>
3 weeks ago
This process can take a long time and a pretty big hit on your resources depending on how big your library is, I did notice the first time it takes longer then the second time. Not sure if this is a cache thing or something else.
- That's why I suggest to do it based on categories (Movies, TV, Music etc).
- I don't suggest to use this on a cloud based setup.
```bash
jdupes [options] DIR1 DIR2
```
This will do a dry run and summarize at the end.
```bash
jdupes -rMX onlyext:mp4,mkv,avi "/data/torrents/movies/" "/data/media/movies"
```
This will hard link all duplicate files without prompting.
```bash
jdupes -rLX onlyext:mp4,mkv,avi "/data/torrents/movies/" "/data/media/movies"
```
!!! bug ""
chore(editorconfig): Add more extensions (#1410) * Add more extensions to editorconfig Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat(editorconfig): update indent size * Revert "feat(editorconfig): update indent size" This reverts commit 30e5918efe499ebf05559b19bdb140e75bd0d31b. * style: :lipstick: format json files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format yaml files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format other files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: editorconfig lint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * revert: :fire: remove deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: fix incorrect prior merges Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: change json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * style: :lipstick: format json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * update(formatting/py): run pep8 formatting --------- Signed-off-by: Eric Nemchik <eric@nemchik.com> Signed-off-by: GitHub <noreply@github.com> Co-authored-by: FonduemangVI <15520607+FonduemangVI@users.noreply.github.com> Co-authored-by: FonduemangVI <michael.thomas@vualtlabs1226.com> Co-authored-by: zakary <zak@ary.dev>
3 weeks ago
Windows allows a maximum of 1023 hard links per file
!!! Warning
chore(editorconfig): Add more extensions (#1410) * Add more extensions to editorconfig Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat(editorconfig): update indent size * Revert "feat(editorconfig): update indent size" This reverts commit 30e5918efe499ebf05559b19bdb140e75bd0d31b. * style: :lipstick: format json files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format yaml files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format other files Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: format md files Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: markdownlint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: editorconfig lint fixes Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * feat: :rocket: deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * revert: :fire: remove deploy preview Signed-off-by: Eric Nemchik <eric@nemchik.com> * fix: :bug: fix incorrect prior merges Signed-off-by: Eric Nemchik <eric@nemchik.com> * style: :lipstick: change json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * style: :lipstick: format json to 2 spaces Signed-off-by: GitHub <noreply@github.com> * update(formatting/py): run pep8 formatting --------- Signed-off-by: Eric Nemchik <eric@nemchik.com> Signed-off-by: GitHub <noreply@github.com> Co-authored-by: FonduemangVI <15520607+FonduemangVI@users.noreply.github.com> Co-authored-by: FonduemangVI <michael.thomas@vualtlabs1226.com> Co-authored-by: zakary <zak@ary.dev>
3 weeks ago
The `-Q` or `--quick` option only reads each file once, hashes it, and performs comparisons based solely on the hashes. There is a small but significant risk of a hash collision which is the purpose of the failsafe byte-for-byte comparison that this option explicitly bypasses. Do not use it on ANY data set for which any amount of data loss is unacceptable. You have been warned!
{! include-markdown "../../includes/support.md" !}