Skip to content

Instantly share code, notes, and snippets.

@27Cobalter
Last active October 31, 2018 17:12
Show Gist options
  • Save 27Cobalter/d2760a0ab04e284ab1349f68099a2043 to your computer and use it in GitHub Desktop.
Save 27Cobalter/d2760a0ab04e284ab1349f68099a2043 to your computer and use it in GitHub Desktop.
Steam側でスクショした名前形式をVRCCamera側の名前形式に変換するクソスクリプト
#!/bin/bash
# ディレクトリ構造
# |-Steam2VRC.sh
# |-VRChat_steam //src
# |-VRChat_camera //dst
for pic in `ls VRChat_steam/ | grep -v vr | grep jpg`;do
new_pic=`echo $pic | awk '{print("VRChat_camera/VRChat_1920x1080_"substr($0,1,4)"-"substr($0,5,2)"-"substr($0,7,2)"_"substr($0,9,2)"-"substr($0,11,2)"-"substr($0,13,2)".000.jpg")}'`
if [ -e $new_pic ];then
echo "skip $new_pic"
else
echo "copy VRChat_steam/$pic to $new_pic"
cp VRChat_steam/$pic $new_pic
fi
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment