11#include "zrythm-config.h"
38 1) bool io_mkdir (const
char * dir, GError ** error);
53io_path_get_parent_dir (const
char * path);
67#define io_path_get_basename(filename) g_path_get_basename (filename)
78io_file_get_creation_datetime (
const char * filename);
88io_file_get_last_modified_datetime_as_str (
const char * filename);
107io_get_files_in_dir_as_basenames (
119#define io_get_files_in_dir(dir, allow_empty) \
120 io_get_files_in_dir_ending_in (dir, 0, NULL, allow_empty)
137 const char * end_string,
150WARN_UNUSED_RESULT
bool
152 const char * destdir_str,
153 const char * srcdir_str,
154 bool follow_symlinks,
183#define io_write_file g_file_set_contents
187io_get_registry_string_val (
const char * path);
190#if defined(__APPLE__) && defined(INSTALLER_VER)
197io_get_bundle_path (
char * bundle_path);
NONNULL char * io_path_get_basename_without_ext(const char *filename)
Strips path from given filename.
NONNULL char * io_traverse_path(const char *abs_path)
Returns the new path after traversing any symlinks (using readlink()).
NONNULL char * io_get_next_available_filepath(const char *filepath)
Returns a newly allocated path that is either a copy of the original path if the path does not exist,...
WARN_UNUSED_RESULT bool io_copy_dir(const char *destdir_str, const char *srcdir_str, bool follow_symlinks, bool recursive, GError **error)
Copies a directory.
NONNULL char * io_get_dir(const char *filename)
Gets directory part of filename.
NONNULL void io_open_directory(const char *path)
Opens the given directory using the default program.
NONNULL const char * io_file_get_ext(const char *file)
Returns file extension or NULL.
WARN_UNUSED_RESULT NONNULL_ARGS(1) bool io_mkdir(const char *dir
Makes directory if doesn't exist.
void io_touch_file(const char *filename)
Touches a file similar to UNIX touch.
char ** io_get_files_in_dir_ending_in(const char *_dir, const int recursive, const char *end_string, bool allow_empty)
Returns a list of the files in the given directory.
NONNULL gint64 io_file_get_last_modified_datetime(const char *filename)
Returns the number of seconds since the epoch, or -1 if failed.
NONNULL void io_escape_dir_name(char *dest, const char *dir)
Returns a clone of the given string after removing forbidden characters.
NONNULL int io_remove(const char *path)
Removes the given file.
NONNULL FILE * io_create_file(const char *filename)
Creates the file if doesn't exist.
NONNULL char * io_file_strip_ext(const char *filename)
Strips extensions from given filename.
NONNULL int io_rmdir(const char *path, bool force)
Removes a dir, optionally forcing deletion.