gen wp thumb
This commit is contained in:
@@ -98,7 +98,7 @@ if [ ! -f "$WALLPALDIR/${NAME}.clr" ]; then
|
|||||||
magick ${WALLPATH} -resize 25% -colors 12 -unique-colors txt:- |grep -v '^#'| awk '{print substr($3,1,7)}' |pastel sort-by brightness |pastel format hex > "$WALLPALDIR/$NAME.clr"
|
magick ${WALLPATH} -resize 25% -colors 12 -unique-colors txt:- |grep -v '^#'| awk '{print substr($3,1,7)}' |pastel sort-by brightness |pastel format hex > "$WALLPALDIR/$NAME.clr"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
## kolory tapety do pliku wpcolors.clr
|
||||||
cat "$WALLPALDIR/${NAME}.clr" > "$HOME/.config/mabox/wpcolors.clr"
|
cat "$WALLPALDIR/${NAME}.clr" > "$HOME/.config/mabox/wpcolors.clr"
|
||||||
|
|
||||||
|
|
||||||
@@ -107,7 +107,11 @@ THUMBDIR="$HOME/.cache/colorizer/thumbs"
|
|||||||
mkdir -p ${THUMBDIR}
|
mkdir -p ${THUMBDIR}
|
||||||
THUMB="${THUMBDIR}/${NAME}.png"
|
THUMB="${THUMBDIR}/${NAME}.png"
|
||||||
if [[ ! -f "$THUMB" ]]; then
|
if [[ ! -f "$THUMB" ]]; then
|
||||||
magick ${WALLPATH} -resize 270x150^ -gravity center -extent 266x146 -bordercolor '#DDDDDD' -border 2 ${THUMB}
|
magick ${WALLPATH} -resize 270x150^ -gravity center -extent 266x146 -bordercolor '#DDDDDD' -border 2 ${THUMB}
|
||||||
|
|
||||||
|
cp ${THUMB} "$HOME/.config/mabox/wpthumb.png"
|
||||||
|
else
|
||||||
|
cp ${THUMB} "$HOME/.config/mabox/wpthumb.png"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -106,7 +106,11 @@ THUMBDIR="$HOME/.cache/colorizer/thumbs"
|
|||||||
mkdir -p ${THUMBDIR}
|
mkdir -p ${THUMBDIR}
|
||||||
THUMB="${THUMBDIR}/${NAME}.png"
|
THUMB="${THUMBDIR}/${NAME}.png"
|
||||||
if [[ ! -f "$THUMB" ]]; then
|
if [[ ! -f "$THUMB" ]]; then
|
||||||
magick ${WALLPATH} -resize 270x150^ -gravity center -extent 266x146 -bordercolor '#DDDDDD' -border 2 ${THUMB}
|
magick ${WALLPATH} -resize 270x150^ -gravity center -extent 266x146 -bordercolor '#DDDDDD' -border 2 ${THUMB}
|
||||||
|
|
||||||
|
cp ${THUMB} "$HOME/.config/mabox/wpthumb.png"
|
||||||
|
else
|
||||||
|
cp ${THUMB} "$HOME/.config/mabox/wpthumb.png"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user