Making a personal (academic) website using Blogdown

Here, I used instructions from 2 different sources, 1) the blogdown website and 2) the documentation for the Hugo Academic theme. First install the Blogdown package in R:

library(blogdown)

Navigate to the directory where your website files will reside on your computer,

setwd("/path/to/parent/folder")

then run the following:

blogdown::install_hugo(version = "0.69.2", force = TRUE) # the specific version is important, Academic doesn't work with the latest Hugo version
blogdown::new_site(install_hugo = FALSE, theme = 'gcushen/hugo-academic')

Now edit the contents of the file content/authors/admin/_index.md

Start a new repository for your website on GitHub.

Install git on your computer.

git init
git add *.*
git commit -m 'new website'
git remote add origin https://github.com/username/blogdown_website.git
git push -u origin master

Install miniconda3 and create a new conda environment

conda create -n personal_website
conda activate personal_website
conda install -c conda-forge academic

Publications

Navigate to the website root folder

cd /path/to/parent/folder/mywebsite

and use the academic conda package to convert the .bib file into markdown documents

academic import --bibtex ~/Downloads/My\ publications.bib

Deployment

Open a new account, if you don’t have one already, on Netlify. Click on Sites > New site from Git, choose GitHub under Continuous Deployment and give permissions as needed. Then click on Sites > your site > Settings > General > Change site name, to change the site address.

That’s it, now everytime you push a new commit to GitHub, the site is automatically deployed to Netlify!

Srinivasa Rao
Srinivasa Rao
Postdoctoral research associate

My research interests include prostate cancer, cancer genomics and tumour evolution.

Related