Plain text presentations in your terminal
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Robert Labudda 797b87b954 . for empty lines 1 year ago
README.md . for empty lines 1 year ago
slide.py . for empty lines 1 year ago

README.md

slide.py

With slide.py you can present plain text files in your terminal.

Presentations are really just plain text files. You can have as many slides as you want per file — from 0 to many and then show them by passing them as arguments to slide.py:

slide.py cover.txt main-part.txt end.txt

You have seen slide.sh and are wondering why there even was the need to create slide.py? There wasn’t.
Except I wanted all slides to be centered in the terminal, given the biggest slide in the deck.
And some more keys.

Writing presentations

A presentation is just a text file and it will be displayed as is with five exceptions:

  • A single line !!pause will hold the presentation until you press a key
  • A single line !!center will center every line after this one
  • A single line !!nocenter will stop centering every line after this one
  • A single line --- SLIDE --- signifies the start of a new slide
  • A single line . will be left empty

So, this is a valid presentation:

!!center
A PRESENTATION
!!nocenter

!!pause
using slide.py

--- SLIDE ---
You are using slide.py. Good for you.
--- SLIDE ---
Have a nice day!

Here’s another presentation:

A single slide, single line presentation.

Empty lines at the start and at the end of every slide will be thrown away. If you want to start the slide with empty lines, use .:

.
.
.
A four-line slide

Navigation

You can navigate the slides using these keys:

  • q, Esc: end the presentation
  • , PgDn, Enter, Space: go to the next slide
  • , PgUp: go to the previous slide
  • Home: go to the first slide

Terminal Font Adjustment

In case you are using a GUI your terminal font might be too small for a good, readable presentation.

Try running slide.py -a with your presentation. It will show a rectangle in the size of the biggest slide, so you can resize your terminal’s font until you get the size you want.

Once you’re done with the adjustment, press q, Enter, or Escape to quit the adjustment screen and start the presentation.