Roman Mahotskyi
Roman Mahotskyi

Reputation: 6655

How to make a download link in GitHub README.md file?

I uploaded a .epub file to the GitHub repository. I want to create a download link to this file inside the README.md file.

By clicking this link user will be able to download the file directly, without going to another page and clicking the download button on that page.

Is it possible to achieve this with the default README.md (markdown) file?

Upvotes: 2

Views: 5058

Answers (2)

Roman Mahotskyi
Roman Mahotskyi

Reputation: 6655

I was able to achieve the download link by putting my .epub file inside a release assets.

After creating a release I right-clicked on the artifact and copied the link address.

The markdown snippet looks like this

[epub](https://github.com/name/project/releases/download/v1.0.0/book.epub)

It immediately starts loading the file upon clicking the epub word.

Upvotes: 2

Schecher_1
Schecher_1

Reputation: 560

In text comes e.g. "click me" and at link just your downloadlink

You can do it with this:

[text](link)

as an example:

[click me to download](https://github.com/Schecher1/Minecraft-Server-Creator/blob/master/README.md)

Upvotes: 3

Related Questions