mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-06-29 18:38:36 +08:00
Add a script to add the status bar to the screenshots
The ones generated by the flutter driver do not have status bars
This commit is contained in:
20
scripts/finalize_screenshots.sh
Executable file
20
scripts/finalize_screenshots.sh
Executable file
@ -0,0 +1,20 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
#
|
||||||
|
# This script adds the status bar on top of all the images
|
||||||
|
# It is required as flutter driver screenshot does not include the status bar
|
||||||
|
#
|
||||||
|
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
||||||
|
cd "$SCRIPT_DIR/.."
|
||||||
|
|
||||||
|
DIR_NAME='./screenshots'
|
||||||
|
cd $DIR_NAME
|
||||||
|
|
||||||
|
for i in *.png; do
|
||||||
|
FILE_NAME=$(basename "${i}" .png)_final.jpg
|
||||||
|
echo "Converting $i -> $FILE_NAME"
|
||||||
|
|
||||||
|
convert "${i}" "$SCRIPT_DIR/status_bar.png" -composite "${FILE_NAME}"
|
||||||
|
done
|
BIN
scripts/status_bar.png
Normal file
BIN
scripts/status_bar.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 8.1 KiB |
Reference in New Issue
Block a user