Note that this site is in currently in version 1.0.0-alpha.   Some functionality may be limited.

Introduction to the Command Line

Theory to Practice

You’ve made it through your introduction to the command line! By now, you have experienced some of the power of communicating with your computer using text commands. The basic steps you learned today will help as you’ll further your digital skills. For example, you might work with the command line interface to set up your version control with git or you’ll have your text editor open while writing python scripts or building basic websites with HTML and CSS. Having a grasp of command line basics will not only make you more familiar with how your computer and basic programming work, but it will also give you access to tools and communities that will expand your research.

Review your knowledge: 7 questions from the lessons

Try again!

What is the difference between a plain text document and a rich text document? (Select all that apply)

Try again!

What do pipes allow you to do?

(Select all that apply)

Try again!

What effect does the following command produce?

$ echo "Hello! My Name is Mark!" > introduction.txt
(Select one of the following)

Try again!

What does the up arrow command do?

(Select one of the following)

Try again!

What do command line flags allow you to do?

(Select one of the following)

Try again!

Let's think about the grep command.

(Select all that apply)

Try again!

What command do you run if you are trying to identify where in the filesystem you are currently located/working?

(Select all that apply)

Deepen your knowledge

Discussion Questions

  • What are some of the operations that using the command line, as opposed as your GUI, allows you to perform?

  • What has learning to use the command line taught you about your machine?


DHRI workshops provide a foundational comprehension of digital skills and tools often used in digital humanities and humanistic social science research. While having a strong foundation is important, there is usually more to learn if you want to get started on your own. Now that you have an awareness of the basics, here are some other tutorials to try that will extend your learning.

Data Science at the Command Line

Data Science at the Command Line is an open access e-book by Jeroen Janssens, a hands-on guide that can help you become a more efficient and productive data scientist through the use of the command line.


BashGuide offers some good practice techniques for taking your BASH skills to a higher level by teaching you write some simple scripts.

Further Readings

After they complete a workshop, participants often ask: what next? Here are some additional resources that can help you think about the projects that could be developed, the resources that you might need, the ways this skill could be used in the classroom, or debates in the field of digital humanities that provide context to what you have just learned.

Stephen Ramsay

Stephen Ramsay is a scholar that has thought at length about the way the command line is (or can be!) embedded in a researcher’s praxis. If you’re interested in reading his work, here are two of his finest essays: “Life on the Command Line” and “Programming with Humanists: Reflections on Raising an Army of Hacker-Scholars in the Digital Humanities”

Projects or Challenges to Try

More command line challenges

More command line challenges devised by the GCDI team are available here.

Bash Reference Manual

When working with digital tools, it’s usually a good idea to familiarize with their documentation. Here’s the Bash Reference Manual, where you can find Bash features for beginners and advanced users.


Pandoc is an online software that allows users to convert file types through the commandline (from markdown to PDF, for example).


youtube-dl is a command-line exercise to download videos from It requires the Python interpreter.

MALLET (MAchine Learning for LanguagE Toolkit)

Feeling super brave? You might want to give MALLET (MAchine Learning for LanguagE Toolkit) a shot! MALLET is a “a Java-based package for statistical natural language processing, document classification, clustering, topic modeling, information extraction, and other machine learning applications to text.” It includes tools for document classification, sequence tagging, topic modeling, and numerical optimization.