Created
August 9, 2019 15:36
-
-
Save stefanoschrs/1ae0ab8f4b889662f7fc5ea74c6ce283 to your computer and use it in GitHub Desktop.
deviceframe iPhone X hack
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
outputDir=/tmp/screenshots/framed | |
mkdir -p ${outputDir} | |
########## | |
# iPhone # | |
########## | |
padPath=/tmp/iphone-pad.png | |
convert -size 1125x185 xc:#e65562 ${padPath} | |
for filePath in $(find /tmp/screenshots/ | grep iPhone | grep -v framed) ; do | |
outputPath=/tmp/iphone-screenshot.png | |
convert ${padPath} ${filePath} -append ${outputPath} | |
npx dframe ${outputPath} --frame "Apple iPhone X" --output ${outputDir} | |
mv ${outputDir}/iphone-screenshot* ${filePath/screenshots/screenshots\/framed} | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment