details
🔗NAME
details
🔗SYNOPSIS
common darktable lua file functions
🔗USAGE
local df = require "lib/dtutils.file"
🔗DESCRIPTION
The dtutils.file library provides common file manipulation functions used in constructing darktable lua scripts
🔗RETURN VALUE
df - library - the file functions
🔗FUNCTIONS
-
check_if_bin_exists - check if an executable exists
-
check_if_file_exists - check if a file or path exist
-
chop_filetype - remove a filetype from a filename
-
create_unique_filename - create a unique filename from the supplied argment
-
executable_path_widget - create a widget to get executable path preferences
-
file_copy - copy a file to another name/location
-
file_move - move a file from one directory to another
-
filename_increment - add a two digit increment to a filename
-
get_basename - get the filename without the path or extension
-
get_executable_path_preference - return the path to an executable from a preference
-
get_filename - get the filename and extension from a file path
-
get_filetype - get the filetype from a filename
-
get_path - get the path from a file path
-
mkdir - create the directory(ies) if they do not already exists
-
rmdir - recursively remove a directory
-
sanitize_filename - make a filename safe to pass as an argument
-
set_executable_path_preference - set a preference for the path to an executable
-
split_filepath - split a filepath into parts
🔗LICENSE
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.