![export from darktable export from darktable](https://cdn.fstoppers.com/styles/full/s3/media/2021/02/25/darktable_export.jpg)
by a shortcut key press, but it would be much more limited. Another method would be to call an external program such as imagemagick from Lua after export, that resizes the image. darktable-cli is a command line variant to be used to export images given the raw file and the accompanying xmp file. On Conflict means that a file of the same name already exists in the folder, what do you want DT to do.
#Export from darktable code
this video of Harry Durgin explaining such a plugin which is available from the scripts github (it could serve as code example if you decide to go this route). Check that the option 'File on disk' has been chosen then next to (FILEFOLDER)/darktableexported/ (FILENAME) is a button to browse for a directory, use this to select the directory that you want the image to export to. One warning, the exported file is not saved and only passed to gimp, if you want to save it you have to do it within gimp. With this method, complex things are possible, see e.g. It works the other way around, you open a RAW file in GIMP and if it knows about darktable it will open the file and as soon as you close darktable the developed result is available in gimp. The first one would be to add a new storage backend which would be visible in the export module as a new target. While not everything within darktable is accessible via scripting, I can imagine several ways of solving this issue with Lua, but I am not a programmer and cannot solve this issue in a reasonable amount of time. The nice thing about it is that darktable has not to be recompiled to make use of new scripts, what would be needed if darktables code itself is touched. That way, it is possible to write “plugin” like extensions. It is possible to extend darktable due to its integrated Lua scripting language. I'd like to extend a bit on the other answer.