Forum Archive

Get file contents of several Dropbox files

oldmankit

Hello,

Could anyone recommend a way to get the file contents of several files in Dropbox, without having to name each file individually?

I tried 'get file contents' with "*.md" as the file name (in Dropbox) but it didn't work.

Thank you!

peterh86

You need a python script. Check out python functions os.walk, or (better to grab your .md files) glob.glob. You then need a loop to read the files that these functions return.

This workflow:

http://editorial-app.appspot.com/workflow/6453713958862848/81eiZlBdpKA (in the last action)

uses glob.glob to find all .md files in a Dropbox folder, then has a loop to read them and join them together. You could use it as an example and modify it.

oldmankit

Thank you so much. That's just what I needed to get started.