greeenboii 0.1.5 → 0.1.6

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.
Files changed (76) hide show
  1. checksums.yaml +4 -4
  2. data/.idea/dataSources/28fe2501-d682-44de-9f2e-9ff4bf02ce84/storage_v2/_src_/schema/main.uQUzAA.meta +0 -0
  3. data/.idea/dataSources/28fe2501-d682-44de-9f2e-9ff4bf02ce84.xml +0 -0
  4. data/.idea/dataSources.local.xml +0 -0
  5. data/.idea/dataSources.xml +0 -0
  6. data/.idea/greeenboii.iml +0 -0
  7. data/.idea/material_theme_project_new.xml +0 -0
  8. data/.idea/modules.xml +0 -0
  9. data/.idea/sqldialects.xml +0 -0
  10. data/.idea/vcs.xml +0 -0
  11. data/.idea/workspace.xml +34 -30
  12. data/.rubocop.sorbet.yml +5 -0
  13. data/.rubocop.yml +36 -0
  14. data/CHANGELOG.md +0 -0
  15. data/CODE_OF_CONDUCT.md +0 -0
  16. data/CONTRIBUTING.md +0 -0
  17. data/LICENSE.txt +0 -0
  18. data/Makefile +0 -0
  19. data/README.md +0 -0
  20. data/Rakefile +0 -0
  21. data/exe/greeenboii +1 -1
  22. data/ext/greeenboii/extconf.rb +0 -0
  23. data/ext/greeenboii/greeenboii.c +0 -0
  24. data/ext/greeenboii/greeenboii.h +0 -0
  25. data/greeenboii_todo.db +0 -0
  26. data/lib/greeenboii/version.rb +1 -1
  27. data/lib/greeenboii.rb +16 -15
  28. data/sig/greeenboii/options.rbs +0 -0
  29. data/sig/greeenboii/search.rbs +0 -0
  30. data/sig/greeenboii/todo_list.rbs +30 -0
  31. data/sig/greeenboii.rbs +0 -0
  32. data/sorbet/config +0 -0
  33. data/sorbet/rbi/annotations/.gitattributes +0 -0
  34. data/sorbet/rbi/annotations/minitest.rbi +0 -0
  35. data/sorbet/rbi/annotations/rainbow.rbi +0 -0
  36. data/sorbet/rbi/gems/.gitattributes +1 -0
  37. data/sorbet/rbi/gems/ast@2.4.2.rbi +585 -0
  38. data/sorbet/rbi/gems/benchmark@0.4.0.rbi +618 -0
  39. data/sorbet/rbi/gems/bigdecimal@3.1.9.rbi +9 -0
  40. data/sorbet/rbi/gems/cli-ui@2.3.0.rbi +3181 -0
  41. data/sorbet/rbi/gems/console_table@0.3.1.rbi +78 -0
  42. data/sorbet/rbi/gems/csv@3.3.2.rbi +9 -0
  43. data/sorbet/rbi/gems/erubi@1.13.1.rbi +155 -0
  44. data/sorbet/rbi/gems/httparty@0.22.0.rbi +2115 -0
  45. data/sorbet/rbi/gems/json@2.10.1.rbi +2120 -0
  46. data/sorbet/rbi/gems/language_server-protocol@3.17.0.4.rbi +9 -0
  47. data/sorbet/rbi/gems/lint_roller@1.1.0.rbi +86 -0
  48. data/sorbet/rbi/gems/mini_mime@1.1.5.rbi +9 -0
  49. data/sorbet/rbi/gems/minitest@5.25.4.rbi +1547 -0
  50. data/sorbet/rbi/gems/multi_xml@0.7.1.rbi +9 -0
  51. data/sorbet/rbi/gems/netrc@0.11.0.rbi +159 -0
  52. data/sorbet/rbi/gems/nokogiri@1.18.3.rbi +8205 -0
  53. data/sorbet/rbi/gems/parallel@1.26.3.rbi +291 -0
  54. data/sorbet/rbi/gems/parser@3.3.7.1.rbi +5525 -0
  55. data/sorbet/rbi/gems/prism@1.3.0.rbi +41403 -0
  56. data/sorbet/rbi/gems/racc@1.8.1.rbi +164 -0
  57. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +403 -0
  58. data/sorbet/rbi/gems/rake-compiler@1.2.9.rbi +9 -0
  59. data/sorbet/rbi/gems/rake@13.2.1.rbi +3028 -0
  60. data/sorbet/rbi/gems/rbi@0.2.4.rbi +4542 -0
  61. data/sorbet/rbi/gems/regexp_parser@2.10.0.rbi +3795 -0
  62. data/sorbet/rbi/gems/rubocop-ast@1.38.0.rbi +7654 -0
  63. data/sorbet/rbi/gems/rubocop@1.72.2.rbi +61026 -0
  64. data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1318 -0
  65. data/sorbet/rbi/gems/spoom@1.5.4.rbi +5026 -0
  66. data/sorbet/rbi/gems/sqlite3@2.6.0.rbi +1895 -0
  67. data/sorbet/rbi/gems/tapioca@0.16.11.rbi +3656 -0
  68. data/sorbet/rbi/gems/thor@1.3.2.rbi +4378 -0
  69. data/sorbet/rbi/gems/unicode-display_width@3.1.4.rbi +132 -0
  70. data/sorbet/rbi/gems/unicode-emoji@4.0.4.rbi +251 -0
  71. data/sorbet/rbi/gems/yard-sorbet@0.9.0.rbi +435 -0
  72. data/sorbet/rbi/gems/yard@0.9.37.rbi +18379 -0
  73. data/sorbet/tapioca/config.yml +0 -0
  74. data/sorbet/tapioca/require.rb +6 -0
  75. data/src/main.c +0 -0
  76. metadata +47 -11
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 1032461384e80da2ac012ecae78e755cca153986a41f95cb96939a39e03ee144
4
- data.tar.gz: 2e8277cc9703fd090e641a5b26c39ce1625eb521faf92b28f4d4c0d958fa851e
3
+ metadata.gz: 516633c110835301e4bc5845b8d9fbebb04396c5dcc60c6a89efd47341141de0
4
+ data.tar.gz: fa651e7d04963a8100718f8403d4807bc4258c69d77afc22565d0c7000900121
5
5
  SHA512:
