Useful Commands/Package Management: Difference between revisions
Jump to navigation
Jump to search
| Line 14: | Line 14: | ||
winget source update | winget source update | ||
</syntaxhighlight> | </syntaxhighlight> | ||
|} | |||
{| class="wikitable" style="text-align: center; width: 100%;" | |||
|+ '''Windows 系統套件管理分工架構''' | |||
|- style="background-color: #eaecf0;" | |||
! style="width: 50%;" | WinGet<br /><small>(負責所有 GUI 應用)</small> | |||
! style="width: 50%;" | Scoop<br /><small>(負責所有 CLI 與開發工具)</small> | |||
|- | |||
| style="vertical-align: top; text-align: left;" | | |||
* Chrome / Edge | |||
* VS Code / JetBrains | |||
* Docker / Git | |||
* Discord / Spotify | |||
| style="vertical-align: top; text-align: left;" | | |||
* PHP / Composer | |||
* Node.js / NVM / Bun | |||
* Python / Go / Rust | |||
* Neovim / kubectl / 7zip | |||
|} | |} | ||
Revision as of 02:12, 21 July 2026
Windows
| Purpose | RunAs | Command |
|---|---|---|
| Install PowerShell | Required |
winget install --id Microsoft.PowerShell --source winget --installer-type wix --override "CREATE_DESKTOP_SHORTCUT=1 ADD_EXPLORER_CONTEXT_MENU_OPENPOWERSHELL=1"
Don't install with default options. |
| Update package list |
winget source update
|
| WinGet (負責所有 GUI 應用) |
Scoop (負責所有 CLI 與開發工具) |
|---|---|
|
|
Ubuntu
| Purpose | Command |
|---|---|
| List how many top packages installed by me. |
apt-mark showmanual | grep -E 'top$'
|
| List files owned by package |
dpkg -L openvino-2026.2.1
|
| List all packages installed. |
dpkg --get-selections
|
| Show version info of a package not installed. |
sudo apt-cache show openssl
|
| Show version info of a package installed. |
dpkg -s openssl | grep '^Version'
|
OSX
| Purpose | Command |
|---|---|
| 安裝 Beta 版套件 |
$ brew info jython
jython: stable 2.5.3, devel 2.7-b1
...
$ brew install --devel jython
|
| 看看 brew install 的時候有哪些編譯選項可以用 |
brew info graphviz # 版本資訊 / 相依套件 / 編譯選項
brew options graphviz # 只有編譯選項
|
| 移除沒在用的套件 (已經有安裝新版本,但是舊版還在) 注意!! 這個指令可能導致自編譯套件找不到 lib |
brew cleanup
brew cleanup $FORMULA
brew cleanup -n # dry-run
|