vim-tags 1.0.2 → 1.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: d0f7b059c27cda270e8b674ff1572c468b46653357bad9a0c0ed92335e1d8db7
4
- data.tar.gz: a2e993a9edc418fa3cd1c6b27efaa3a4e63d24a114f1db7f3d3397694709a691
3
+ metadata.gz: 6ca213be5515220844966a74f4c5aa14f71517b7b003c1bedd3c5d96ad965165
4
+ data.tar.gz: 199e3f85f614fa9113b98ee3df5ea3b1a7f2f0b38529fc11c1587c0346aa436d
5
5
  SHA512:
6
- metadata.gz: a7ff80f898bf224b54e99d0b0d7aa3db1ceeed382ebc8ae88d9a38d15fb687e532589eea9a207ad3d57526f44bca61ce9272903783ee48db5336829321d9ff3f
7
- data.tar.gz: fc6a2cb64e2e57e3b7a076b8a10b8b42393056921a4aa3a5dce7418e65a1e22ca7c2e7cefdd1f253c7116a9c67ce73fba5cd4ccbe9696bc577dfc67dae6990a8
6
+ metadata.gz: ab6d3baacb13aae1f78a1736597547124ea4d1df0bdfe4d1a0b42627ae9f569deadc3a1b25062842923e3ecd0f8d88a7266015d6b716ce1ab0dc3503d8c30bc2
7
+ data.tar.gz: 47b1fce292ee835e3e69ee87f5f58d6897b805be0df3d0876c476145b703d971c05dac078d21ac201b3234c6fee3e88ab5644d0f39d2ac7a1025eb0195b5bbf4
data/plugin/vim-tags.vim CHANGED
@@ -1,19 +1,21 @@
1
1
  function! LoadRubyTags()
2
2
  let l:project_directory = finddir('.git/..', expand('%:p:h').';')
3
3
 
4
- if !empty(l:project_directory)
4
+ if !empty(l:project_directory) && filereadable(l:project_directory . '/Gemfile')
5
5
  let l:gem_tag_files_path = l:project_directory . '/.bundle/.gem_tag_files'
6
6
 
7
- if !filereadable(l:gem_tag_files_path)
7
+ if !filereadable(l:gem_tag_files_path) && !get(g:, 'vim_tags_skip_bundle', 0)
8
8
  let l:install_response = system('bundler plugin install vim-tags')
9
9
  let l:command_response = system('bundler vim-tags')
10
10
  endif
11
11
 
12
- let l:gems = json_decode(readfile(l:gem_tag_files_path))
13
- let l:ruby = json_decode(readfile(l:project_directory . '/.bundle/.ruby_tag_files'))
12
+ if filereadable(l:gem_tag_files_path)
13
+ let l:gems = json_decode(readfile(l:gem_tag_files_path))
14
+ let l:ruby = json_decode(readfile(l:project_directory . '/.bundle/.ruby_tag_files'))
14
15
 
15
- let &l:tags = &tags . ',' . l:gems['tags'] . ',' . l:ruby['tags']
16
- let &l:path = &path . ',' . l:gems['paths'] . ',' . l:ruby['paths']
16
+ let &l:tags = &tags . ',' . l:gems['tags'] . ',' . l:ruby['tags']
17
+ let &l:path = &path . ',' . l:gems['paths'] . ',' . l:ruby['paths']
18
+ endif
17
19
  endif
18
20
  endfunction
19
21
 
data/plugins.rb CHANGED
@@ -9,6 +9,7 @@ class VimTagsCommand < Bundler::Plugin::API
9
9
  def exec(*)
10
10
  write_gem_file
11
11
  write_ruby_file
12
+ write_gem_paths_file
12
13
  end
13
14
 
14
15
  private
@@ -21,6 +22,14 @@ class VimTagsCommand < Bundler::Plugin::API
21
22
  )
22
23
  end
23
24
 
25
+ def write_gem_paths_file
26
+ write_to_file(
27
+ File.join(Bundler.app_config_path, ".gem_paths"),
28
+ "\nWriting gem paths cache",
29
+ gem_specs.map { |spec| [spec.name, spec.full_gem_path] }.to_h.to_json
30
+ )
31
+ end
32
+
24
33
  def write_ruby_file
25
34
  write_to_file(
26
35
  File.join(Bundler.app_config_path, ".ruby_tag_files"),
data/vim-tags.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "vim-tags"
5
- spec.version = "1.0.2"
5
+ spec.version = "1.0.3"
6
6
  spec.authors = ["Nick Pezza"]
7
7
  spec.email = ["pezza@hey.com"]
8
8
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vim-tags
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nick Pezza
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-12-21 00:00:00.000000000 Z
11
+ date: 2024-12-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: debug
@@ -56,7 +56,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
56
56
  - !ruby/object:Gem::Version
57
57
  version: '0'
58
58
  requirements: []
59
- rubygems_version: 3.2.22
59
+ rubygems_version: 3.5.13
60
60
  signing_key:
61
61
  specification_version: 4
62
62
  summary: Generate cache file of all paths to tags files of dependencies