Permalink
Browse files

Ship with Ruby 2.2.2 yardocs.

  • Loading branch information...
castwide committed Dec 3, 2017
1 parent e30f160 commit 856cedb728ac3502a56ec86476ce22f1762e418d
@@ -38,7 +38,7 @@ Documentation for Solargraph integration is forthcoming. In the meantime, refer

## Updating the Core Documentation (EXPERIMENTAL)

The Solargraph gem ships with documentation for Ruby 2.0.0. As of gem version 0.15.0, there's an option to download additional documentation for other Ruby versions from the command line.
The Solargraph gem ships with documentation for Ruby 2.2.2. As of gem version 0.15.0, there's an option to download additional documentation for other Ruby versions from the command line.

$ solargraph list-cores # List the installed documentation versions
$ solargraph available-cores # List the versions available for download
@@ -20,4 +20,4 @@ module Solargraph
YARD_EXTENSION_FILE = File.join(File.realpath(File.dirname(__FILE__)), 'yard-solargraph.rb')
end

Solargraph::YardMap::CoreDocs.require_2_0_0
Solargraph::YardMap::CoreDocs.require_minimum
@@ -1,3 +1,3 @@
module Solargraph
VERSION = '0.14.3'
VERSION = '0.15.0'
end
@@ -15,13 +15,13 @@ def cache_dir
@cache_dir ||= File.join(Dir.home, '.solargraph', 'cache')
end

# Solargraph installs the Ruby 2.0.0 to ensure minimum functionality.
def require_2_0_0
# Solargraph installs Ruby 2.2.2 documentation to ensure minimum functionality.
def require_minimum
FileUtils.mkdir_p cache_dir
version_dir = File.join(cache_dir, '2.0.0')
version_dir = File.join(cache_dir, '2.2.2')
unless File.exist?(version_dir)
FileUtils.cp File.join(Solargraph::YARDOC_PATH, '2.0.0.tar.gz'), cache_dir
install_archive File.join(cache_dir, '2.0.0.tar.gz')
FileUtils.cp File.join(Solargraph::YARDOC_PATH, '2.2.2.tar.gz'), cache_dir
install_archive File.join(cache_dir, '2.2.2.tar.gz')
end
end

@@ -85,7 +85,7 @@ def download version

def clear
FileUtils.rm_rf cache_dir, secure: true
require_2_0_0
require_minimum
end

private
BIN -2.75 MB yardoc/2.0.0.tar.gz
Binary file not shown.
BIN +2.88 MB yardoc/2.2.2.tar.gz
Binary file not shown.

0 comments on commit 856cedb

Please sign in to comment.