Skip to content

Instantly share code, notes, and snippets.

@anwas
Last active October 23, 2021 02:24
Show Gist options
  • Select an option

  • Save anwas/16a068ab8f4c96f0c56d6ccf2a814f0d to your computer and use it in GitHub Desktop.

Select an option

Save anwas/16a068ab8f4c96f0c56d6ccf2a814f0d to your computer and use it in GitHub Desktop.
[Rekursiškai trinti aplankus pagal pavadinimą] #cli #folders
#!/bin/bash
find . -type d -name .metadata -exec rm -rf {} \;
# or files by wildcard
find . -type f -name *.part -exec rm -rf {} \;
# The script starts within the current directory,
# so be sure you navigate to the directory you want to start searching from first.
# This script would work on any search type;
# simply replace ".metadata" with the search of your choosing but be careful:
# if your search term is too general, you may end up deleting a bunch of stuff you don't want to.
@anwas
Copy link
Copy Markdown
Author

anwas commented Feb 28, 2018

info: https://davidwalsh.name/delete-svn

The script starts within the current directory, so be sure you navigate to the directory you want to start searching from first. This script would work on any search type; simply replace ".metadata" with the search of your choosing but be careful: if your search term is too general, you may end up deleting a bunch of stuff you don't want to

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment