scout-gear 10.7.6 → 10.7.7

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: f346d283c182fbb5a090329100ad4bd32a50e7e84c058c156014ca1fd2e64772
4
- data.tar.gz: d4457afe22a81e426232ee94ddc798921fc69dfcf35a628c8ecafa39fb3a271b
3
+ metadata.gz: 27ef5b8aa113a998b4dde3d2eba3b8129e29b47b5a96af51e1bb8080d82cb671
4
+ data.tar.gz: 6e4cba134a145b426024f03d247550573f4dbf879cc600ad951a2729255ce2f3
5
5
  SHA512:
6
- metadata.gz: 27ac7e8599c5caabad5d63282c2f316404bce25d82dc0cb302acbb249c1ddb76eff171044b0f9c766e05ee582f399f4ba27076c6514bb3abab16857f11974846
7
- data.tar.gz: 475df8c7b163a30dd09d608119633443c8bfc9eec1f6bcc657e3f2116bf23a678e18f3224f8da399c6923ac222f5cc1b953dd4035f44514bff90d1ee2b1ffcb7
6
+ metadata.gz: c31507a2e82ca6d1b308661f586633f08a917dcd8b794cb7902d86e4c022f1f6ad1d4e423da0e3d8633464feeda0fd938b1e58779f72ad12e9685c67d244b4bc
7
+ data.tar.gz: 1bc95a9439b34ce670ebdbd893c79793c03d339c49b4e7e6877b24dd18e05f189875e95779e8bc3caea9abd3fb8491ec73888c74a03ffb1a859c7d35e397a0c9
data/.vimproject CHANGED
@@ -170,6 +170,7 @@ scout-gear=/$PWD filter="*.rb *.yaml" {
170
170
  }
171
171
  resource=resource{
172
172
  produce
173
+ sync
173
174
  }
174
175
  }
