arxutils_sqlite3 0.1.52 → 0.1.53

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: 3d69eb5d028ba88688de072f5c46ef3405f11b86039d35b6333dbe2738d5cda5
4
- data.tar.gz: 323f8f287e6931e7c8409d6bf66084f85b52b905c9b45a55fb90fc4ff779d92d
3
+ metadata.gz: bd619405f651016b19a09bb7dc65fe14eed439e25a419a24784774c3675f88a7
4
+ data.tar.gz: 2abf287f96ca75b75a41da86d74bf9269acb76ac380f7c55f9668093a4d4ccad
5
5
  SHA512:
6
- metadata.gz: ab32ab27f8f923710ae2773ea03013503970fcf77ba35e51e7783081a47d7a336d7cb0e8d165dd8c5cedba4de07a39da48ee057b1b22630eca32e80d850b3ce2
7
- data.tar.gz: f0ec4c6c217a4eb9c045a64529ca8028b6486ad4255ab34140c6cab8f0a733691a26b2e8204da0d5247925bec592114664afa30967333ae2c7588d9e87fae49f
6
+ metadata.gz: 23faf1f7084d060cf94778f3fcaeb4a3f2fd5f55d40607dd3133a032549140b30f02a50c65a2319a696c5324c4752dfa48e35041e90e3e4be3250c6d1d4ba37e
7
+ data.tar.gz: 662f292981fb7e3749c90d11f5ef29122491bff8b37b83dc0b03f66cf73f81db178179d3c41a1a24c82066181f6c2e772cdb4101aae8fb7ef79167f00696de3a
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- arxutils_sqlite3 (0.1.52)
4
+ arxutils_sqlite3 (0.1.53)
5
5
  activerecord (~> 6.1)
6
6
  activesupport
7
7
  simpleoptparse
@@ -59,6 +59,11 @@ module Arxutils_Sqlite3
59
59
  MIGRATE_DIR = DB_PN.join(MIGRATE_BASE_DIR)
60
60
 
61
61
  EXCLUDE_FILES = %w[SETTING_YAML_FILE_NAME].freeze
62
+ DEFAULT_KLASS = "Enop"
63
+
64
+ def default_klass
65
+ DEFAULT_KLASS
66
+ end
62
67
 
63
68
  # DB構成ファイル格納ディレクトリの作成
64
69
  def make_config_directory
@@ -5,64 +5,67 @@ config = Arxutils_Sqlite3::Config.new
5
5
  klass = nil
6
6
  setting = config.load_setting_yaml_file
7
7
  klass = setting[:klass]
8
+ klass = config.default_klass if klass.nil?
8
9
 
9
10
  desc "setup copy_db_scheme copy_opts makeconfig make_migrate_script migrate acr"
10
- task arxutils_sqlite3: %w[setup copy_db_scheme copy_opts makeconfig make_migrate_script migrate acr]
11
+ task arxutils_sqlite3: %w[arx:setup arx:copy_db_scheme arx:copy_opts arx:makeconfig arx:make_migrate_script arx:migrate arx:acr]
11
12
 
12
13
  desc "delete setup copy_db_scheme copy_opts makeconfig make_migrate_script migrate acr"
13
- task bootstrap: %w[delete arxutils_sqlite3]
14
+ task "arx:bootstrap": %w[arx:delete arxutils_sqlite3]
14
15
 
15
16
  desc "migrate acr"
16
- task ma: %w[migrate acr]
17
+ task "arx:ma": %w[arx:migrate arx:acr]
17
18
 
18
19
  desc "delete_db"
19
- task b: %w[delete_db]
20
+ task "arx:b": %w[arx:delete_db]
20
21
 
21
22
  # コマンドラインで指定したクラス名を含むオプション指定用ハッシュの定義を含むRubyスクリ
22
23
  # プトファイルの生成
23
24
  desc "produce setting.yml, db_scheme.yml.sample and opts.rb.sample with class name #{klass}"
24
- task :setup do
25
+ task "arx:setup" do
25
26
  sh "bundle exec arxutils_sqlite3 --cmd=s --klass=#{klass}"
26
27
  end
27
28
 
28
29
  desc "copy from db_scheme.yml.sample to db_scheme.yml"
29
- task :copy_db_scheme do
30
+ task "arx:copy_db_scheme" do
30
31
  sh "bundle exec arxutils_sqlite3 --cmd=cds"
31
32
  end
32
33
 
33
34
  desc "copy from opts.rb.sample to opts.rb"
34
- task :copy_opts do
35
+ task "arx:copy_opts" do
35
36
  sh "bundle exec arxutils_sqlite3 --cmd=co"
36
37
  end
37
38
 