6
- metadata.gz: 80e18f5503fd985fe8925c8fee6f3456687d56d8649d2ddd5045069543c50cb9752a61d8138aa7669185ce1246819566d81ecaa4b5629cf621725ba16d705e04
7
- data.tar.gz: ad153530aedfb2a5133ba680e1ffe882dff1f12be293f44d878ffcdb89e25092c37a694b9a021a34baf9f8d290bdb667ea89d2bbb0fd5ea479b93ea3cc9e88e8
6
+ metadata.gz: d163e0ce96977ac3fac8671cea5582be83ffd918a079288bdc6d6917aa7a69a2cc14e9815a3533ea8e55121efec2ae038257ee78cf8b00385654f30277e7040c
7
+ data.tar.gz: ec02be37b160f5f7c90fee7c157292c1b12416ce091f4fae707420eec4eeabcfa926ce1a5f7875b2c27951c18a6bca58f853e2b88206d0c1fc60a4bc41ee2a1f
File without changes
File without changes
data/.idea/greeenboii.iml CHANGED
File without changes
File without changes
data/.idea/modules.xml CHANGED
File without changes
File without changes
data/.idea/vcs.xml CHANGED
File without changes
data/.idea/workspace.xml CHANGED
@@ -4,14 +4,7 @@
4
4
  <option name="autoReloadType" value="SELECTIVE" />
5
5
  </component>
6
6
  <component name="ChangeListManager">
7
- <list default="true" id="0fa98f61-8369-4575-be76-5316c7df88b7" name="Changes" comment="Add Makefile and main.c for greeenboii module initialization">
8
- <change beforePath="$PROJECT_DIR$/.idea/greeenboii.iml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/greeenboii.iml" afterDir="false" />
9
- <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
10
- <change beforePath="$PROJECT_DIR$/Gemfile" beforeDir="false" afterPath="$PROJECT_DIR$/Gemfile" afterDir="false" />
11
- <change beforePath="$PROJECT_DIR$/Gemfile.lock" beforeDir="false" afterPath="$PROJECT_DIR$/Gemfile.lock" afterDir="false" />
12
- <change beforePath="$PROJECT_DIR$/lib/greeenboii.rb" beforeDir="false" afterPath="$PROJECT_DIR$/lib/greeenboii.rb" afterDir="false" />
13
- <change beforePath="$PROJECT_DIR$/lib/greeenboii/version.rb" beforeDir="false" afterPath="$PROJECT_DIR$/lib/greeenboii/version.rb" afterDir="false" />
14
- </list>
7
+ <list default="true" id="0fa98f61-8369-4575-be76-5316c7df88b7" name="Changes" comment="Add RuboCop configuration for Sorbet and update gem dependencies" />
15
8
  <option name="SHOW_DIALOG" value="false" />
