tldr/pages.zh_TW/common/code.md

29 lines
566 B
Markdown
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

# code
> Visual Studio Code.
> 更多資訊:<https://github.com/microsoft/vscode>.
- 執行 VS Code
`code`
- 在 VS Code 開啟當前目錄:
`code .`
- 在 VS Code 開啟檔案或目錄:
`code {{檔案或目錄/完整/路徑}}`
- 在目前開啟的 VS Code 視窗中開啟一個檔案或目錄:
`code --reuse-window {{檔案或目錄/完整/路徑}}`
- 在 VS Code 中比較兩個檔案:
`code -d {{檔案一}} {{檔案二}}`
- 用超級使用者 (sudo) 權限執行 VS Code
`sudo code {{檔案或目錄/完整/路徑}} --user-data-dir`