diff --git a/wechat-devtools/package.sh b/wechat-devtools/package.sh index 10889db..4b9306b 100755 --- a/wechat-devtools/package.sh +++ b/wechat-devtools/package.sh @@ -35,8 +35,7 @@ if [ "$1" == "" ]; then echo "下载官方原包..." - # wget $deb_url -O "${tmp_dir}/${app_name}.deb" - cp "$HOME/Downloads/io.github.msojocs.wechat-devtools-linux_${version}_amd64.deb" "${tmp_dir}/${app_name}.deb" + wget $deb_url -O "${tmp_dir}/${app_name}.deb" echo "下载完成, 解包中..." dpkg-deb -R "${tmp_dir}/${app_name}.deb" "${tmp_dir}/${app_name}" @@ -47,6 +46,10 @@ if [ "$1" == "" ]; then mv "${source_dir}/files/bin/package.nw" "./unpack/usr/lib/${app_name}" mv "${source_dir}/entries/icons" "./unpack/usr/share" + for i in ./unpack/usr/share/icons/hicolor/*/*/*; do + mv $i ${i/io.github.msojocs.wechat-devtools-linux/wechat-devtools} + done + rm -rf "./unpack/usr/lib/${app_name}/package.nw/node_modules/wcc/bin/mac" rm -rf "./unpack/usr/lib/${app_name}/package.nw/node_modules/wcc/bin/windows" @@ -87,6 +90,8 @@ MimeType=x-scheme-handler/wechatide elif [ "$1" == "pack" ]; then + echo '计算文件md5中...' + cd ./unpack find usr/ -type f | xargs -I {} md5sum {} > DEBIAN/md5sums