Steps to create website with blogdown and the Hugo Academic (Wowchemy) theme

Photo by Daniel von Appen on Unsplash

These are the steps that I took to set up my website using blogdown and the Hugo Academic (Wochemy) theme. I also did a little “how to” session with some GW political science graduate students where we worked through these steps and got everyone started with a blogdown site. Many of the steps recounted here are based on what I learned from this super-helpful post by Alison Hill.

  1. Open a GitHub account and set up a personal access token (PAT) in R using usethis::create_github_token(). Consult Happy Git and Git Hub for the UseR for more details.

  2. Create a Github repository. Initialize the repository with a README but don’t worry about adding .gitignore or a license.

  3. Go to your new repository and click on the green button that says Code. Choose HTTPS (the default) and click on the clipboard to copy the link.

  4. Open RStudio. Navigate to File > New Project > Version Control > Git and paste the URL from step 3 into the Repository URL: field. Browse to a location where you want to store the project and click Create Project.

  5. Install blogdown (install.packages("blogdown")).

  6. Create the site:

new_site(theme = "wowchemy/starter-academic"
  1. Select y to let blogdown star the server and get a local preview. In the future, you can use blogdown::stop_server to stop the server and blogdown::serve_site to restart it.

  2. Create content.

  3. Check content using blogdown::check_content() and fix any issues.

  4. Commit changes with usethis::use_git() and push them to GitHub using the little green arrow in RStudio’s Git window.

  5. Publish the site to Netlify. Sign up using your GitHub account, then log in and select New site from Git > Continuous Deployment: GitHub. Select the repository with your site and deploy it!

Associate Professor of Political Science and International Affairs

My research interests include development, the political economy of labor and the politics of South Asia.