geordi 12.1.0 → 12.1.1

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: 8b0ad63b0055ae689422b0aab1ccbf95093e010448e609ba98dec160d32120bb
4
- data.tar.gz: bcf3cc151f954a1bc92301b1badc3ce4ccf607a5731b971789b66567cb4b620d
3
+ metadata.gz: 04313c8ce7c7ad6e748f4b75a35deb5e888c66bbbc1070e1213677b610c971f1
4
+ data.tar.gz: 210726dbce934e3d0db120b4f7a5aa2eba7bbb4d4056868e8e083eadcbec02c2
5
5
  SHA512:
6
- metadata.gz: 0ad4cd385ff82debfbc9cc1efc5475142e2bbe88c6af52925ef681a45679bf51faadbd995bb2cd500118c732187cd8190bd585f6d1ed0315f79a9cccac7c109f
7
- data.tar.gz: 60e6c101c9eed979a55150f4b2c0e2dcc3566e949f168eb921b30ab0dd939c458fecb7349abe4e4f6185deb7eab4a35a9273b92437733132fd4cb23de8ab3d80
6
+ metadata.gz: a52a0c665afd173e9371cad4fa64a65dc3fea587f9c415f376aa3706799b222e55917a8e47ad0e4a8d71b78e35c0ed2b5115cc0f0ef95a9c720e1de25b51d809
7
+ data.tar.gz: 00c8b800c1ea5b89e63e178c26448a93db8de1cb566ddf324facfb99ede4df107e19100eeee0bf42fac1c4db5d8e7c6d43a919bd4e6015d5481ecfdb22587c5d
@@ -8,7 +8,7 @@ on:
8
8
  - master
9
9
  jobs:
10
10
  test:
11
- runs-on: ubuntu-20.04
11
+ runs-on: ubuntu-24.04
12
12
  strategy:
13
13
  fail-fast: false
14
14
  matrix:
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- geordi (12.1.0)
4
+ geordi (12.1.1)
5
5
  thor (~> 1)
6
6
 
7
7
  GEM
@@ -29,6 +29,7 @@ module Geordi
29
29
  end
30
30
  @mysql_command = decide_mysql_command(extra_flags['mysql'])
31
31
  @postgres_command = decide_postgres_command(extra_flags['postgres'])
32
+ @texteditor = Geordi::Util.get_texteditor
32
33
  end
33
34
 
34
35
  def edit_allowlist(dbtype)
@@ -89,8 +90,7 @@ module Geordi
89
90
  tmp.write("#{line[0]} #{line[1]}\n")
90
91
  end
91
92
  tmp.close
92
- texteditor = Geordi::Util.decide_texteditor
93
- system("#{texteditor} #{tmp.path}")
93
+ system("#{@texteditor} #{tmp.path}")
94
94
  File.open(tmp.path, 'r') do |wl_edited|
95
95
  allowlisted_dbs = []
96
96
  allowlist_storage = File.open(allowlist, 'w')
@@ -122,7 +122,7 @@ module Geordi
122
122
  end
123
123
 
124
124
  def inquire_linear_api_key
125
- Geordi::Interaction.note 'Create an API key here: https://linear.app/makandra/settings/api'
125
+ Geordi::Interaction.note 'Create a personal API key here: https://linear.app/makandra/settings/account/security'
126
126
  token = Geordi::Interaction.prompt("Please enter the API key:")
127
127
  self.linear_api_key = token
128
128
  Interaction.note("API key stored in #{GLOBAL_SETTINGS_FILE_NAME}.")
data/lib/geordi/util.rb CHANGED
@@ -137,13 +137,12 @@ module Geordi
137
137
  end
138
138
  end
139
139
 
140
- # try to guess user's favorite cli text editor
141
- def decide_texteditor
142
- %w[/usr/bin/editor vi].each do |texteditor|
143
- if cmd_exists?(texteditor) && texteditor.start_with?('$')
144
- return ENV[texteditor[1..-1]]
145
- elsif cmd_exists? texteditor
146
- return texteditor
140
+ def get_texteditor
141
+ %w[/usr/bin/editor vi].find { |c| cmd_exists?(c) }.tap do |editor|
142
+ if editor == '/usr/bin/editor'
143
+ Interaction.note 'Choose text editor with: sudo update-alternatives --config editor'
144
+ elsif editor == nil
145
+ Interaction.fail 'Could not find a text editor.'
147
146
  end
148
147
  end
149
148
  end
@@ -1,3 +1,3 @@
1
1
  module Geordi
2
- VERSION = '12.1.0'.freeze
2
+ VERSION = '12.1.1'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: geordi
3
3
  version: !ruby/object:Gem::Version
4
- version: 12.1.0
4
+ version: 12.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Henning Koch
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-03-05 00:00:00.000000000 Z
11
+ date: 2025-05-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: thor