Documents Branch
Using GitHub as a File Host for hotlinking all sorts of files on the web
Using a separate branch for different media types. Each branch is named with the first letter of that media type.
docs|Default Branch|-txt,md,pdf,doc, etc...images -svg,png,jpg,gif, etc...audio -mp3,m4a,aiff, etc...video -x264,x265,mp4, etc...
Steps to embed an image named jimi.png on a website:
- Open the Repository either in the GitHub client or on the GitHub website.
- Switch to the appropriate branch for the file type you're adding. Since we're adding an image we'll use the
i(images) branch - Add the image to the repo then commit and push it.
- Go to the repo on GitHub & switch to the
ibranch - Click the name of the image & copy the image link
- On the target page, insert the link the appropriate way and save the file
The Full link is:
https://raw.githubusercontent.com/8rents/_/i/jimi.pngWhich is easy to remember!
https://raw.githubusercontent.com/[username/repo/branch/filename]All you have to do is memorize: https://raw.githubusercontent.com/
After that add: Your user name/repository name/branch/ folder path (blank if on root)/file name
So the complete URL for the uploaded image would be:
https://raw.githubusercontent.com/8rents/_/i/jimi.png<img src="https://raw.githubusercontent.com/8rents/_/i/jimi.png" alt="Jimi">You can make a snippet or memorize the URL of the repo:
- In the client, switch to the proper branch
- Add, commit & push the file
- Paste the first part of the URL and edit the branch, folder path if there is one & then the image name
- File names must consist of lowercase letters, numbers & hyphens only
- Appropriate branch for the type of media must be used
- Use only open formats whenever possible avoid proprietary formats like Google's webm. Note the exception to these rules is for editing mode formats like PSD (Photoshop) or ALS (Ableton Live)
File types can be in whatever type I need to share. I tend to prefer:
- Open Formats
- Easy to mutate
Here is a brief list of my order of preference of file formats:
- Markdown (Good)
- Microsoft Word
- PDF (Not Good)
Prefer image formats in the following order:
- PNG
- JPG
- SVG
- GIF
- MP3
- AAC
- FLAC
- AIFF or WAV (for stems)
- H264
- H265
(<3) 2025 Brenton Holiday
