Skip to content

Commit

Permalink
Switch to RDOC
Browse files Browse the repository at this point in the history
  • Loading branch information
vinistock committed May 2, 2023
1 parent 68b99eb commit e077637
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 16 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/publish_docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
git config user.email [email protected]
- name: Generate documentation
run: bundle exec rake yard
run: bundle exec rake rdoc

- name: Commit to gh-pages
run: |
Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ gem "rubocop-rake", "~> 0.6.0", require: false
gem "rubocop-sorbet", "~> 0.7", require: false
gem "sorbet-static-and-runtime", platforms: NON_WINDOWS_PLATFORMS
gem "tapioca", "~> 0.11", require: false, platforms: NON_WINDOWS_PLATFORMS
gem "yard", "~> 0.9", require: false
gem "rdoc", require: false

# The Rails documentation link only activates when railties is detected.
gem "railties", "~> 7.0", require: false
9 changes: 8 additions & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,14 @@ GEM
nokogiri (1.14.3)
mini_portile2 (~> 2.8.0)
racc (~> 1.4)
nokogiri (1.14.3-arm64-darwin)
racc (~> 1.4)
parallel (1.23.0)
parser (3.2.2.0)
ast (~> 2.4.1)
prettier_print (1.2.1)
psych (5.0.1)
stringio
racc (1.6.2)
rack (2.2.6.4)
rack-test (2.1.0)
Expand All @@ -88,6 +92,8 @@ GEM
parser (>= 2.6.4.0)
sorbet-runtime (>= 0.5.9204)
unparser
rdoc (6.5.0)
psych (>= 4.0.0)
regexp_parser (2.8.0)
reline (0.3.3)
io-console (~> 0.5)
Expand Down Expand Up @@ -134,6 +140,7 @@ GEM
sorbet (>= 0.5.10187)
sorbet-runtime (>= 0.5.9204)
thor (>= 0.19.2)
stringio (3.0.4)
syntax_tree (6.1.1)
prettier_print (>= 1.2.0)
tapioca (0.11.5)
Expand Down Expand Up @@ -173,6 +180,7 @@ DEPENDENCIES
mocha (~> 2.0)
railties (~> 7.0)
rake (~> 13.0)
rdoc
rubocop (~> 1.50)
rubocop-minitest (~> 0.30.0)
rubocop-rake (~> 0.6.0)
Expand All @@ -181,7 +189,6 @@ DEPENDENCIES
ruby-lsp!
sorbet-static-and-runtime
tapioca (~> 0.11)
yard (~> 0.9)

BUNDLED WITH
2.4.7
21 changes: 11 additions & 10 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,28 @@

require "bundler/gem_tasks"
require "rake/testtask"
require "yard"
require "rdoc/task"
require "ruby_lsp/check_docs"

Rake::TestTask.new(:test) do |t|
t.libs << "test"
t.libs << "lib"
t.test_files = FileList["test/**/*_test.rb"]
end

YARD::Rake::YardocTask.new do |t|
t.options = [
"--markup",
"markdown",
"--output-dir",
"docs",
"--asset",
"misc",
]
RDoc::Task.new do |rdoc|
rdoc.main = "README.md"
rdoc.rdoc_files.include("*.md", "lib/**/*.rb")
rdoc.rdoc_dir = "docs"
rdoc.markup = "markdown"
rdoc.options.push("--copy-files", "misc")
rdoc.options.push("--copy-files", "LICENSE.txt")
end

require "rubocop/rake_task"

RuboCop::RakeTask.new

RubyLsp::CheckDocs.new(FileList["#{__dir__}/lib/ruby_lsp/**/*.rb"])

task default: [:test]
6 changes: 3 additions & 3 deletions dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,17 @@ up:

commands:
docs:
run: bundle exec rake yard
run: bundle exec rake rdoc
subcommands:
check:
run: bundle exec rake check_docs
run: bundle exec rake ruby_lsp:check_docs
server: exe/ruby-lsp
style: bin/rubocop
typecheck:
aliases: ["tc"]
run: "bundle exec srb tc"
ci:
run: "bundle exec rake check_docs &&
run: "bundle exec rake ruby_lsp:check_docs &&
bundle exec rake check_visit_overrides &&
bundle exec srb tc &&
bin/rubocop &&
Expand Down

0 comments on commit e077637

Please sign in to comment.