mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 17:37:37 +00:00
Ports: Simplify the output from identify
when installing icons
This ensures that the correct index is always used when selecting an image of a particular size.
This commit is contained in:
parent
d09271be35
commit
5af7d5da2f
1 changed files with 1 additions and 1 deletions
|
@ -224,7 +224,7 @@ install_icon() {
|
|||
fi
|
||||
|
||||
for icon_size in "16x16" "32x32"; do
|
||||
index=$(run identify "$icon" | grep "$icon_size" | grep -oE "\[[0-9]+\]" | tr -d "[]" | head -n1)
|
||||
index=$(run identify -format '%p;%wx%h\n' "$icon" | grep "$icon_size" | cut -d";" -f1 | head -n1)
|
||||
if [ -n "$index" ]; then
|
||||
run convert "${icon}[${index}]" "app-${icon_size}.png"
|
||||
else
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue