Signed-off-by: shenmo <jifengshenmo@outlook.com>
This commit is contained in:
2025-11-19 15:54:21 +00:00
committed by Gitee
parent a2378626c5
commit cb0112c1c2
3 changed files with 23 additions and 19 deletions

2
debian/changelog vendored
View File

@@ -1,4 +1,4 @@
amber-ce-bookworm (12.8.5) UNRELEASED; urgency=low amber-ce-bookworm (12.9.1) UNRELEASED; urgency=low
* 通用 ACE 构建,现不再需要单独使用构建脚本 * 通用 ACE 构建,现不再需要单独使用构建脚本
* 更方便地更改成其他ACE * 更方便地更改成其他ACE
* 现可在容器内使用 dpkg-buildpackage * 现可在容器内使用 dpkg-buildpackage

View File

@@ -24,17 +24,19 @@ uid=$(id -u $non_root_user)
#### This part is for args pharm #### This part is for args pharm
if [ "$1" = "" ];then if [ $# -eq 0 ]; then
container_command="bash" container_command="bash"
else else
container_command="$1" # 正确转义所有参数,处理空格和特殊字符
shift container_command=""
for arg in "$@"; do for arg in "$@"; do
arg="$(echo "${arg}x" | sed 's|'\''|'\'\\\\\'\''|g')" # 使用 printf %q 进行安全的 shell 转义
arg="${arg%x}" escaped_arg="$(printf "%q" "$arg")"
container_command="${container_command} '${arg}'" container_command="${container_command} ${escaped_arg}"
done done
container_command="${container_command# }" # 移除开头的空格
fi fi
######################################################################################### #########################################################################################
##########合成bwrap 1. 基础函数配置段 ##########合成bwrap 1. 基础函数配置段
# 初始化 EXEC_COMMAND 为 bwrap 基础指令 # 初始化 EXEC_COMMAND 为 bwrap 基础指令

View File

@@ -24,17 +24,19 @@ uid=$(id -u $non_root_user)
#### This part is for args pharm #### This part is for args pharm
if [ "$1" = "" ];then if [ $# -eq 0 ]; then
container_command="bash" container_command="bash"
else else
container_command="$1" # 正确转义所有参数,处理空格和特殊字符
shift container_command=""
for arg in "$@"; do for arg in "$@"; do
arg="$(echo "${arg}x" | sed 's|'\''|'\'\\\\\'\''|g')" # 使用 printf %q 进行安全的 shell 转义
arg="${arg%x}" escaped_arg="$(printf "%q" "$arg")"
container_command="${container_command} '${arg}'" container_command="${container_command} ${escaped_arg}"
done done
container_command="${container_command# }" # 移除开头的空格
fi fi
######################################################################################### #########################################################################################
##########合成bwrap 1. 基础函数配置段 ##########合成bwrap 1. 基础函数配置段
# 初始化 EXEC_COMMAND 为 bwrap 基础指令 # 初始化 EXEC_COMMAND 为 bwrap 基础指令