Hi people, im developing an s3 adapter (compatible with 2.x) and im not have a clear explanations about methods with need be implemented, epecificly the read and delete methods.
how ghost uses these methods ?
no have any description and i m not know about delete images in ghost (delete, not only remove from mobiledoc)
I couldn’t find documentation either, but it may help to look at the source code of other Ghost adapters to figure out what they’re doing.
For example, looking at the WebDAV adapter, it seems the delete function must:
delete the file with the given path
return true if deleting was successful and false otherwise
Similarly, read seems to get the (binary) contents of a file and return it, though you should probably double-check that since I’m not very experienced in that area.
Perhaps you could also check out this s3 adapter and see if it works, either for direct use, or to better understand how adapters function.
Hi @luizamboni, I didn’t mean for you to use the Ghost adapter, but use it as an example. But if it’s for v1.0 I guess it’s not much help.
Good to hear you’re writing a fresh adapter for v2.x. Maybe you can see the official local-file-store adapter for some clues, but it’s quite limited.
I agree, it would be nice to have more documentation on how they work/when they’re used!