mirror of
https://github.com/ivuorinen/cheatsheet-tldr.git
synced 2026-01-26 11:33:59 +00:00
30 lines
565 B
Plaintext
30 lines
565 B
Plaintext
---
|
|
syntax: markdown
|
|
tags: [tldr, linux]
|
|
source: https://github.com/tldr-pages/tldr.git
|
|
---
|
|
# xdg-open
|
|
|
|
> Open a file or URL in the user's preferred application.
|
|
> More information: <https://portland.freedesktop.org/doc/xdg-open.html>.
|
|
|
|
- Open the current directory in the default file explorer:
|
|
|
|
`xdg-open .`
|
|
|
|
- Open a URL in the default browser:
|
|
|
|
`xdg-open {{https://example.com}}`
|
|
|
|
- Open an image in the default image viewer:
|
|
|
|
`xdg-open {{path/to/image}}`
|
|
|
|
- Open a PDF in the default PDF viewer:
|
|
|
|
`xdg-open {{path/to/pdf}}`
|
|
|
|
- Display help:
|
|
|
|
`xdg-open --help`
|