GLib.file_read_link
function file_read_link(filename: String): String { // Gjs wrapper for g_file_read_link() }
Reads the contents of the symbolic link filename like the POSIX readlink() function. The returned string is in the encoding used for filenames. Use GLib.filename_to_utf8 to convert it to UTF-8.
Since 2.4
- filename
the symbolic link
- Returns
A newly-allocated string with the contents of the symbolic link, or null if an error occurred.