175
176
  test=test {
data/VERSION CHANGED
@@ -1 +1 @@
1
- 10.7.6
1
+ 10.7.7
@@ -75,17 +75,17 @@ module Annotation
75
75
  when Annotation.is_annotated?(objs)
76
76
  tsv.key_field = "List"
77
77
 
78
- tsv[objs.annotation_id] = self.list_tsv_values(objs, fields).dup
78
+ tsv[objs.id] = self.list_tsv_values(objs, fields).dup
79
79
  when Array === objs
80
80
  tsv.key_field = "ID"
81
81
 
82
82
  if Annotation.is_annotated?(objs.compact.first)
83
83
  objs.compact.each_with_index do |obj,i|
84
- tsv[obj.annotation_id + "#" << i.to_s] = self.obj_tsv_values(obj, fields).dup
84
+ tsv[obj.id + "#" << i.to_s] = self.obj_tsv_values(obj, fields).dup
85
85
  end
86
86
  elsif (objs.any? && Annotation.is_annotated?(objs.compact.first.compact.first))
87
87
  objs.flatten.compact.each_with_index do |obj,i|
88
- tsv[obj.annotation_id + "#" << i.to_s] = self.obj_tsv_values(obj, fields).dup
88
+ tsv[obj.id + "#" << i.to_s] = self.obj_tsv_values(obj, fields).dup
89
89
  end
90
90
  end
91
91
  else
@@ -29,7 +29,7 @@ module Workflow
29
29
  if block_given?
30
30
  helpers[name] = block
31
31
  else
32
- raise RbbtException, "helper #{name} unkown in #{self} workflow" unless helpers[name]
32
+ raise ScoutException, "helper #{name} unkown in #{self} workflow" unless helpers[name]
33
33
  o = Object.new
34
34
  o.extend step_module
35
35
  o.send(name, *args, **kwargs)
@@ -164,7 +164,7 @@ module Workflow
164
164
  type = task_proc.type
165
165
  end
166
166
  task name => type do
167
- raise RbbtException, "dep_task does not have any dependencies" if dependencies.empty?
167
+ raise ScoutException, "dep_task does not have any dependencies" if dependencies.empty?
168
168
  Step.wait_for_jobs dependencies.select{|d| d.streaming? }
169
169
  dep = dependencies.last
170
170
  dep.join
data/scout-gear.gemspec CHANGED
@@ -2,16 +2,16 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Juwelier::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: scout-gear 10.7.6 ruby lib
5
+ # stub: scout-gear 10.7.7 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "scout-gear".freeze
9
- s.version = "10.7.6".freeze
9
+ s.version = "10.7.7".freeze
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib".freeze]
13
13
  s.authors = ["Miguel Vazquez".freeze]
14
- s.date = "2025-04-08"
14
+ s.date = "2025-04-11"
15
15
  s.description = "Scout gear: workflow, TSVs, persistence, entities, associations, and knowledge_bases.".freeze
16
16
  s.email = "mikisvaz@gmail.com".freeze
17
17
  s.executables = ["scout".freeze]
@@ -143,6 +143,7 @@ Gem::Specification.new do |s|
143
143
  "scout_commands/log",
144
144
  "scout_commands/rbbt",
145
145
  "scout_commands/resource/produce",
146
+ "scout_commands/resource/sync",
146
147
  "scout_commands/template",
147
148
  "scout_commands/update",
148
149
  "scout_commands/workflow/cmd",
@@ -0,0 +1,33 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require 'scout'
4
+
5
+ $0 = "scout #{$previous_commands.any? ? $previous_commands*" " + " " : "" }#{ File.basename(__FILE__) }" if $previous_commands
6
+
7
+ options = SOPT.setup <<EOF
8
+
9
+ Sync to resources between path maps or between hosts
10
+
11
+ $ #{$0} [<options>] <path> [<path_map>]
12
+
13
+ Path map defaults to :user
14
+
15
+ -h--help Print this help
16
+ -s--source* Host of source path
17
+ -t--target* Host of target path
18
+ EOF
19
+ if options[:help]
20
+ if defined? scout_usage
21
+ scout_usage
22
+ else
23
+ puts SOPT.doc
24
+ end
25
+ exit 0
26
+ end
27
+
28
+ path, path_map = ARGV
29
+
30
+ raise MissingParameterException, :path if path.nil?
31
+
32
+ options.keys_to_sym!
33
+ Resource.sync(Path.setup(path.dup), path_map, **options)
data/test/test_helper.rb CHANGED
@@ -20,6 +20,7 @@ require 'test/unit'
20
20
  $LOAD_PATH.unshift(File.dirname(__FILE__))
21
21
  $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
22
22
  #require 'scout/helper/misc/development'
23
+ require 'scout-gear'
23
24
  require 'scout/tmpfile'
24
25
  require 'scout/log'
25
26
  require 'scout/open'
@@ -54,6 +55,7 @@ class Test::Unit::TestCase
54
55
 
55
56
  teardown do
56
57
  Open.rm_rf tmpdir
58
+ Workflow.job_cache.clear
57
59
  end
58
60
 
59
61
  def self.datadir_test
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: scout-gear
3
3
  version: !ruby/object:Gem::Version
4
- version: 10.7.6
4
+ version: 10.7.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Miguel Vazquez
8
8
  bindir: bin
9
9
  cert_chain: []
10
- date: 2025-04-08 00:00:00.000000000 Z
10
+ date: 2025-04-11 00:00:00.000000000 Z
11
11
  dependencies:
12
12
  - !ruby/object:Gem::Dependency
13
13
  name: scout-essentials
@@ -212,6 +212,7 @@ files:
212
212
  - scout_commands/log
213
213
  - scout_commands/rbbt
214
214
  - scout_commands/resource/produce
215
+ - scout_commands/resource/sync
215
216
  - scout_commands/template
216
217
  - scout_commands/update
217
218
  - scout_commands/workflow/cmd