Open GIScience

Joseph Holler's Open GIScience Curriculum at Middlebury College

Research and Publish with GitHub

Feb-10 : In this lesson, we will learn fundamentals of Git version control and publish a website using Markdown, GitHub, and Jekyll.

Thanks to Yifei Luo for contributions to this lesson.

Goals and Expectations

Git

Git is a free and open source version control system for a repositories.

Git can be run from a command line shell or from a simple GUI (graphical user interface), or from a third-party program. In this course, we will primarily use GitHub’s website https://github.com and GitHub Desktop application.

GitHub

GitHub is one of many places you can host your Git repositories.

Let’s take a look at QGIS, which is hosted on GitHub.

Create a GitHub Account

Key Git and GitHub Actions

Hassle-free Git

Example GitHub Repository

Markdown

Markdown is an easy-to-learn and very efficient language for formatting writing. It can be used for writing webpages, blogs, books, computational notebooks, and even scientific articles. Markdown is the language for writing issues, wikis, and readme pages on GitHub.

You can use Markdown to author website content using software like Jekyll.

Create a GitHub Page

GitHub Pages is a service running on GitHub that can serve websites. It can also use Jekyll to build the websites for you.

Create your site

Project sites

Aside: If you want to build a project site:

Edit your site online

You can make simple revisions to your site on GitHub.com.

Edit your site locally

I suggest making more substantial revisions to your site on a local computer.


| First Column | Second Column | Last Column |
| :----------- | :-----------: | ----------: |
| left | centered | right |
| empty middle | | empty middle |

First Column Second Column Last Column
left centered right
empty middle   empty middle

Customize your site

Let’s see how to edit the site content to make it your own.

Create a new post

---
title: "Is GIS a Science?"
categories:
  - blog
tags:
  - science
  - GIS
---

Save images and other files in an assets folder

Jekyll looks to an assets folder for images and other content, so lets create one now.

GitHub Logo

Keeping work in sync between GitHub.com and local repositories

To see how GitHub works when you are editing with more than one version of a repository, lets return to github.com

First serious blog post

Please read two chapters of the NASEM report on reproducibility adn replicability.

Check out how geographers are doing based on recent survey data:

Based on your experience in geography and spatial data science and the readings and data above, do you think reproducibility and replicability (R&R) are important in geography? What do you think the greatest challenge to R&R is in geography, and do you see any opportunities to address it? Please post this blog before the next class.

Need inspriation? View Last Week Tonight with John Oliver (HBO): Scientific Studies

References

Workshops and learning resources

Readings on Git

Customizing Jekyll Sites

You can develop a more advanced Jekyll sites customized for portfolios, blogging, documentation, etc. by first forking or cloning a Jekyll template. Some of these work directly with GitHub pages (building the site remotely on GitHub’s servers), while others will require installing requisite software on your own computer to build the site locally. Nearly every aspect of a Jekyll site is customizable by downloading the relevant files from the theme’s GitHub repository into your own site’s repository and modifying them.

Here are some places to start:

Main Page