gio
TLDR
Open a file with the default application
SYNOPSIS
gio command [arguments]
DESCRIPTION
gio is the GIO command-line tool for file operations in GNOME-based systems. It provides a unified interface for both local files and virtual filesystems (GVfs), including network locations, trash, and removable media.
Unlike standard Unix commands, gio integrates with GNOME's infrastructure, respecting desktop settings for default applications, trash behavior, and virtual filesystem mounts. It can access locations like smb://, sftp://, mtp://, and trash://.
The tool replaces older utilities like gvfs-open, gvfs-copy, and gvfs-trash.
PARAMETERS
open FILE
Open file with default applicationlist DIR
List contents of directoryinfo FILE
Display information about a filecopy SRC DEST
Copy filesmove SRC DEST
Move filestrash FILE
Move file to trashremove FILE
Delete file permanentlycat FILE
Display file contentslaunch DESKTOP
Launch application from .desktop filemime FILE
Get or set MIME type handlermount LOCATION
Mount a location
CAVEATS
Requires GLib and GVfs to be properly installed. Some virtual filesystem operations require the gvfsd daemon running. Performance may be slower than native commands for local file operations.
HISTORY
gio was introduced in GLib 2.50 (2016) as a unified command-line interface for GIO operations, consolidating various gvfs-* utilities into a single tool with subcommands. It's part of the GNOME platform's modern approach to file handling.


