GitBook Editor



When using GitBook for reading code documentation, it's quite glaring to be forced to switch to a bright screen when going back and forth between a code editor (usually dark) and the documentation. I made a quick mockup of what it could look like. This could come as a dark mode toggle on the user end, as an option for the book editors, or in. Powered by GitBook. However, the free level editor is still available here. Download the version of the editor you need if you are on Windows or Mac.

  1. Gitbook Editor Alternative
  2. Gitbook Editor Mac
  3. Gitbook Editor Linux

A GitBook is a useful tool for creating (open?) educational resources. It is an online “book” format, that can be hosted directly from a GitHub repository. You are currently reading a GitBook designed to help you get started creating your own educational GitBooks for your courses (how meta!). It does this in two ways: By explaining how to create GitBooks, and by serving as a template that you can copy and edit, instead of having to start from scratch. This template GitBook has all the settings that I consider to be useful for educational GitBooks, but you can always customize it.

I will focus specifically on GitBooks that are made in Rstudio, using the rmarkdown markup language, rendered using the bookdown package, and hosted on GitHub. If you want to get started, skip ahead to Chapter 2; if you need more convincing, keep reading below.

Gitbook

1.1 Why use a GitBook for teaching?

To spead the workload

My challenge was that I had to translate all tutorial instructions from proprietary software to R, and there was not enough time to complete this task before the course commenced. By making the tutorial instructions available in this GitBook, I was able to continue translating tutorial instructions while the semester was ongoing, and push updates to GitHub in time for each session, which were immediately available to all students. The parallel with the current situation is that some courses are now forced to start teaching in an online format, without having enough time to completely prepare. By using a GitBook, you can spread out the workload of preparing your materials across the semester. This is the finished GitBook

To contribute or use existing Open Educational Resources

Download

Another key advantage of using a GitBook is, that you can easily make your course materials available for others to use under an open access license, or perhaps you can use an existing GitBook from the internet and adapt it for your own uses. GitBooks can be easily duplicated and adapted, just like any other project hosted on GitHub. Contributing Open Educational Materials can help reduce the workload on teachers around the world, and can improve the quality of the materials used thanks to online collaborating and feedback.

To benefit from formatting advantages

GitBooks also have two formatting advantages over classic PDF or Word files. First, they are Rmarkdown files, and can thus include blocks of R (or Python) code that can be evaluated, and whose results are rendered to the file. Second, they are interactive web pages, and as such, can have dynamic features (such as answers to assignments that can be hidden, or boxes where students can fill out an answer to be checked). Additionally, other web pages or interactive apps can be embedded within the page. So whereas a traditional document is static, GitBooks can be interactive.

How do GitBooks work?

GitBooks consist of an Rstudio project, with several Rmarkdown files containing the chapters of the book. Inside Rstudio, users can press a “Build Book” button, which renders all of these chapters to a nicely formatted HTML book (and a PDF file for users to download). Users can push the finished book to a GitHub repository, and indicate on GitHub that the book should be hosted on GitHub pages. Voilà!

Getting started

If you are convinced that this tool might benefit your teaching, your first point of action is to prepare your system for creating GitBooks (Chapter 2). After that, you can get a copy of this GitBook as a template (Chapter 3). Then, you can start tweaking it for your own course!

GitBook is one of the best Markdown editors I have ever used. It is available for Linux, Windows and OS X. It has features like auto-complete and drag and drop. GitBook has built-in support for Version Control. To install GitBook on Ubuntu using the .deb package, open a terminal by pressing Ctrl + Alt + T and follow the steps given below:

> Install using .deb package

Step 1:

Download the debian(.deb) package by clicking here.

Before proceeding remember to change your working directory in terminal to the directory where the .deb package was downloaded. Use the cd command to change directory.

Step 2:

Install the package using the dpkg command:

Replace FileName with the name of the file you just downloaded.

Step 3:

Gitbook Editor Alternative

Finally, to install any missing dependencies run:

Step 4:

If you get the following error:

Gitbook Editor Mac

gitbook-editor: error while loading shared libraries: libgtk-x11-2.0.so.0: cannot open shared object file: No such file or directory

Install libgtk2.0 by running the following command:

If you get the following error:

gitbook-editor: error while loading shared libraries: libXtst.so.6: cannot open shared object file: No such file or directory

Install libxtst6 by running the following command:

Step 5:

You are all set, GitBook editor has been successfully installed on your system.

Gitbook Editor Linux

Any further queries and suggestions are welcome in the comments section below. If you wish to try out Typora or Remarkable the installation guide can be found here and here respectively.