38
39
  # DB構成情報の生成
39
40
  desc "produce sqlite3.yml"
40
- task :makeconfig do
41
+ task "arx:makeconfig" do
41
42
  sh "bundle exec arxutils_sqlite3 --cmd=c"
42
43
  end
43
44
 
44
45
  # マイグレート用スクリプトファイルの生成
45
46
  desc "produce migration scripts"
46
- task :make_migrate_script do
47
+ task "arx:make_migrate_script" do
47
48
  sh "bundle exec arxutils_sqlite3 --cmd=f --yaml=config/db_scheme.yml"
48
49
  end
49
50
  # マイグレートの実行
50
51
  desc "execute migration"
51
- task :migrate do
52
+ task "arx:migrate" do
52
53
  sh "bundle exec arxutils_sqlite3 --cmd=m"
53
54
  end
54
55
 
55
56
  desc "call ActiveRecord instance method"
56
- task :acr do
57
+ task "arx:acr" do
57
58
  sh "bundle exec arxutils_sqlite3 --cmd=a"
58
59
  end
59
60
 
60
61
  desc "delete configuration files adn migration scripts and db files"
61
- task :delete do
62
+ task "arx:delete" do
62
63
  sh "bundle exec arxutils_sqlite3 --cmd=d"
63
64
  end
64
65
 
65
66
  desc "delete db files"
66
- task :delete_db do
67
+ task "arx:delete_db" do
67
68
  sh "bundle exec arxutils_sqlite3 --cmd=b"
68
69
  end
70
+
71
+
@@ -1,4 +1,4 @@
1
1
  module Arxutils_Sqlite3
2
2
  # バージョン番号
3
- VERSION = "0.1.52".freeze
3
+ VERSION = "0.1.53".freeze
4
4
  end
data/lib/dbacrecord.rb CHANGED
@@ -1,25 +1,25 @@
1
1
  module Enop
2
2
  module Dbutil
3
3
  class Count < ActiveRecord::Base
4
- has_many :invalidennblists
4
+ has_many :invalidxennblists
5
5
  end
6
6
 
7
7
  class Countdatetime < ActiveRecord::Base
8
8
  end
9
9
 
10
- class Evnb < ActiveRecord::Base
10
+ class Xevnb < ActiveRecord::Base
11
11
  end
12
12
 
13
- class Ennblist < ActiveRecord::Base
13
+ class Xennblist < ActiveRecord::Base
14
14
  end
15
15
 
16
- class Invalidennblist < ActiveRecord::Base
17
- belongs_to :ennblist , foreign_key: 'org_id'
16
+ class Invalidxennblist < ActiveRecord::Base
17
+ belongs_to :xennblist , foreign_key: 'org_id'
18
18
  belongs_to :count , foreign_key: ''
19
19
  end
20
20
 
21
- class Currentennblist < ActiveRecord::Base
22
- belongs_to :ennblist , foreign_key: 'org_id'
21
+ class Currentxennblist < ActiveRecord::Base
22
+ belongs_to :xennblist , foreign_key: 'org_id'
23
23
  end
24
24
 
25
25
  end
@@ -11,8 +11,8 @@
11
11
  :ar_version: 6.0
12
12
  - :flist:
13
13
  - noitem
14
- :classname: Evnb
15
- :classname_downcase: evnb
14
+ :classname: Xevnb
15
+ :classname_downcase: xevnb
16
16
  :items:
17
17
  - - time_id
18
18
  - integer
@@ -20,14 +20,14 @@
20
20
  - - ennb_id
21
21
  - integer
22
22
  - 'false'
23
- :plural: evnbs
23
+ :plural: xevnbs
24
24
  :ar_version: 6.0
25
25
  - :flist:
26
26
  - noitem
27
27
  - invalid
28
28
  - current
29
- :classname: Ennblist
30
- :classname_downcase: ennblist
29
+ :classname: Xennblist
30
+ :classname_downcase: xennblist
31
31
  :items:
32
32
  - - stack
33
33
  - string
@@ -44,5 +44,5 @@
44
44
  - - start_datetime
45
45
  - datetime
46
46
  - 'false'
47
- :plural: ennblists
47
+ :plural: xennblists
48
48
  :ar_version: 6.0
@@ -1,3 +1,5 @@
1
+ require_relative '../lib/dbacrecord'
2
+
1
3
  class Dbsetup
2
4
  def initialize(connect_time)
3
5
  @connect_time = connect_time
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: arxutils_sqlite3
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.52
4
+ version: 0.1.53
5
5
  platform: ruby
6
6
  authors:
7
7
  - yasuo kominami
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-09-15 00:00:00.000000000 Z
11
+ date: 2022-09-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport