mirror of
https://github.com/ryanoasis/nerd-fonts.git
synced 2024-09-19 09:51:48 +02:00
Only delete based on pattern
This commit is contained in:
parent
d1143347e0
commit
78954bfecf
1 changed files with 3 additions and 1 deletions
|
@ -21,14 +21,16 @@ cd "$scripts_root_dir/../../patched-fonts/" || {
|
|||
if [ $# -eq 1 ]
|
||||
then
|
||||
pattern="./$1"
|
||||
search_pattern="*$1*.zip"
|
||||
echo "$LINE_PREFIX Limiting archive to pattern './$pattern'"
|
||||
else
|
||||
pattern="."
|
||||
search_pattern="*.zip"
|
||||
echo "$LINE_PREFIX No limting pattern given, will search entire folder"
|
||||
fi
|
||||
|
||||
# clear out the directory zips
|
||||
find "${outputdir:?}" -name "*.zip" -type f -delete
|
||||
find "${outputdir:?}" -name "$search_pattern" -type f -delete
|
||||
|
||||
#find ./Hack -maxdepth 0 -type d | # uncomment to test 1 font
|
||||
#find ./ProFont -maxdepth 0 -type d | # uncomment to test 1 font
|
||||
|
|
Loading…
Reference in a new issue