mirror of
https://gitee.com/spark-store-project/spark-wine
synced 2025-12-18 21:11:39 +08:00
Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 93f096bca5 | |||
| 43e11b2e7f | |||
| 39be413b97 | |||
| 63b63d7cfa | |||
| ec73153de1 | |||
| 6ad27cca3f | |||
| ad9535b5a0 |
@@ -1,5 +1,5 @@
|
||||
Package: spark-dwine-helper
|
||||
Version: 1.5.1
|
||||
Version: 1.6
|
||||
Architecture: all
|
||||
Maintainer: shenmo <shenmo@spark-app.store>
|
||||
Installed-Size: 2293
|
||||
@@ -7,5 +7,5 @@ Depends: zenity:amd64, p7zip-full:amd64, fonts-noto-cjk,deepin-wine-helper(>=5.1
|
||||
Section: utils
|
||||
Priority: extra
|
||||
Multi-Arch: foreign
|
||||
Homepage: https://www.spark-app.store/
|
||||
Homepage: https://gitee.com/deepin-community-store/spark-wine
|
||||
Description: Spark Deepin Wine Helper
|
||||
|
||||
@@ -8,8 +8,6 @@
|
||||
#
|
||||
# Modifier: shenmo <shenmo@spark-app.store>
|
||||
#
|
||||
# diff: Now will run set-dwine-scale.sh in stage CallProcess before CallApp
|
||||
# Deleted Deepin-* to simplify the script
|
||||
#
|
||||
WINEPREFIX="$HOME/.deepinwine/@public_bottle_name@"
|
||||
APPDIR="/opt/deepinwine/apps/@public_bottle_name@"
|
||||
@@ -35,32 +33,7 @@ if [ $SPECIFY_SHELL_DIR ]; then
|
||||
SHELL_DIR=$SPECIFY_SHELL_DIR
|
||||
fi
|
||||
|
||||
UsePublicDir()
|
||||
{
|
||||
if [ -z "$USE_PUBLIC_DIR" ]; then
|
||||
echo "Don't use public dir"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -d "$PUBLIC_DIR" ];then
|
||||
echo "Not found $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -r "$PUBLIC_DIR" ];then
|
||||
echo "Can't read for $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -w "$PUBLIC_DIR" ];then
|
||||
echo "Can't write for $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -x "$PUBLIC_DIR" ];then
|
||||
echo "Can't excute for $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
|
||||
return 0
|
||||
}
|
||||
########关于公共文件夹,暂时意义不明
|
||||
|
||||
_DeleteRegistry()
|
||||
{
|
||||
@@ -172,7 +145,7 @@ CallProcess()
|
||||
|
||||
debug_log_to_file "Starting process $* ..."
|
||||
############# WARNING: Here is the modified content: Now will run set-dwine-scale.sh
|
||||
/opt/durapps/spark-dwine-helper/set-dwine-scale.sh "$WINEPREFIX"
|
||||
/opt/durapps/spark-dwine-helper/scale-set-helper/set-wine-scale.sh "$WINEPREFIX"
|
||||
env WINEPREFIX="$WINEPREFIX" $WINE_CMD "$@" &
|
||||
|
||||
#start autobottle
|
||||
@@ -500,10 +473,6 @@ DeployApp()
|
||||
{
|
||||
ExtractApp "$WINEPREFIX"
|
||||
|
||||
if UsePublicDir;then
|
||||
chgrp -R users "$WINEPREFIX"
|
||||
chmod -R 0775 "$WINEPREFIX"
|
||||
fi
|
||||
|
||||
echo "$APPVER" > "$WINEPREFIX/PACKAGE_VERSION"
|
||||
|
||||
@@ -542,10 +511,6 @@ UpdateApp()
|
||||
ExtractApp "${WINEPREFIX}.tmpdir"
|
||||
$SHELL_DIR/updater -s "${WINEPREFIX}.tmpdir" -c "${WINEPREFIX}" -v
|
||||
|
||||
if UsePublicDir;then
|
||||
chgrp -R users "$WINEPREFIX"
|
||||
chmod -R 0775 "$WINEPREFIX"
|
||||
fi
|
||||
|
||||
rm -rf "${WINEPREFIX}.tmpdir"
|
||||
echo "$APPVER" > "$WINEPREFIX/PACKAGE_VERSION"
|
||||
@@ -614,9 +579,6 @@ fi
|
||||
BOTTLENAME="$1"
|
||||
WINEPREFIX="$HOME/.deepinwine/$1"
|
||||
|
||||
if UsePublicDir;then
|
||||
WINEPREFIX="$PUBLIC_DIR/$1"
|
||||
fi
|
||||
|
||||
APPDIR="/opt/apps/${DEB_PACKAGE_NAME}/files"
|
||||
if [ -f "$APPDIR/files.md5sum" ];then
|
||||
|
||||
@@ -25,9 +25,10 @@ mkdir -p $HOME/.config/spark-wine/
|
||||
#####能到这一步的说明已经是没有自定义参数了,直接读全局覆盖没问题
|
||||
#####
|
||||
|
||||
if [ !-f "$HOME/.config/spark-wine/scale.txt" ];then
|
||||
if [ -f "$HOME/.config/spark-wine/scale.txt" ];then
|
||||
cat $HOME/.config/spark-wine/scale.txt > $CONTAINER_PATH/scale.txt
|
||||
echo "检测到已经设置过全局参数,直接复制"
|
||||
echo "全局参数的位置在$HOME/.config/spark-wine/scale.txt,如果需要更换请删除此文件重新生成"
|
||||
exit
|
||||
fi
|
||||
|
||||
@@ -57,9 +57,9 @@ if [ ! -f "$CONTAINER_PATH/scale.txt" ];then
|
||||
echo "E: No SCALE profile found. try to use DEEPIN_WINE_SCALE"
|
||||
echo "错误:没有检测到缩放设置,读取DEEPIN_WINE_SCALE"
|
||||
if [ "$DEEPIN_WINE_SCALE" = "" ];then
|
||||
echo "E: No DEEPIN_WINE_SCALE found. Use spark-get-scale to Set "
|
||||
echo "错误:没有检测到DEEPIN_WINE_SCALE,用spark-get-scale设置"
|
||||
/opt/durapps/spark-dwine-helper/spark-get-scale.sh "$CONTAINER_PATH"
|
||||
echo "E: No DEEPIN_WINE_SCALE found. Use get-scale.sh to Set "
|
||||
echo "错误:没有检测到DEEPIN_WINE_SCALE,用get-scale.sh设置"
|
||||
/opt/durapps/spark-dwine-helper/scale-set-helper/get-scale.sh "$CONTAINER_PATH"
|
||||
wine_scale=`cat $CONTAINER_PATH/scale.txt`
|
||||
echo "检测到的缩放倍数为:$wine_scale"
|
||||
echo "Scale is $wine_scale"
|
||||
@@ -176,4 +176,4 @@ echo "env WINEPREFIX="$CONTAINER_PATH" $APPRUN_CMD reg ADD 'HKCU\Control Panel\D
|
||||
|
||||
env WINEPREFIX="$CONTAINER_PATH" $APPRUN_CMD reg ADD 'HKCU\Control Panel\Desktop' /v LogPixels /t REG_DWORD /d $dpi /f
|
||||
|
||||
fi
|
||||
fi
|
||||
@@ -8,8 +8,7 @@
|
||||
#
|
||||
# Modifier: shenmo <shenmo@spark-app.store>
|
||||
#
|
||||
# diff: Now will run set-dwine-scale.sh in stage RunApp before CallApp
|
||||
# Deleted Deepin-* to simplify the script
|
||||
|
||||
#
|
||||
#
|
||||
#
|
||||
@@ -48,32 +47,7 @@ if [ $SPECIFY_SHELL_DIR ]; then
|
||||
SHELL_DIR=$SPECIFY_SHELL_DIR
|
||||
fi
|
||||
|
||||
UsePublicDir()
|
||||
{
|
||||
if [ -z "$USE_PUBLIC_DIR" ]; then
|
||||
echo "Don't use public dir"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -d "$PUBLIC_DIR" ];then
|
||||
echo "Not found $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -r "$PUBLIC_DIR" ];then
|
||||
echo "Can't read for $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -w "$PUBLIC_DIR" ];then
|
||||
echo "Can't write for $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
if [ ! -x "$PUBLIC_DIR" ];then
|
||||
echo "Can't excute for $PUBLIC_DIR"
|
||||
return 1
|
||||
fi
|
||||
|
||||
return 0
|
||||
}
|
||||
########关于公共文件夹,暂时意义不明
|
||||
|
||||
_DeleteRegistry()
|
||||
{
|
||||
@@ -238,10 +212,7 @@ DeployApp()
|
||||
{
|
||||
ExtractApp "$WINEPREFIX"
|
||||
|
||||
if UsePublicDir;then
|
||||
chgrp -R users "$WINEPREFIX"
|
||||
chmod -R 0775 "$WINEPREFIX"
|
||||
fi
|
||||
|
||||
|
||||
echo "$APPVER" > "$WINEPREFIX/PACKAGE_VERSION"
|
||||
|
||||
@@ -280,10 +251,7 @@ UpdateApp()
|
||||
ExtractApp "${WINEPREFIX}.tmpdir"
|
||||
$SHELL_DIR/updater -s "${WINEPREFIX}.tmpdir" -c "${WINEPREFIX}" -v
|
||||
|
||||
if UsePublicDir;then
|
||||
chgrp -R users "$WINEPREFIX"
|
||||
chmod -R 0775 "$WINEPREFIX"
|
||||
fi
|
||||
|
||||
|
||||
rm -rf "${WINEPREFIX}.tmpdir"
|
||||
echo "$APPVER" > "$WINEPREFIX/PACKAGE_VERSION"
|
||||
@@ -301,8 +269,8 @@ RunApp()
|
||||
else
|
||||
DeployApp | progressbar $BOTTLENAME "初始化$BOTTLENAME中..."
|
||||
fi
|
||||
############# WARNING: Here is the modified content: Now will run set-dwine-scale.sh
|
||||
/opt/durapps/spark-dwine-helper/set-dwine-scale.sh "$WINEPREFIX"
|
||||
############# WARNING: Here is the modified content: Now will run set-wine-scale.sh
|
||||
/opt/durapps/spark-dwine-helper/scale-set-helper/set-wine-scale.sh "$WINEPREFIX" "$WINEPREFIX"
|
||||
|
||||
CallApp "$@"
|
||||
}
|
||||
@@ -354,9 +322,7 @@ fi
|
||||
BOTTLENAME="$1"
|
||||
WINEPREFIX="$HOME/.deepinwine/$1"
|
||||
|
||||
if UsePublicDir;then
|
||||
WINEPREFIX="$PUBLIC_DIR/$1"
|
||||
fi
|
||||
|
||||
|
||||
APPDIR="/opt/apps/${DEB_PACKAGE_NAME}/files"
|
||||
if [ -f "$APPDIR/files.md5sum" ];then
|
||||
|
||||
Reference in New Issue
Block a user