Last active
August 28, 2018 11:26
-
-
Save d-Pixie/654d11c22438f0e3442e2edb87271998 to your computer and use it in GitHub Desktop.
Imagemagick convert, resize to all favicon and app icon formats.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8"?> | |
<browserconfig><msapplication><tile><square70x70logo src="/ms-icon-70x70.png"/><square150x150logo src="/ms-icon-150x150.png"/><square310x310logo src="/ms-icon-310x310.png"/><TileColor>#ffffff</TileColor></tile></msapplication></browserconfig> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ $# -lt 1 ] | |
then | |
echo "Give input filename as first argument." | |
exit 1 | |
fi | |
if [ $# -gt 1 ] | |
then | |
echo "This script only accepts one argument, the input filename." | |
exit 1 | |
fi | |
convert "$1" -strip -background none -write mpr:main +delete \ | |
mpr:main -resize "36x36!" -write android-icon-36x36.png +delete \ | |
mpr:main -resize "48x48!" -write android-icon-48x48.png +delete \ | |
mpr:main -resize "72x72!" -write android-icon-72x72.png +delete \ | |
mpr:main -resize "96x96!" -write android-icon-96x96.png +delete \ | |
mpr:main -resize "144x144!" -write android-icon-144x144.png +delete \ | |
mpr:main -resize "192x192!" -write android-icon-192x192.png +delete \ | |
mpr:main -resize "57x57!" -write apple-icon-57x57.png +delete \ | |
mpr:main -resize "60x60!" -write apple-icon-60x60.png +delete \ | |
mpr:main -resize "72x72!" -write apple-icon-72x72.png +delete \ | |
mpr:main -resize "76x76!" -write apple-icon-76x76.png +delete \ | |
mpr:main -resize "114x114!" -write apple-icon-114x114.png +delete \ | |
mpr:main -resize "120x120!" -write apple-icon-120x120.png +delete \ | |
mpr:main -resize "144x144!" -write apple-icon-144x144.png +delete \ | |
mpr:main -resize "152x152!" -write apple-icon-152x152.png +delete \ | |
mpr:main -resize "180x180!" -write apple-icon-180x180.png +delete \ | |
mpr:main -resize "192x192!" -write apple-icon-precomposed.png +delete \ | |
mpr:main -resize "192x192!" -write apple-icon.png +delete \ | |
mpr:main -resize "16x16!" -write favicon-16x16.png +delete \ | |
mpr:main -resize "32x32!" -write favicon-32x32.png +delete \ | |
mpr:main -resize "96x96!" -write favicon-96x96.png +delete \ | |
mpr:main -resize "70x70!" -write ms-icon-70x70.png +delete \ | |
mpr:main -resize "144x144!" -write ms-icon-144x144.png +delete \ | |
mpr:main -resize "150x150!" -write ms-icon-150x150.png +delete \ | |
mpr:main -resize "310x310!" -write ms-icon-310x310.png +delete \ | |
mpr:main -resize "16x16!" favicon.ico |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<link rel="apple-touch-icon" sizes="57x57" href="apple-icon-57x57.png"> | |
<link rel="apple-touch-icon" sizes="60x60" href="apple-icon-60x60.png"> | |
<link rel="apple-touch-icon" sizes="72x72" href="apple-icon-72x72.png"> | |
<link rel="apple-touch-icon" sizes="76x76" href="apple-icon-76x76.png"> | |
<link rel="apple-touch-icon" sizes="114x114" href="apple-icon-114x114.png"> | |
<link rel="apple-touch-icon" sizes="120x120" href="apple-icon-120x120.png"> | |
<link rel="apple-touch-icon" sizes="144x144" href="apple-icon-144x144.png"> | |
<link rel="apple-touch-icon" sizes="152x152" href="apple-icon-152x152.png"> | |
<link rel="apple-touch-icon" sizes="180x180" href="apple-icon-180x180.png"> | |
<link rel="icon" type="image/png" sizes="192x192" href="android-icon-192x192.png"> | |
<link rel="icon" type="image/png" sizes="32x32" href="favicon-32x32.png"> | |
<link rel="icon" type="image/png" sizes="96x96" href="favicon-96x96.png"> | |
<link rel="icon" type="image/png" sizes="16x16" href="favicon-16x16.png"> | |
<link rel="manifest" href="manifest.json"> | |
<meta name="msapplication-TileColor" content="#ffffff"> | |
<meta name="msapplication-TileImage" content="ms-icon-144x144.png"> | |
<meta name="theme-color" content="#ffffff"> | |
</head> | |
<body> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "App", | |
"icons": [ | |
{ | |
"src": "\/android-icon-36x36.png", | |
"sizes": "36x36", | |
"type": "image\/png", | |
"density": "0.75" | |
}, | |
{ | |
"src": "\/android-icon-48x48.png", | |
"sizes": "48x48", | |
"type": "image\/png", | |
"density": "1.0" | |
}, | |
{ | |
"src": "\/android-icon-72x72.png", | |
"sizes": "72x72", | |
"type": "image\/png", | |
"density": "1.5" | |
}, | |
{ | |
"src": "\/android-icon-96x96.png", | |
"sizes": "96x96", | |
"type": "image\/png", | |
"density": "2.0" | |
}, | |
{ | |
"src": "\/android-icon-144x144.png", | |
"sizes": "144x144", | |
"type": "image\/png", | |
"density": "3.0" | |
}, | |
{ | |
"src": "\/android-icon-192x192.png", | |
"sizes": "192x192", | |
"type": "image\/png", | |
"density": "4.0" | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
All the scripts and files you need to setup a webapp with a complete set of icons and colors.
If you know of any that are missing, please comment.