danger-toc
A plugin for danger.systems that makes sure your project’s README.md
has a TOC.
Table of Contents
Installation
Add danger-toc
to your Gemfile.
gem 'danger-toc', '~> 0.1'
Add toc.check
to your Dangerfile. Make a pull request and see this plugin in action.
Usage
Configuration
The plugin supports following configuration options:
Danger::Toc.configure do |config|
config.files = [ 'README.md' ]
config.header = 'Table of Contents'
end
Methods and Attributes
Methods and attributes from this plugin are available in your Dangerfile
under the toc
namespace.
toc.files
List of files to ensure TOC in, default is README.md
.
toc.header
The Table of Contents header, without #
, default is Table of Contents
.
toc.check
Run all checks with defaults.
Contributing
See CONTRIBUTING.
Copyright
Copyright (c) Daniel Doubrovkine, 2017
MIT License, see LICENSE for details.