neeto-translate-cli 0.2.8 → 0.2.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 7d1e43201f183d061de8314572b0cfbd0d2e056a8ab780876a3b40bac078aa4a
4
- data.tar.gz: 5d4e21c9a5d2c0d10b9ef3c0877dec6f674764a998511e96a27b56da9eaebce5
3
+ metadata.gz: 69664999355e94a492f7b2143f475555d5d34f74952be53360b636d08eacdd11
4
+ data.tar.gz: e662a70a78a0aa498611279feb5179bcb76e219c10d17678c4b365c6f68836bf
5
5
  SHA512:
6
- metadata.gz: ac523a25c9ba9af2261d7581fb8375dbea96f8d3b1b7dbabb2b9f3beff706315def2f1a0dea47acbdfc5493db5d3ca95bd40e50ea3eadbab9f4a3019df21c36f
7
- data.tar.gz: d29dbcd350471c4c3908c0394d57a7fd5fc9b520ba55c649a5416c29951fbcb789394715f59d24908da7b6da18a2aa88d5a7af3b2e2a25a113b4496afd428cdb
6
+ metadata.gz: 9b0196c1e6a1afaa03af7689c547f8cfd00000b25d085f4e3ac708c517f39f977fb4159ea381fb25a7fbb0ac2c0ec878beedd89e40fc4acfb020ec094e4a7033
7
+ data.tar.gz: 225d4a6721608b13f41d86680080f916807d6cd08d52cf5d776b2696ebfb75d8900e3395374f8b913a497046f84f0296009421277d1a8e9e151fcd4ec3dab923
@@ -40,10 +40,32 @@ module NeetoTranslateCli
40
40
 
41
41
  def find_updated_keys(commit_id)
42
42
  updated_frontend_keys = []
43
+
44
+ # Debug: Log the commit_id and current working directory
45
+ puts "DEBUG: commit_id = '#{commit_id}'"
46
+ puts "DEBUG: current working directory = '#{Dir.pwd}'"
47
+ puts "DEBUG: frontend path = '#{options[:frontend]}'"
48
+
43
49
  frontend_translations[:en].each do |file_path, content|
44
50
  lang_file_path = "#{options[:frontend]}/en/#{file_path}.json"
45
51
  relative_path_from_pwd = Pathname.new(lang_file_path).to_s
46
- previous_content = `git show #{commit_id}:#{relative_path_from_pwd}`
52
+
53
+ # Debug: Log the paths being used
54
+ puts "DEBUG: file_path = '#{file_path}'"
55
+ puts "DEBUG: lang_file_path = '#{lang_file_path}'"
56
+ puts "DEBUG: relative_path_from_pwd = '#{relative_path_from_pwd}'"
57
+
58
+ # Debug: Check if file exists
59
+ puts "DEBUG: file exists? #{File.exist?(relative_path_from_pwd)}"
60
+
61
+ # Debug: Try the git show command and log the result
62
+ git_command = "git show #{commit_id}:#{relative_path_from_pwd}"
63
+ puts "DEBUG: running git command: #{git_command}"
64
+
65
+ previous_content = `#{git_command}`
66
+ puts "DEBUG: git show result length = #{previous_content.length}"
67
+ puts "DEBUG: git show result (first 100 chars) = '#{previous_content[0..99]}'"
68
+
47
69
  next if previous_content.empty?
48
70
 
49
71
  previous_json = JSON.parse(previous_content)
@@ -54,11 +76,14 @@ module NeetoTranslateCli
54
76
  flat_previous_json.key?(key) && flat_current_json[key] != flat_previous_json[key]
55
77
  end
56
78
 
79
+ puts "DEBUG: updated_keys_for_file = #{updated_keys_for_file}"
80
+
57
81
  next if updated_keys_for_file.empty?
58
82
 
59
83
  updated_frontend_keys.concat(updated_keys_for_file.map { |key| "#{file_path}::#{key}" })
60
84
  end
61
85
 
86
+ puts "DEBUG: final updated_frontend_keys = #{updated_frontend_keys}"
62
87
  updated_frontend_keys
63
88
  end
64
89
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module NeetoTranslateCli
4
- VERSION = "0.2.8"
4
+ VERSION = "0.2.9"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: neeto-translate-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.8
4
+ version: 0.2.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Abhay V Ashokan
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-09-26 00:00:00.000000000 Z
11
+ date: 2025-10-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday