Skip to content

Instantly share code, notes, and snippets.

@gumblex
Created May 15, 2016 08:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gumblex/977ff9257754336d98307463ab98dbdb to your computer and use it in GitHub Desktop.
Save gumblex/977ff9257754336d98307463ab98dbdb to your computer and use it in GitHub Desktop.
Re-zip hacg's encrypted rars
#!/bin/bash
cd "$1"
find . -name "*.rar" -type f -print0 | while IFS= read -r -d $'\0' filename; do
basefn=$(basename "$filename")
basefncut="${basefn%.*}"
unar -p 扶她奶茶 -o /tmp -d "$filename"
7za a -tzip -mx=9 "${filename%.*}".zip /tmp/"$basefncut"/*
rm -rf /tmp/"$basefncut"/
done
@Artoria2e5
Copy link

要是有判定灰度图换成单通道 JPEG 的就好了(逃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment