Hey 👋 new reader,
Pluralsight gave me some free1 month
, get them before
subscriptions
they are gone!
How to Host unlimited Side Projects for free
26 Feb 2017 · 2 mins read Edit PostI host all my side projects on GitHub, which totals to 5.6 Million lines of open-source code!
GitHub pages makes it easy to get a new side project up and running within minutes. Follow these simple steps.
- Create repo & activate GitHub Pages
- (optional) Clone a boilerplate repo
- Start side project
1. Create Side project Repo and Activate GitHub Pages
When you create a repo, the name you choose will be the URL of the website, so choose something sensible.
Next activate GitHub pages, by going to the repo settings, scrolling down and clicking enable github pages.
Now you can navigate to a url and see the site, such as:
http://username.github.io/repo_name
2. Clone a boilerplate repo (optional)
Having a boilerplate as starter code makes setting up side projects even faster.
I create and manage a boilerplate using GruntJS to handle all dependencies and help with processing Sass.
The boilerplate uses Grunt to optimise the project. For example the below snippet minifies the index.html file to decrease load times.
Gruntfile.js
grunt.initConfig({
htmlmin: { // Minify HTML
dist: {
options: {
removeComments: true,
collapseWhitespace: true
},
files: {
'index.html': 'build.html' // 'destination': 'source'
}
}
},
});
grunt.loadNpmTasks('grunt-contrib-htmlmin'); // Minify HTML
grunt.registerTask('default', ['htmlmin']);
3. Start the side project
Now you can start making front end side project. But bare in mind GitHub static sites allows Jekyll, HTML, CSS and JS.
Some of my side projects
- Simple Tel Tracking - Add Google Analytics tracking code email and telephone numbers in Wordpress
- Harrys Habits - A chatbot to help you form new healthy habits
- Rate My Plate - A twitter bot to rate the environemental impact of your food
- This blog - All of these posts are hosted on GitHub pages and open source
Suggested
- Automatic Sleep Tracking — 18 May 2016
- Habit-Formation Methods — 01 April 2017