gloo 3.4.0 → 3.4.1

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: 34119d3b6c3fc676b45d7172a6300e1bef50e7bfd480ecaaeab9ad39be040cc4
4
- data.tar.gz: b812253883e7589dea4b6588b85661a1cf6e849a61e2c36a658be8279a0a6411
3
+ metadata.gz: ac56d6b0d2298092e23e0bf352b6b5c77bfbf0d231b060003a404bc8e313e269
4
+ data.tar.gz: 9524d5e521c258dd5922c49c3c8dfcef2c52f57d0dff02306bfdb5ed3f1d0baa
5
5
  SHA512:
6
- metadata.gz: 33d90fe0f4135042d0d5d6cfa4323438183e43e034ce525542bff0aa34bd16baf703ed7819de51c5ad19b38dd51fec8423a4999179e08e41e0dbc89ad0f3d20c
7
- data.tar.gz: 017e592805017fc75f776a9a1673eb50aba32ef227260c573f382e8dc83d067ac2429b1f18d722df22672b8f7c57cd941769180d517398db74cde98aeb56a64d
6
+ metadata.gz: c6e81f7c12f73b7736c79be525c23a300b231fbb76884490ef1b0b87ff85f3e85533ef708edb4b1044d99e443b7fb0df3f39551dce69b6d6dd91a3d2692dc472
7
+ data.tar.gz: 3c50b4ffba3590217bcd2641a190e196a472620321a5f23eeb07d8e5cf24d19ba81d675497143bf44ea4c389d308ae65446ceee8be50037e5dbbc26c13cfad8f
data/lib/VERSION CHANGED
@@ -1 +1 @@
1
- 3.4.0
1
+ 3.4.1
data/lib/VERSION_NOTES CHANGED
@@ -1,3 +1,8 @@
1
+ 3.4.1 - 2024.09.23
2
+ - Removes old, unused sound objects
3
+ - Adds support for lib folder in gloo rather than in the project folder
4
+
5
+
1
6
  3.4.0 - 2024.09.22
2
7
  - Refactor for old TTY lib
3
8
  - Additional web server functionality
@@ -17,6 +17,7 @@ module Gloo
17
17
  #
18
18
  def initialize( engine )
19
19
  @engine = engine
20
+ @log = @engine.log
20
21
  end
21
22
 
22
23
  #
@@ -32,6 +33,13 @@ module Gloo
32
33
  def get_all_files_in( folder )
33
34
  pns = []
34
35
  dir = File.join( @engine.settings.project_path, folder )
36
+
37
+ unless Dir.exist?( dir )
38
+ @log.debug "Folder does not exist in project: #{folder}"
39
+ dir = File.join( @engine.settings.user_root, folder )
40
+ @log.debug "Looking in gloo home? found == #{Dir.exist?( dir )}"
41
+ end
42
+
35
43
  Dir.glob( "#{dir}*.gloo" ).each do |f|
36
44
  pns << f
37
45
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gloo
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.4.0
4
+ version: 3.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Crane
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2024-09-22 00:00:00.000000000 Z
11
+ date: 2024-09-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -458,8 +458,6 @@ files:
458
458
  - lib/gloo/objs/ror/eval.rb
459
459
  - lib/gloo/objs/security/cipher.rb
460
460
  - lib/gloo/objs/security/password.rb
461
- - lib/gloo/objs/snd/play.rb
462
- - lib/gloo/objs/snd/say.rb
463
461
  - lib/gloo/objs/system/file_handle.rb
464
462
  - lib/gloo/objs/system/ssh_exec.rb
465
463
  - lib/gloo/objs/system/system.rb
@@ -1,48 +0,0 @@
1
- # Author:: Eric Crane (mailto:eric.crane@mac.com)
2
- # Copyright:: Copyright (c) 2020 Eric Crane. All rights reserved.
3
- #
4
- # Play an audio file (MP3).
5
- #
6
-
7
- module Gloo
8
- module Objs
9
- class Play < Gloo::Core::Obj
10
-
11
- KEYWORD = 'play'.freeze
12
- KEYWORD_SHORT = 'play'.freeze
13
-
14
- #
15
- # The name of the object type.
16
- #
17
- def self.typename
18
- return KEYWORD
19
- end
20
-
21
- #
22
- # The short name of the object type.
23
- #
24
- def self.short_typename
25
- return KEYWORD_SHORT
26
- end
27
-
28
- # ---------------------------------------------------------------------
29
- # Messages
30
- # ---------------------------------------------------------------------
31
-
32
- #
33
- # Get a list of message names that this object receives.
34
- #
35
- def self.messages
36
- return super + [ 'run' ]
37
- end
38
-
39
- #
40
- # Play the audio file.
41
- #
42
- def msg_run
43
- system "afplay #{value}"
44
- end
45
-
46
- end
47
- end
48
- end
@@ -1,98 +0,0 @@
1
- # Author:: Eric Crane (mailto:eric.crane@mac.com)
2
- # Copyright:: Copyright (c) 2020 Eric Crane. All rights reserved.
3
- #
4
- # Wrapper for the 'say something' function on the Mac.
5
- #
6
- require 'erb'
7
-
8
- module Gloo
9
- module Objs
10
- class Say < Gloo::Core::Obj
11
-
12
- KEYWORD = 'say'.freeze
13
- KEYWORD_SHORT = 'say'.freeze
14
- VOICE = 'voice'.freeze
15
- MSG = 'message'.freeze
16
- DEFAULT_MSG = 'talk to me'.freeze
17
-
18
- #
19
- # The name of the object type.
20
- #
21
- def self.typename
22
- return KEYWORD
23
- end
24
-
25
- #
26
- # The short name of the object type.
27
- #
28
- def self.short_typename
29
- return KEYWORD_SHORT
30
- end
31
-
32
- #
33
- # Get the voice to use.
34
- #
35
- def voice_value
36
- v = find_child VOICE
37
- return nil unless v
38
-
39
- return v.value
40
- end
41
-
42
- #
43
- # Get the message to speak.
44
- #
45
- def msg_value
46
- o = find_child MSG
47
- return nil unless o
48
-
49
- return o.value
50
- end
51
-
52
- # ---------------------------------------------------------------------
53
- # Children
54
- # ---------------------------------------------------------------------
55
-
56
- #
57
- # Does this object have children to add when an object
58
- # is created in interactive mode?
59
- # This does not apply during obj load, etc.
60
- #
61
- def add_children_on_create?
62
- return true
63
- end
64
-
65
- #
66
- # Add children to this object.
67
- # This is used by containers to add children needed
68
- # for default configurations.
69
- #
70
- def add_default_children
71
- fac = @engine.factory
72
- fac.create_string VOICE, '', self
73
- fac.create_string MSG, DEFAULT_MSG, self
74
- end
75
-
76
- # ---------------------------------------------------------------------
77
- # Messages
78
- # ---------------------------------------------------------------------
79
-
80
- #
81
- # Get a list of message names that this object receives.
82
- #
83
- def self.messages
84
- return super + [ 'run' ]
85
- end
86
-
87
- #
88
- # Have the computer 'speak' the message.
89
- #
90
- def msg_run
91
- v = voice_value.empty? ? '' : "-v '#{voice_value}'"
92
- cmd = "say #{v} '#{msg_value}'"
93
- system cmd
94
- end
95
-
96
- end
97
- end
98
- end