]> git.armaanb.net Git - logo.git/commitdiff
Ignore the pregenerated logo when running svg2img
authorArmaan Bhojwani <me@armaanb.net>
Tue, 19 Jan 2021 23:45:24 +0000 (18:45 -0500)
committerArmaan Bhojwani <me@armaanb.net>
Tue, 19 Jan 2021 23:45:24 +0000 (18:45 -0500)
README.md
logo-square-color-dark-256.png [deleted file]
logo.png [new file with mode: 0644]
svg2img

index bae6492917681418a16e2b51b528dee4cf1189b4..f8c68169c06e8aa02f3c11480cac4489fb37f292 100644 (file)
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
 # personal logo
 A logo/icon/pfp I designed for myself
 
-![Logo](logo-square-color-dark-256.png)
+![Logo](logo.png)
 
 ## Generation
 Running `svg2img <formats>` will generate all the variants of the logo in the formats of your choice. The logo goes from the template to SVG to PNG to whatever format you choose. It supports any format that ImageMagick supports, as well as ASCII and Unicode.
diff --git a/logo-square-color-dark-256.png b/logo-square-color-dark-256.png
deleted file mode 100644 (file)
index d317f25..0000000
Binary files a/logo-square-color-dark-256.png and /dev/null differ
diff --git a/logo.png b/logo.png
new file mode 100644 (file)
index 0000000..d317f25
Binary files /dev/null and b/logo.png differ
diff --git a/svg2img b/svg2img
index 44af51c90635242aefff8a33dce1f61ebca768cd..2dcf70e83263b2b503e7f809a27522a79268a381 100755 (executable)
--- a/svg2img
+++ b/svg2img
@@ -56,7 +56,8 @@ for arg in ${@};do
   
   [[ ${arg} == "svg" ]] && exit 0
   
-  [[ ${arg} == "png" ]] && find . -name *.png -exec rm -v {} \;
+  [[ ${arg} == "png" ]] && find . -name *.png -not -iwholename ./logo.png \
+    -exec rm -v {} \;
   
   if [[ (! -d "square/png" || ! -d "circle/png") || (${arg} == "png") ]]; then
     echo "Generating PNGs"
@@ -137,6 +138,6 @@ for arg in ${@};do
     while read PAT; do
       echo "Generating ${arg}s"
       convert -verbose ${PAT} ${PAT//png/${arg}}
-    done < <(find -name *.png)
+    done < <(find -name *.png -not -iwholename ./logo.png)
   done
 done