openHASP icon indicating copy to clipboard operation
openHASP copied to clipboard

File handling commands

Open FreeBear-nc opened this issue 9 months ago • 12 comments

As part of adding SD support, it occurred to me that it would be useful to have some basic file handling commands. e.g.: list - Returning a json object with file names & sizes on either SD card or internal storage (spiffs/littlefs) - Already implemented as a dir command and used by the file editor, but doesn't display file size. copy - Copy file to/from SD card and returns a json object of file name (including new path ?) and size move - As per copy, but deleting source file if copy is successful. delete - Already available within the file editor, but no callable from mqtt/telnet/terminal (unless I've missed something)

copy and move commands would only be of use for those using an SD card. list (or an enhanced dir) and copy have a wider appeal to other users.

FreeBear-nc avatar May 23 '24 11:05 FreeBear-nc