hind 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +85 -15
- data/lib/hind/version.rb +1 -1
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 32bbe6d5a60d938e3488b900d71934deece01265da3ad23b62ab75fef4a84886
|
4
|
+
data.tar.gz: c4e90be47c9b2c73b56e0f861753dda011dd8429adb79467804162955601ee88
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 58ecd7c81c2c9ef20610421321724e7c559b6a54044e947bead98449cea231dcc27d2c21215ec3ed64d5b62cfc0534e64674dabeace288d7a75dca828755ed58
|
7
|
+
data.tar.gz: 52a181f665a67514012349f3886edceb771a7771225da08dfe69fdf8969264c34df0d650a6adecb98c375ce840a0d102b0ecc2b422a64ab0cb2fb62e17f85475
|
data/README.md
CHANGED
@@ -1,39 +1,109 @@
|
|
1
1
|
# Hind
|
2
2
|
|
3
|
-
|
4
|
-
|
5
|
-
Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/hind`. To experiment with that code, run `bin/console` for an interactive prompt.
|
3
|
+
Hind is a Ruby gem for generating code intelligence data in LSIF (Language Server Index Format) and SCIP (Sourcegraph Code Intelligence Protocol) formats. It helps create index files that power code navigation features like go-to-definition, find references, and hover documentation.
|
6
4
|
|
7
5
|
## Installation
|
8
6
|
|
9
|
-
|
10
|
-
|
11
|
-
Install the gem and add to the application's Gemfile by executing:
|
7
|
+
Install the gem:
|
12
8
|
|
13
9
|
```bash
|
14
|
-
|
10
|
+
gem install hind
|
15
11
|
```
|
16
12
|
|
17
|
-
|
13
|
+
Or add it to your Gemfile:
|
18
14
|
|
19
|
-
```
|
20
|
-
gem
|
15
|
+
```ruby
|
16
|
+
gem 'hind'
|
21
17
|
```
|
22
18
|
|
23
19
|
## Usage
|
24
20
|
|
25
|
-
|
21
|
+
### Generating LSIF Data
|
22
|
+
|
23
|
+
To generate LSIF data for your Ruby project:
|
24
|
+
|
25
|
+
```bash
|
26
|
+
# Basic usage
|
27
|
+
hind lsif
|
28
|
+
|
29
|
+
# Specify directory and output file
|
30
|
+
hind lsif -d /path/to/project -o output.lsif
|
31
|
+
|
32
|
+
# Process specific files with glob pattern
|
33
|
+
hind lsif -g "lib/**/*.rb"
|
34
|
+
|
35
|
+
# Exclude patterns
|
36
|
+
hind lsif -e "test/**/*" -e "spec/**/*"
|
37
|
+
|
38
|
+
# Verbose output
|
39
|
+
hind lsif -v
|
40
|
+
```
|
41
|
+
|
42
|
+
Options:
|
43
|
+
- `-d, --directory DIR` - Root directory to process (default: current directory)
|
44
|
+
- `-o, --output FILE` - Output file path (default: dump.lsif)
|
45
|
+
- `-g, --glob PATTERN` - File pattern to match (default: **/*.rb)
|
46
|
+
- `-f, --force` - Overwrite output file if it exists
|
47
|
+
- `-e, --exclude PATTERN` - Patterns to exclude (can be specified multiple times)
|
48
|
+
- `-v, --verbose` - Enable verbose output
|
49
|
+
- `-c, --config FILE` - Path to configuration file
|
50
|
+
|
51
|
+
|
52
|
+
|
53
|
+
### GitLab Integration
|
54
|
+
|
55
|
+
To use Hind with GitLab for code intelligence:
|
56
|
+
|
57
|
+
1. Add this to your `.gitlab-ci.yml`:
|
58
|
+
|
59
|
+
```yaml
|
60
|
+
lsif:
|
61
|
+
stage: lsif
|
62
|
+
script:
|
63
|
+
- gem install hind
|
64
|
+
- hind lsif -d . -o dump.lsif -v
|
65
|
+
artifacts:
|
66
|
+
reports:
|
67
|
+
lsif: dump.lsif
|
68
|
+
```
|
69
|
+
|
70
|
+
2. GitLab will automatically process the LSIF data and enable code intelligence features.
|
71
|
+
|
72
|
+
## Features
|
73
|
+
|
74
|
+
- Generates LSIF data for Ruby code
|
75
|
+
- Supports code intelligence features:
|
76
|
+
- Go to definition
|
77
|
+
- Find references
|
78
|
+
- Hover documentation
|
79
|
+
- Symbol search
|
80
|
+
- Integrates with GitLab code intelligence
|
81
|
+
- Configurable output and processing
|
82
|
+
- Comprehensive error checking and reporting
|
26
83
|
|
27
84
|
## Development
|
28
85
|
|
29
|
-
After checking out the repo
|
86
|
+
After checking out the repo:
|
30
87
|
|
31
|
-
|
88
|
+
1. Install dependencies:
|
89
|
+
```bash
|
90
|
+
bundle install
|
91
|
+
```
|
92
|
+
|
93
|
+
2. Run tests:
|
94
|
+
```bash
|
95
|
+
bundle exec rspec
|
96
|
+
```
|
97
|
+
|
98
|
+
3. Run the gem locally:
|
99
|
+
```bash
|
100
|
+
bundle exec bin/hind
|
101
|
+
```
|
32
102
|
|
33
103
|
## Contributing
|
34
104
|
|
35
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
105
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/yourusername/hind.
|
36
106
|
|
37
107
|
## License
|
38
108
|
|
39
|
-
The gem is available as open source under the terms of the
|
109
|
+
The gem is available as open source under the terms of the MIT License.
|
data/lib/hind/version.rb
CHANGED
metadata
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hind
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
|
-
-
|
7
|
+
- Aboobacker MK
|
8
8
|
bindir: bin
|
9
9
|
cert_chain: []
|
10
10
|
date: 2025-02-09 00:00:00.000000000 Z
|
@@ -95,7 +95,7 @@ dependencies:
|
|
95
95
|
version: '3.0'
|
96
96
|
description: A tool to generate LSIF and SCIP index files for Ruby codebases
|
97
97
|
email:
|
98
|
-
-
|
98
|
+
- aboobackervyd@gmail.com
|
99
99
|
executables:
|
100
100
|
- hind
|
101
101
|
extensions: []
|
@@ -119,14 +119,14 @@ files:
|
|
119
119
|
- lib/hind/scip/generator.rb
|
120
120
|
- lib/hind/scip/visitor.rb
|
121
121
|
- lib/hind/version.rb
|
122
|
-
homepage: https://github.com/
|
122
|
+
homepage: https://github.com/tachyons/hind
|
123
123
|
licenses:
|
124
124
|
- MIT
|
125
125
|
metadata:
|
126
126
|
allowed_push_host: https://rubygems.org
|
127
|
-
homepage_uri: https://github.com/
|
128
|
-
source_code_uri: https://github.com/
|
129
|
-
changelog_uri: https://github.com/
|
127
|
+
homepage_uri: https://github.com/tachyons/hind
|
128
|
+
source_code_uri: https://github.com/tachyons/hind
|
129
|
+
changelog_uri: https://github.com/tachyons/hind/blob/main/CHANGELOG.md
|
130
130
|
rdoc_options: []
|
131
131
|
require_paths:
|
132
132
|
- lib
|