diff options
Diffstat (limited to '_tils/2020-11-08-find-broken-symlinks-with-find.md')
-rw-r--r-- | _tils/2020-11-08-find-broken-symlinks-with-find.md | 36 |
1 files changed, 0 insertions, 36 deletions
diff --git a/_tils/2020-11-08-find-broken-symlinks-with-find.md b/_tils/2020-11-08-find-broken-symlinks-with-find.md deleted file mode 100644 index bc97fc6..0000000 --- a/_tils/2020-11-08-find-broken-symlinks-with-find.md +++ /dev/null @@ -1,36 +0,0 @@ ---- - -title: Find broken symlinks with "find" - -date: 2020-11-08 - -layout: post - -lang: en - -ref: find-broken-symlinks-with-find - -eu_categories: shell - ---- - -The `find` command knows how to show broken symlinks: - -```shell -find . -xtype l -``` - -This was useful to me when combined with [Git Annex][git-annex]. Its -[`wanted`][git-annex-wanted] option allows you to have a "sparse" checkout of -the content, and save space by not having to copy every annexed file locally: - -```shell -git annex wanted . 'exclude=Music/* and exclude=Videos/*' -``` - -You can `find` any broken symlinks outside those directories by querying with -Git Annex itself, but `find . -xtype l` works on other places too, where broken -symlinks might be a problem. - -[git-annex]: https://git-annex.branchable.com/ -[git-annex-wanted]: https://git-annex.branchable.com/git-annex-wanted/ |