solargraph-rails-init 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +8 -0
- data/Gemfile +8 -0
- data/Gemfile.lock +19 -0
- data/LICENSE.txt +21 -0
- data/README.md +38 -0
- data/Rakefile +4 -0
- data/bin/console +15 -0
- data/bin/setup +8 -0
- data/exe/solargraph-rails-init +25 -0
- data/lib/solargraph/rails/init.rb +12 -0
- data/lib/solargraph/rails/init/version.rb +9 -0
- data/solargraph-rails-init.gemspec +29 -0
- metadata +58 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 3ab7bbc5e69a862fdc9d7dab811099ab9330787fe784b324d699c74827a1f5f2
|
4
|
+
data.tar.gz: 7539801b051fa4f3939bcde2ef252caea6af3b98d8ef2e2723311a56fbad1add
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 2a6c2f0b9dd006b94d0e87a5f6ae2422cecfee6614a9a178e0f797af99675a74b4329246830763b71e4b8a847eb06f99121b7a4d52e8cb4f8a38c0b1f98ef420
|
7
|
+
data.tar.gz: 4d7b06d798db0c5f911b6b95d15c0e7ee0f589dedb460cddbe42ed9528b07285ac10885f5056a7edfe88a8d6ca7a819138f8bf3b14404ac506b754aa57239122
|
data/.gitignore
ADDED
data/Gemfile
ADDED
data/Gemfile.lock
ADDED
@@ -0,0 +1,19 @@
|
|
1
|
+
PATH
|
2
|
+
remote: .
|
3
|
+
specs:
|
4
|
+
solargraph-rails-init (0.1.0)
|
5
|
+
|
6
|
+
GEM
|
7
|
+
remote: https://rubygems.org/
|
8
|
+
specs:
|
9
|
+
rake (13.0.3)
|
10
|
+
|
11
|
+
PLATFORMS
|
12
|
+
x86_64-darwin-20
|
13
|
+
|
14
|
+
DEPENDENCIES
|
15
|
+
rake (~> 13.0)
|
16
|
+
solargraph-rails-init!
|
17
|
+
|
18
|
+
BUNDLED WITH
|
19
|
+
2.2.11
|
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2021 Carl Mercier
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,38 @@
|
|
1
|
+
# solargraph-rails-init
|
2
|
+
|
3
|
+
A simple script to configure Solargraph to work with Rails that acts as a shortcut to the following commands:
|
4
|
+
|
5
|
+
```bash
|
6
|
+
gem install solargraph
|
7
|
+
solargraph download-core
|
8
|
+
yard gems
|
9
|
+
solargraph bundle
|
10
|
+
curl -s https://gist.githubusercontent.com/cmer/024991c85c4de01dab17632b2dc7f064/raw > .solargraph.yml
|
11
|
+
curl -s https://gist.githubusercontent.com/castwide/28b349566a223dfb439a337aea29713e/raw > config/definitions.rb
|
12
|
+
```
|
13
|
+
|
14
|
+
|
15
|
+
## Installation
|
16
|
+
|
17
|
+
Run the following commands in your Rails app root directory:
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
gem install solargraph-rails-init
|
21
|
+
solargraph-rails-init
|
22
|
+
```
|
23
|
+
|
24
|
+
Run `solargraph-rails-init` again if you install new gems or change your Ruby version.
|
25
|
+
|
26
|
+
## Inspiration
|
27
|
+
|
28
|
+
This was inspired by [Setting up Solargraph for VSCode](https://www.youtube.com/watch?v=mkLDPpDSWng).
|
29
|
+
|
30
|
+
|
31
|
+
## Contributing
|
32
|
+
|
33
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/cmer/solargraph-rails-init.
|
34
|
+
|
35
|
+
|
36
|
+
## License
|
37
|
+
|
38
|
+
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
data/Rakefile
ADDED
data/bin/console
ADDED
@@ -0,0 +1,15 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
# frozen_string_literal: true
|
3
|
+
|
4
|
+
require "bundler/setup"
|
5
|
+
require "solargraph/rails/init"
|
6
|
+
|
7
|
+
# You can add fixtures and/or initialization code here to make experimenting
|
8
|
+
# with your gem easier. You can also use a different console, if you like.
|
9
|
+
|
10
|
+
# (If you use this, don't forget to add pry to your Gemfile!)
|
11
|
+
# require "pry"
|
12
|
+
# Pry.start
|
13
|
+
|
14
|
+
require "irb"
|
15
|
+
IRB.start(__FILE__)
|
data/bin/setup
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
#!/usr/bin/env ruby
|
2
|
+
|
3
|
+
puts "Installing Solargraph gem..."
|
4
|
+
`gem install solargraph`
|
5
|
+
|
6
|
+
puts "Installing documentation. This might take a while..."
|
7
|
+
`solargraph download-core`
|
8
|
+
`yard gems`
|
9
|
+
`solargraph bundle`
|
10
|
+
|
11
|
+
unless File.exist?('.solargraph.yml')
|
12
|
+
puts "Copying .solargraph.yml..."
|
13
|
+
`curl -s https://gist.githubusercontent.com/cmer/024991c85c4de01dab17632b2dc7f064/raw > .solargraph.yml`
|
14
|
+
else
|
15
|
+
puts "Skipped copying .solargraph.yml. Already exists."
|
16
|
+
end
|
17
|
+
|
18
|
+
unless File.exist?('config/definitions.rb')
|
19
|
+
puts "Copying definitions.rb..."
|
20
|
+
`curl -s https://gist.githubusercontent.com/castwide/28b349566a223dfb439a337aea29713e/raw > config/definitions.rb`
|
21
|
+
else
|
22
|
+
puts "Skipped copying .definitions.rb. Already exists."
|
23
|
+
end
|
24
|
+
|
25
|
+
puts "Done!"
|
@@ -0,0 +1,29 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require_relative "lib/solargraph/rails/init/version"
|
4
|
+
|
5
|
+
Gem::Specification.new do |spec|
|
6
|
+
spec.name = "solargraph-rails-init"
|
7
|
+
spec.version = Solargraph::Rails::Init::VERSION
|
8
|
+
spec.authors = ["Carl Mercier"]
|
9
|
+
spec.email = ["foss@carlmercier.com"]
|
10
|
+
|
11
|
+
spec.summary = "A simple script to initialize a Rails app to use Solargraph"
|
12
|
+
spec.description = "A simple script to initialize a Rails app to use Solargraph"
|
13
|
+
spec.homepage = "https://github.com/cmer/solargraph-rails-init"
|
14
|
+
spec.license = "MIT"
|
15
|
+
spec.required_ruby_version = Gem::Requirement.new(">= 2.4.0")
|
16
|
+
|
17
|
+
spec.metadata["homepage_uri"] = spec.homepage
|
18
|
+
spec.metadata["source_code_uri"] = "https://github.com/cmer/solargraph-rails-init"
|
19
|
+
|
20
|
+
|
21
|
+
# Specify which files should be added to the gem when it is released.
|
22
|
+
# The `git ls-files -z` loads the files in the RubyGem that have been added into git.
|
23
|
+
spec.files = Dir.chdir(File.expand_path(__dir__)) do
|
24
|
+
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{\A(?:test|spec|features)/}) }
|
25
|
+
end
|
26
|
+
spec.bindir = "exe"
|
27
|
+
spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
|
28
|
+
spec.require_paths = ["lib"]
|
29
|
+
end
|
metadata
ADDED
@@ -0,0 +1,58 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: solargraph-rails-init
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Carl Mercier
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2021-03-14 00:00:00.000000000 Z
|
12
|
+
dependencies: []
|
13
|
+
description: A simple script to initialize a Rails app to use Solargraph
|
14
|
+
email:
|
15
|
+
- foss@carlmercier.com
|
16
|
+
executables:
|
17
|
+
- solargraph-rails-init
|
18
|
+
extensions: []
|
19
|
+
extra_rdoc_files: []
|
20
|
+
files:
|
21
|
+
- ".gitignore"
|
22
|
+
- Gemfile
|
23
|
+
- Gemfile.lock
|
24
|
+
- LICENSE.txt
|
25
|
+
- README.md
|
26
|
+
- Rakefile
|
27
|
+
- bin/console
|
28
|
+
- bin/setup
|
29
|
+
- exe/solargraph-rails-init
|
30
|
+
- lib/solargraph/rails/init.rb
|
31
|
+
- lib/solargraph/rails/init/version.rb
|
32
|
+
- solargraph-rails-init.gemspec
|
33
|
+
homepage: https://github.com/cmer/solargraph-rails-init
|
34
|
+
licenses:
|
35
|
+
- MIT
|
36
|
+
metadata:
|
37
|
+
homepage_uri: https://github.com/cmer/solargraph-rails-init
|
38
|
+
source_code_uri: https://github.com/cmer/solargraph-rails-init
|
39
|
+
post_install_message:
|
40
|
+
rdoc_options: []
|
41
|
+
require_paths:
|
42
|
+
- lib
|
43
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 2.4.0
|
48
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
49
|
+
requirements:
|
50
|
+
- - ">="
|
51
|
+
- !ruby/object:Gem::Version
|
52
|
+
version: '0'
|
53
|
+
requirements: []
|
54
|
+
rubygems_version: 3.1.4
|
55
|
+
signing_key:
|
56
|
+
specification_version: 4
|
57
|
+
summary: A simple script to initialize a Rails app to use Solargraph
|
58
|
+
test_files: []
|