tutorials
tutorials copied to clipboard
How to deal with downloads...
Previously, we used downgit for handling downloads of the folders in the repo. Sometimes downGit experienced issues and was unavailable, meaning users couldn't download files.
In response to this, I made zip folders in each folder repo and pointed the download link directly at these folders. This works for smaller tutorials, but for larger ones, we can't store the zip on GitHub because it's too big.
@bethac07 suggested zipping and releasing the tutorials folders so they appear under 'Releases' where there isn't a size limit. Those archives could be linked to the download buttons on the website BUT the issue is that when the files are re-zipped, a version no. changes in the URL, meaning it's not possible to use a static link for these. I do not currently know of a way to automatically update the links in the README file. Maybe an action that does a find/replace for the version # in the readme (if that's possible?).
Another possibility is hosting the largest tutorials on google where there isn't a limit for the zip folder size and then linking directly to these for users to download.
Any thoughts on these options?
Here's a find/replace GitHub action https://github.com/marketplace/actions/find-and-replace
Here's an example download link from Releases of CellProfiler:
'https://github.com/CellProfiler/CellProfiler/releases/download/v4.2.4/CellProfiler-macOS-4.2.4.zip'
We could use regex to match the "v4.2.4" part of the string and update it. The trick would be 1) how will the action know the current release version? and 2) Can we use an action to automatically deploy new releases when commits happen (ideally, only when that subfolder changes... not all commits)? Related: is the version # just incremented automatically?
Notes from meeting with Beth earlier:
- Tags are snapshot in time, associated with a specific commit.
- Branches are departures from main code
- We hope is to merge branch back in
- Beth posted a get-tag GitHub action
uses: to source a github action
$tag is already an environment variable
Run this and set this to new tag. Identify place to replace with regex?
OR have a Source copy of README that gets edited and push these changes to a GitHub action to
- May have to manually supply the previous version
- Can version with date (doesn’t have to be major-minor-prerelease)
Goals for now:
- Create GH action to zip and release folders
- Change the README download links to refer to the release archive for each tutorial folder.
- use regex to identify where the version string is in the archive download link in the README and automatically modify this every time a new release is pushed, thus updating the download links