APT
跳至導覽
跳至搜尋
APT是一套套件管理系統,源自Debian。
工具
把Legacy Format轉成DEB822格式,這邊要注意只支援GNU Awk:
gawk '{if ($1 ~ /^deb/) {printf("Enabled: yes\nTypes: %s\nURIs: %s\nSuites: %s\nComponents: %s\n%s", $1, $(NF-2), $(NF-1), $NF, signedby); if (match($0, /arch=([^ \]]*)/, a)) printf("Architectures: %s\n", a[1]); if (match($0, /signed-by=([^ \]]*)/, a)) printf("Signed-by: %s\n", a[1])}}'
範例
將HTTP與HTTPS都使用HTTPS Proxy:
sudo env http_proxy=https://user:pass@proxy-tls.example.com:4128/ https_proxy=https://user:pass@proxy-tls.example.com:4128/ apt update
相關連結
外部連結
- 官方網站 (英文)