16
9
  <option name="HIGHLIGHT_CONFLICTS" value="true" />
17
10
  <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
@@ -47,28 +40,28 @@
47
40
  <option name="hideEmptyMiddlePackages" value="true" />
48
41
  <option name="showLibraryContents" value="true" />
49
42
  </component>
50
- <component name="PropertiesComponent"><![CDATA[{
51
- "keyToString": {
52
- "Ruby.greeenboii.executor": "Run",
53
- "RunOnceActivity.ShowReadmeOnStart": "true",
54
- "RunOnceActivity.git.unshallow": "true",
55
- "git-widget-placeholder": "main",
56
- "last_opened_file_path": "C:/Users/suvan/Downloads/cli-kit-example-main-yee/cli-kit-example-main",
57
- "node.js.detected.package.eslint": "true",
58
- "node.js.detected.package.tslint": "true",
59
- "node.js.selected.package.eslint": "(autodetect)",
60
- "node.js.selected.package.tslint": "(autodetect)",
61
- "nodejs_package_manager_path": "npm",
62
- "ruby.structure.view.model.defaults.configured": "true",
63
- "settings.editor.selected.configurable": "preferences.pluginManager",
64
- "vue.rearranger.settings.migration": "true"
43
+ <component name="PropertiesComponent">{
44
+ &quot;keyToString&quot;: {
45
+ &quot;Ruby.greeenboii.executor&quot;: &quot;Run&quot;,
46
+ &quot;RunOnceActivity.ShowReadmeOnStart&quot;: &quot;true&quot;,
47
+ &quot;RunOnceActivity.git.unshallow&quot;: &quot;true&quot;,
48
+ &quot;git-widget-placeholder&quot;: &quot;main&quot;,
49
+ &quot;last_opened_file_path&quot;: &quot;C:/Users/suvan/Downloads/cli-kit-example-main-yee/cli-kit-example-main&quot;,
50
+ &quot;node.js.detected.package.eslint&quot;: &quot;true&quot;,
51
+ &quot;node.js.detected.package.tslint&quot;: &quot;true&quot;,
52
+ &quot;node.js.selected.package.eslint&quot;: &quot;(autodetect)&quot;,
53
+ &quot;node.js.selected.package.tslint&quot;: &quot;(autodetect)&quot;,
54
+ &quot;nodejs_package_manager_path&quot;: &quot;npm&quot;,
55
+ &quot;ruby.structure.view.model.defaults.configured&quot;: &quot;true&quot;,
56
+ &quot;settings.editor.selected.configurable&quot;: &quot;preferences.pluginManager&quot;,
57
+ &quot;vue.rearranger.settings.migration&quot;: &quot;true&quot;
65
58
  },
66
- "keyToStringList": {
67
- "DatabaseDriversLRU": [
68
- "sqlite"
59
+ &quot;keyToStringList&quot;: {
60
+ &quot;DatabaseDriversLRU&quot;: [
61
+ &quot;sqlite&quot;
69
62
  ]
70
63
  }
71
- }]]></component>
64
+ }</component>
72
65
  <component name="SharedIndexes">
73
66
  <attachedChunks>
74
67
  <set>
@@ -86,7 +79,9 @@
86
79
  <option name="presentableId" value="Default" />
87
80
  <updated>1740310037191</updated>
88
81
  <workItem from="1740310038341" duration="13422000" />
89
- <workItem from="1740370363540" duration="1662000" />
82
+ <workItem from="1740370363540" duration="1955000" />
83
+ <workItem from="1740374525187" duration="497000" />
84
+ <workItem from="1740375046749" duration="1249000" />
90
85
  </task>
91
86
  <task id="LOCAL-00001" summary="update branch for push events from master to production">
92
87
  <option name="closed" value="true" />
@@ -120,7 +115,15 @@
120
115
  <option name="project" value="LOCAL" />
121
116
  <updated>1740333983898</updated>
122
117
  </task>
123
- <option name="localTasksCounter" value="5" />
118
+ <task id="LOCAL-00005" summary="Add RuboCop configuration for Sorbet and update gem dependencies">
119
+ <option name="closed" value="true" />
120
+ <created>1740375460765</created>
121
+ <option name="number" value="00005" />
122
+ <option name="presentableId" value="LOCAL-00005" />
123
+ <option name="project" value="LOCAL" />
124
+ <updated>1740375460765</updated>
125
+ </task>
126
+ <option name="localTasksCounter" value="6" />
124
127
  <servers />
125
128
  </component>
126
129
  <component name="TypeScriptGeneratedFilesManager">
@@ -131,7 +134,8 @@
131
134
  <MESSAGE value="Add RBS classes for Error, Options, and Search modules" />
132
135
  <MESSAGE value="Add cli-ui gem dependency and update version to 0.1.2" />
133
136
  <MESSAGE value="Add Makefile and main.c for greeenboii module initialization" />
134
- <option name="LAST_COMMIT_MESSAGE" value="Add Makefile and main.c for greeenboii module initialization" />
137
+ <MESSAGE value="Add RuboCop configuration for Sorbet and update gem dependencies" />
138
+ <option name="LAST_COMMIT_MESSAGE" value="Add RuboCop configuration for Sorbet and update gem dependencies" />
135
139
  </component>
136
140
  <component name="com.intellij.coverage.CoverageDataManagerImpl">
137
141
  <SUITE FILE_PATH="coverage/greeenboii@greeenboii.rcov" NAME="greeenboii Coverage Results" MODIFIED="1740333917319" SOURCE_PROVIDER="com.intellij.coverage.DefaultCoverageFileProvider" RUNNER="rcov" COVERAGE_BY_TEST_ENABLED="false" COVERAGE_TRACING_ENABLED="false" WORKING_DIRECTORY="$PROJECT_DIR$" MODULE_NAME="greeenboii" />
@@ -0,0 +1,5 @@
1
+ Sorbet:
2
+ Enabled: true
3
+
4
+ Sorbet/ValidSigil:
5
+ Enabled: true
data/.rubocop.yml CHANGED
@@ -2,6 +2,42 @@ AllCops:
2
2
  TargetRubyVersion: 3.1
3
3
  NewCops: enable
4
4
 
5
+
6
+ Style/FrozenStringLiteralComment:
7
+ Enabled: false
8
+
9
+ # This doesn't understand that <<~ doesn't exist in 2.0
10
+ Layout/HeredocIndentation:
11
+ Enabled: false
12
+
13
+ # This doesn't take into account retrying from an exception
14
+ Lint/SuppressedException:
15
+ Enabled: false
16
+
17
+ # allow String.new to create mutable strings
18
+ Style/EmptyLiteral:
19
+ Enabled: false
20
+
21
+ # allow the use of globals which makes sense in a CLI app like this
22
+ Style/GlobalVars:
23
+ Enabled: false
24
+
25
+ # allow using %r{} for regexes
26
+ Style/RegexpLiteral:
27
+ Enabled: false
28
+
29
+ # allow readable Dev::Util.begin formatting
30
+ Style/MultilineBlockChain:
31
+ Enabled: false
32
+
33
+ # we prefer rescue to align with the beginning of the line containing begin, not begin itself
34
+ Layout/RescueEnsureAlignment:
35
+ Enabled: false
36
+
37
+ # We heavily manage output on purpose
38
+ Style/GlobalStdStream:
39
+ Enabled: false
40
+
5
41
  Style/StringLiterals:
6
42
  EnforcedStyle: double_quotes
7
43
 
data/CHANGELOG.md CHANGED
File without changes
data/CODE_OF_CONDUCT.md CHANGED
File without changes
data/CONTRIBUTING.md CHANGED
File without changes
data/LICENSE.txt CHANGED
File without changes
data/Makefile CHANGED
File without changes
data/README.md CHANGED
File without changes
data/Rakefile CHANGED
File without changes
data/exe/greeenboii CHANGED
@@ -1,4 +1,4 @@
1
1
  #!/usr/bin/env ruby
2
2
  # frozen_string_literal: true
3
3
 
4
- require_relative '../lib/greeenboii'
4
+ require_relative "../lib/greeenboii"
File without changes
File without changes
File without changes
data/greeenboii_todo.db CHANGED
File without changes
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Greeenboii
4
- VERSION = "0.1.5"
4
+ VERSION = "0.1.6"
5
5
  end
data/lib/greeenboii.rb CHANGED
@@ -70,7 +70,7 @@ module Greeenboii
70
70
 
71
71
  title = result.css("h3").text.strip
72
72
  url = link["href"]
73
- snippet = result.css(".VwiC3b").text.strip
73
+ result.css(".VwiC3b").text.strip
74
74
 
75
75
  puts "Debug: Found Google result - Title: #{title}"
76
76
  results << url if url.start_with?("http")
@@ -100,6 +100,7 @@ module Greeenboii
100
100
  puts "Debug: Total results found: #{results.length}"
101
101
  results.take(8)
102
102
  end
103
+
103
104
  def self.display_results(results)
104
105
  CLI::UI.frame_style = :bracket
105
106
  CLI::UI::Frame.open(CLI::UI.fmt("{{green:Search Results}}")) do
@@ -121,13 +122,13 @@ module Greeenboii
121
122
  private def setup_database
122
123
  db = SQLite3::Database.new("greeenboii_todo.db")
123
124
  db.execute <<~SQL
124
- CREATE TABLE IF NOT EXISTS todos (
125
- id INTEGER PRIMARY KEY,
126
- title TEXT NOT NULL,
127
- completed BOOLEAN DEFAULT 0,
128
- created_at DATETIME DEFAULT CURRENT_TIMESTAMP
129
- )
130
- SQL
125
+ CREATE TABLE IF NOT EXISTS todos (
126
+ id INTEGER PRIMARY KEY,
127
+ title TEXT NOT NULL,
128
+ completed BOOLEAN DEFAULT 0,
129
+ created_at DATETIME DEFAULT CURRENT_TIMESTAMP
130
+ )
131
+ SQL
131
132
  db
132
133
  end
133
134
 
@@ -185,7 +186,7 @@ module Greeenboii
185
186
  end
186
187
 
187
188
  def show_menu
188
- CLI::UI::Frame.divider('{{v}} Todo List')
189
+ CLI::UI::Frame.divider("{{v}} Todo List")
189
190
  loop do
190
191
  CLI::UI::Prompt.ask("Todo List Options:") do |handler|
191
192
  handler.option("List Tasks") { list_tasks }
@@ -204,12 +205,12 @@ module Greeenboii
204
205
  CLI::UI::Prompt.instructions_color = CLI::UI::Color::GRAY
205
206
 
206
207
  CLI::UI::Prompt.ask("Choose an option:") do |handler|
207
- handler.option("{{gray:Search Files}}") { |selection| puts "Placeholder, Replaced soon. #{selection}" }
208
- handler.option("{{gray:Search Directory}}") { |selection| puts "Placeholder, Replaced soon. #{selection}" }
209
- handler.option("{{gray:Search Content}}") { |selection| puts "Placeholder, Replaced soon. #{selection}" }
210
- handler.option("{{yellow:Todo List}}") { |_selection| TodoList.new.show_menu }
211
- handler.option("{{cyan:Search Engine}}") { |_selection| Search.perform_search }
212
- handler.option("{{red:Exit}}") { |_selection| exit }
208
+ handler.option("{{gray:Search Files}}") { |selection| puts "Placeholder, Replaced soon. #{selection}" }
209
+ handler.option("{{gray:Search Directory}}") { |selection| puts "Placeholder, Replaced soon. #{selection}" }
210
+ handler.option("{{gray:Search Content}}") { |selection| puts "Placeholder, Replaced soon. #{selection}" }
211
+ handler.option("{{yellow:Todo List}}") { |_selection| TodoList.new.show_menu }
212
+ handler.option("{{cyan:Search Engine}}") { |_selection| Search.perform_search }
213
+ handler.option("{{red:Exit}}") { |_selection| exit }
213
214
  end
214
215
  end
215
216
  end
File without changes
File without changes
@@ -0,0 +1,30 @@
1
+ module SQLite3
2
+ class Database
3
+ def initialize: (String) -> void
4
+ def execute: (String, ?Array[untyped]) -> Array[Array[untyped]]
5
+ end
6
+ end
7
+
8
+ module Greeenboii
9
+ class TodoList
10
+ @db: SQLite3::Database
11
+
12
+ def initialize: -> void
13
+
14
+ def add_task: -> (nil | untyped)
15
+
16
+ def list_tasks: -> (nil | Array[Array[untyped]])
17
+
18
+ def mark_done: -> (nil | untyped)
19
+
20
+ def delete_task: -> (nil | untyped)
21
+
22
+ def update_task: -> (nil | untyped)
23
+
24
+ def show_menu: -> nil
25
+
26
+ private
27
+
28
+ def setup_database: -> SQLite3::Database
29
+ end
30
+ end
data/sig/greeenboii.rbs CHANGED
File without changes
data/sorbet/config CHANGED
File without changes
File without changes
File without changes
File without changes
@@ -0,0 +1 @@
1
+ **/*.rbi linguist-generated=true