在 Debian 系统中,你提到的 “extract 配置” 通常有两种可能含义,我分别说明如何“升级”或更新相关配置:
也就是 /etc/apt/sources.list 或 /etc/apt/sources.list.d/ 中的软件源配置。
# 编辑源
sudo sed -i 's/buster/bullseye/g' /etc/apt/sources.list
sudo sed -i 's/bullseye/bookworm/g' /etc/apt/sources.list
# 更新并升级
sudo apt update
sudo apt full-upgrade
sudo apt update
sudo apt upgrade
sudo apt install apt-listbugs apt-listchanges
sudo apt full-upgrade
sudo apt update
sudo apt install --only-upgrade \
bsdtar \
libarchive-tools \
unzip \
unrar \
p7zip-full
bsdtar --version
7z --help
file-roller --version
例如修改 bsdtar 默认解压路径:
alias extract='bsdtar -xvf'
写入:
echo "alias extract='bsdtar -xvf'" >> ~/.bashrc
source ~/.bashrc
如 /usr/local/bin/extract 或 ~/.extractrc
# 编辑配置
nano ~/.extractrc
# 或更新脚本
sudo cp extract.sh /usr/local/bin/extract
sudo chmod +x /usr/local/bin/extract
你可以告诉我:
cat /etc/os-release)我可以给你精确命令。