cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
jonahkeegan
New Member

Download a single github resource ("folder")

I need to download the files contained in a single public resource folder on github:

 

https://github.com/CSSEGISandData/COVID-19/tree/master/csse_covid_19_data/csse_covid_19_daily_report...

 

I need a simple 'Recurrence' trigger, one download per day.

 

I can use HTTP GET to execute the download ZIP url, however, that file is too large to automatically extract with Power Automate, and we need to move the uncompressed files into our Sharepoint.

 

I believe there's a method via subversion:

 

https://stackoverflow.com/questions/7106012/download-a-single-folder-or-directory-from-a-github-repo

 

But I don't think PA supports subversion code / requests.

 

Does anyone have a solution for this flow?

1 REPLY 1
JohnAageAnderse
Super User
Super User

Hello @jonahkeegan 

Instead of thinking about getting a folder, why don't you just take the files, one after each other? The files all has a name pattern that can easily be calculated.

Create your recurrent flow that runs daily.

Have a sharepoint list with just one entry, the date last processed, starting with '01-22-2020' (MM-dd-yyyy), which is the name of the first CSV file.

1) Your flow grabs that date.

2) Then calculates the URL to use and GETs the file (you may have to catch the situation when there is no file for the date).

3) The file is then stored in your sharepoint, a document library.

4) Your flow then calculates the next date to use and stores it in the sharepoint list.

5) Your flow then loops till the date reaches todays date.

6) Your flow ends

 

When your flow next time runs, it will start from the stored date 🙂

Hope this gives you an idea. Kind regards, John

Helpful resources

Announcements
MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS Carousel

Sign up for our May 4th event!

May the fourth be with you, join us online!

MSFTBizAppsLaunchEvent

Experience what’s next for Power Virtual Agents

See the latest Power Automate innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (60,281)