From d6b26aff05ffcaf8c5822ee864aa9d6d8ade7ba3 Mon Sep 17 00:00:00 2001 From: duffn <3457341+duffn@users.noreply.github.com> Date: Mon, 20 Mar 2023 09:50:43 -0600 Subject: [PATCH] Fix YARD docs markdown rendering (#2310) * Fix YARD doc markdown rendering * Fix Rubocop violation * Fix contain_exactly test --------- Co-authored-by: Daniel (dB.) Doubrovkine --- .gitignore | 1 + .yardopts | 1 + CHANGELOG.md | 1 + CONTRIBUTING.md | 2 ++ 4 files changed, 5 insertions(+) diff --git a/.gitignore b/.gitignore index 9e152a5d4c..f9212a64a1 100644 --- a/.gitignore +++ b/.gitignore @@ -35,6 +35,7 @@ dist Gemfile.lock gemfiles/*.lock tmp +.yardoc ## Rubinius .rbx diff --git a/.yardopts b/.yardopts index 51701cd722..0e82f4d976 100644 --- a/.yardopts +++ b/.yardopts @@ -1 +1,2 @@ --asset grape.png +--markup markdown diff --git a/CHANGELOG.md b/CHANGELOG.md index 64fc42ac05..d3eadea17b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,7 @@ * [#2303](https://github.com/ruby-grape/grape/pull/2302): Rack >= 1.3.0 - [@ericproulx](https://github.com/ericproulx). * [#2301](https://github.com/ruby-grape/grape/pull/2301): Revisit GH workflows - [@ericproulx](https://github.com/ericproulx). * [#2311](https://github.com/ruby-grape/grape/pull/2311): Fix tests by pinning rack-test to < 2.1 - [@duffn](https://github.com/duffn). +* [#2310](https://github.com/ruby-grape/grape/pull/2310): Fix YARD docs markdown rendering - [@duffn](https://github.com/duffn). * Your contribution here. #### Fixes diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7cde59694f..5405c652a5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -58,6 +58,8 @@ Make sure that `bundle exec rake` completes without errors. Document any external behavior in the [README](README.md). +You should also document code as necessary, using current code as examples. This project uses [YARD](https://yardoc.org/). You can run and preview the docs locally by [installing `yard`](https://yardoc.org/), running `yard server --reload` and view the docs at http://localhost:8808. + #### Update Changelog Add a line to [CHANGELOG](CHANGELOG.md) under *Next Release*. Make it look like every other line, including your name and link to your Github account.