Project

dasheets

0.01
No commit activity in last 3 years
No release in over 3 years
Generate cheatsheets for Dash
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.3
>= 0

Runtime

~> 4.0.3
~> 2.0
~> 3.1.0
~> 2.0.6
~> 1.3.8
>= 0
 Project Readme

Dasheets

Gem Version

Generate your own cheatsheets as docsets for Dash! Use this simple command line tool and write your cheatsheets in an easy language (Ruby DSL).

Installation

$ gem install dasheets

Usage

Write a file (here tmux.cheatsheet) containing your cheatsheet-data, e. g.:

cheatsheet do
  title 'tmux cheatsheet'
  short_name 'tmux' # Used for the filename of the docset
  introduction 'My *awesome* cheatsheet for tmux'

  # A cheatsheet must consist of categories
  category do
    id 'windows'  # must be unique and is used as title of the category

    entry do
      command 'PREFIX-c'
      name 'create window'            # A short name
      notes 'theses are some notes'   # longer explanation
    end
    entry do
      name 'rename window'
      command 'PREFIX-,'
    end
    entry do
      name 'go to next window'
      command 'PREFIX-n'
    end
  end

  category do
    id 'panes'
    entry do
      name 'split horizontally'
      command 'PREFIX-|'
      notes 'custom mapping'
    end
    entry do
      name 'split horizontally'
      command 'PREFIX-%'
    end
    entry do
      name 'split vertically'
      command 'PREFIX-"'
    end
  end

  notes 'Some notes at the end of the cheatsheet'
end

The following values may contain markdown formatted text:

  • The introduction and the notes of the cheatsheet
  • The name and the notes of the entries

For more complete examples look at some of my actual cheatsheets.

To convert this file to a docset, call

$ dasheets generate tmux.cheatsheet

Contributing

Yes, please! Open issues and pull requests on the GitHub page.

Thanks

svenwin for the awesome name!