ruby-clock 2.0.0.beta5 → 2.0.0.beta7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (195) hide show
  1. checksums.yaml +4 -4
  2. data/.gitignore +1 -1
  3. data/CHANGELOG.md +14 -7
  4. data/README.md +34 -8
  5. data/example-app/Clockfile +27 -7
  6. data/example-app/Gemfile +2 -1
  7. data/example-app/Gemfile.lock +3 -0
  8. data/example-rails-6-app/.browserslistrc +1 -0
  9. data/example-rails-6-app/.gitattributes +10 -0
  10. data/example-rails-6-app/.gitignore +40 -0
  11. data/example-rails-6-app/.ruby-version +1 -0
  12. data/{example-rails-app → example-rails-6-app}/Clockfile +1 -1
  13. data/example-rails-6-app/Gemfile +62 -0
  14. data/example-rails-6-app/Gemfile.lock +270 -0
  15. data/example-rails-6-app/README.md +24 -0
  16. data/example-rails-6-app/app/assets/config/manifest.js +2 -0
  17. data/example-rails-6-app/app/assets/stylesheets/application.css +15 -0
  18. data/example-rails-6-app/app/javascript/channels/consumer.js +6 -0
  19. data/example-rails-6-app/app/javascript/channels/index.js +5 -0
  20. data/example-rails-6-app/app/javascript/packs/application.js +13 -0
  21. data/example-rails-6-app/app/mailers/application_mailer.rb +4 -0
  22. data/example-rails-6-app/app/models/application_record.rb +3 -0
  23. data/{example-rails-app → example-rails-6-app}/app/models/example.rb +4 -4
  24. data/example-rails-6-app/app/views/layouts/application.html.erb +16 -0
  25. data/example-rails-6-app/babel.config.js +82 -0
  26. data/example-rails-6-app/bin/rails +5 -0
  27. data/example-rails-6-app/bin/rake +5 -0
  28. data/example-rails-6-app/bin/setup +36 -0
  29. data/example-rails-6-app/bin/spring +14 -0
  30. data/example-rails-6-app/bin/webpack +18 -0
  31. data/example-rails-6-app/bin/webpack-dev-server +18 -0
  32. data/example-rails-6-app/bin/yarn +17 -0
  33. data/example-rails-6-app/config/application.rb +22 -0
  34. data/example-rails-6-app/config/boot.rb +4 -0
  35. data/example-rails-6-app/config/cable.yml +10 -0
  36. data/example-rails-6-app/config/credentials.yml.enc +1 -0
  37. data/example-rails-6-app/config/database.yml +25 -0
  38. data/example-rails-6-app/config/environments/development.rb +76 -0
  39. data/example-rails-6-app/config/environments/production.rb +120 -0
  40. data/example-rails-6-app/config/environments/test.rb +60 -0
  41. data/example-rails-6-app/config/initializers/application_controller_renderer.rb +8 -0
  42. data/example-rails-6-app/config/initializers/assets.rb +14 -0
  43. data/example-rails-6-app/config/initializers/backtrace_silencers.rb +8 -0
  44. data/example-rails-6-app/config/initializers/content_security_policy.rb +30 -0
  45. data/example-rails-6-app/config/initializers/cookies_serializer.rb +5 -0
  46. data/example-rails-6-app/config/initializers/filter_parameter_logging.rb +6 -0
  47. data/example-rails-6-app/config/initializers/inflections.rb +16 -0
  48. data/example-rails-6-app/config/initializers/mime_types.rb +4 -0
  49. data/example-rails-6-app/config/initializers/wrap_parameters.rb +14 -0
  50. data/example-rails-6-app/config/locales/en.yml +33 -0
  51. data/example-rails-6-app/config/puma.rb +43 -0
  52. data/example-rails-6-app/config/routes.rb +3 -0
  53. data/example-rails-6-app/config/spring.rb +6 -0
  54. data/example-rails-6-app/config/storage.yml +34 -0
  55. data/example-rails-6-app/config/webpack/development.js +5 -0
  56. data/example-rails-6-app/config/webpack/environment.js +3 -0
  57. data/example-rails-6-app/config/webpack/production.js +5 -0
  58. data/example-rails-6-app/config/webpack/test.js +5 -0
  59. data/example-rails-6-app/config/webpacker.yml +92 -0
  60. data/example-rails-6-app/db/migrate/20221102224703_create_examples.rb +8 -0
  61. data/example-rails-6-app/db/schema.rb +20 -0
  62. data/example-rails-6-app/db/seeds.rb +7 -0
  63. data/example-rails-6-app/package.json +17 -0
  64. data/example-rails-6-app/postcss.config.js +12 -0
  65. data/example-rails-6-app/test/test_helper.rb +13 -0
  66. data/example-rails-6-app/yarn.lock +7108 -0
  67. data/example-rails-7-app/Clockfile +19 -0
  68. data/{example-rails-app → example-rails-7-app}/Gemfile +1 -1
  69. data/example-rails-7-app/Gemfile.lock +247 -0
  70. data/example-rails-7-app/Rakefile +6 -0
  71. data/example-rails-7-app/app/channels/application_cable/channel.rb +4 -0
  72. data/example-rails-7-app/app/channels/application_cable/connection.rb +4 -0
  73. data/example-rails-7-app/app/controllers/application_controller.rb +2 -0
  74. data/example-rails-7-app/app/helpers/application_helper.rb +2 -0
  75. data/example-rails-7-app/app/jobs/application_job.rb +7 -0
  76. data/example-rails-7-app/app/models/concerns/.keep +0 -0
  77. data/example-rails-7-app/app/models/example.rb +18 -0
  78. data/example-rails-7-app/app/views/layouts/mailer.html.erb +13 -0
  79. data/example-rails-7-app/app/views/layouts/mailer.text.erb +1 -0
  80. data/example-rails-7-app/bin/bundle +114 -0
  81. data/example-rails-7-app/config/environment.rb +5 -0
  82. data/example-rails-7-app/config/initializers/permissions_policy.rb +11 -0
  83. data/example-rails-7-app/config.ru +6 -0
  84. data/example-rails-7-app/lib/assets/.keep +0 -0
  85. data/example-rails-7-app/lib/tasks/.keep +0 -0
  86. data/example-rails-7-app/log/.keep +0 -0
  87. data/example-rails-7-app/public/404.html +67 -0
  88. data/example-rails-7-app/public/422.html +67 -0
  89. data/example-rails-7-app/public/500.html +66 -0
  90. data/example-rails-7-app/public/apple-touch-icon-precomposed.png +0 -0
  91. data/example-rails-7-app/public/apple-touch-icon.png +0 -0
  92. data/example-rails-7-app/public/favicon.ico +0 -0
  93. data/example-rails-7-app/public/robots.txt +1 -0
  94. data/example-rails-7-app/storage/.keep +0 -0
  95. data/example-rails-7-app/test/application_system_test_case.rb +5 -0
  96. data/example-rails-7-app/test/channels/application_cable/connection_test.rb +11 -0
  97. data/example-rails-7-app/test/controllers/.keep +0 -0
  98. data/example-rails-7-app/test/fixtures/files/.keep +0 -0
  99. data/example-rails-7-app/test/helpers/.keep +0 -0
  100. data/example-rails-7-app/test/integration/.keep +0 -0
  101. data/example-rails-7-app/test/mailers/.keep +0 -0
  102. data/example-rails-7-app/test/models/.keep +0 -0
  103. data/example-rails-7-app/test/system/.keep +0 -0
  104. data/example-rails-7-app/tmp/.keep +0 -0
  105. data/example-rails-7-app/tmp/pids/.keep +0 -0
  106. data/example-rails-7-app/tmp/storage/.keep +0 -0
  107. data/example-rails-7-app/vendor/.keep +0 -0
  108. data/example-rails-7-app/vendor/javascript/.keep +0 -0
  109. data/exe/clock +1 -0
  110. data/lib/ruby-clock/dsl.rb +16 -0
  111. data/lib/ruby-clock/shell.rb +4 -6
  112. data/lib/ruby-clock/version.rb +1 -1
  113. data/lib/ruby-clock.rb +0 -3
  114. data/lib/rufus_monkeypatch.rb +8 -1
  115. data/ruby-clock.gemspec +1 -1
  116. metadata +183 -86
  117. data/lib/ruby-clock/runners.rb +0 -23
  118. /data/{example-rails-app → example-rails-6-app}/Rakefile +0 -0
  119. /data/{example-rails-app → example-rails-6-app}/app/assets/images/.keep +0 -0
  120. /data/{example-rails-app → example-rails-6-app}/app/channels/application_cable/channel.rb +0 -0
  121. /data/{example-rails-app → example-rails-6-app}/app/channels/application_cable/connection.rb +0 -0
  122. /data/{example-rails-app → example-rails-6-app}/app/controllers/application_controller.rb +0 -0
  123. /data/{example-rails-app → example-rails-6-app}/app/controllers/concerns/.keep +0 -0
  124. /data/{example-rails-app → example-rails-6-app}/app/helpers/application_helper.rb +0 -0
  125. /data/{example-rails-app → example-rails-6-app}/app/jobs/application_job.rb +0 -0
  126. /data/{example-rails-app → example-rails-6-app}/app/models/concerns/.keep +0 -0
  127. /data/{example-rails-app → example-rails-6-app}/app/views/layouts/mailer.html.erb +0 -0
  128. /data/{example-rails-app → example-rails-6-app}/app/views/layouts/mailer.text.erb +0 -0
  129. /data/{example-rails-app → example-rails-6-app}/bin/bundle +0 -0
  130. /data/{example-rails-app → example-rails-6-app}/config/environment.rb +0 -0
  131. /data/{example-rails-app → example-rails-6-app}/config/initializers/permissions_policy.rb +0 -0
  132. /data/{example-rails-app → example-rails-6-app}/config.ru +0 -0
  133. /data/{example-rails-app → example-rails-6-app}/lib/assets/.keep +0 -0
  134. /data/{example-rails-app → example-rails-6-app}/lib/tasks/.keep +0 -0
  135. /data/{example-rails-app → example-rails-6-app}/log/.keep +0 -0
  136. /data/{example-rails-app → example-rails-6-app}/public/404.html +0 -0
  137. /data/{example-rails-app → example-rails-6-app}/public/422.html +0 -0
  138. /data/{example-rails-app → example-rails-6-app}/public/500.html +0 -0
  139. /data/{example-rails-app → example-rails-6-app}/public/apple-touch-icon-precomposed.png +0 -0
  140. /data/{example-rails-app → example-rails-6-app}/public/apple-touch-icon.png +0 -0
  141. /data/{example-rails-app → example-rails-6-app}/public/favicon.ico +0 -0
  142. /data/{example-rails-app → example-rails-6-app}/public/robots.txt +0 -0
  143. /data/{example-rails-app → example-rails-6-app}/storage/.keep +0 -0
  144. /data/{example-rails-app → example-rails-6-app}/test/application_system_test_case.rb +0 -0
  145. /data/{example-rails-app → example-rails-6-app}/test/channels/application_cable/connection_test.rb +0 -0
  146. /data/{example-rails-app → example-rails-6-app}/test/controllers/.keep +0 -0
  147. /data/{example-rails-app → example-rails-6-app}/test/fixtures/files/.keep +0 -0
  148. /data/{example-rails-app → example-rails-6-app}/test/helpers/.keep +0 -0
  149. /data/{example-rails-app → example-rails-6-app}/test/integration/.keep +0 -0
  150. /data/{example-rails-app → example-rails-6-app}/test/mailers/.keep +0 -0
  151. /data/{example-rails-app → example-rails-6-app}/test/models/.keep +0 -0
  152. /data/{example-rails-app → example-rails-6-app}/test/system/.keep +0 -0
  153. /data/{example-rails-app → example-rails-6-app}/tmp/.keep +0 -0
  154. /data/{example-rails-app → example-rails-6-app}/tmp/pids/.keep +0 -0
  155. /data/{example-rails-app/tmp/storage → example-rails-6-app/vendor}/.keep +0 -0
  156. /data/{example-rails-app → example-rails-7-app}/.gitattributes +0 -0
  157. /data/{example-rails-app → example-rails-7-app}/.gitignore +0 -0
  158. /data/{example-rails-app → example-rails-7-app}/.ruby-version +0 -0
  159. /data/{example-rails-app → example-rails-7-app}/README.md +0 -0
  160. /data/{example-rails-app → example-rails-7-app}/app/assets/config/manifest.js +0 -0
  161. /data/{example-rails-app/vendor → example-rails-7-app/app/assets/images}/.keep +0 -0
  162. /data/{example-rails-app → example-rails-7-app}/app/assets/stylesheets/application.css +0 -0
  163. /data/{example-rails-app/vendor/javascript → example-rails-7-app/app/controllers/concerns}/.keep +0 -0
  164. /data/{example-rails-app → example-rails-7-app}/app/javascript/application.js +0 -0
  165. /data/{example-rails-app → example-rails-7-app}/app/javascript/controllers/application.js +0 -0
  166. /data/{example-rails-app → example-rails-7-app}/app/javascript/controllers/hello_controller.js +0 -0
  167. /data/{example-rails-app → example-rails-7-app}/app/javascript/controllers/index.js +0 -0
  168. /data/{example-rails-app → example-rails-7-app}/app/mailers/application_mailer.rb +0 -0
  169. /data/{example-rails-app → example-rails-7-app}/app/models/application_record.rb +0 -0
  170. /data/{example-rails-app → example-rails-7-app}/app/views/layouts/application.html.erb +0 -0
  171. /data/{example-rails-app → example-rails-7-app}/bin/importmap +0 -0
  172. /data/{example-rails-app → example-rails-7-app}/bin/rails +0 -0
  173. /data/{example-rails-app → example-rails-7-app}/bin/rake +0 -0
  174. /data/{example-rails-app → example-rails-7-app}/bin/setup +0 -0
  175. /data/{example-rails-app → example-rails-7-app}/config/application.rb +0 -0
  176. /data/{example-rails-app → example-rails-7-app}/config/boot.rb +0 -0
  177. /data/{example-rails-app → example-rails-7-app}/config/cable.yml +0 -0
  178. /data/{example-rails-app → example-rails-7-app}/config/credentials.yml.enc +0 -0
  179. /data/{example-rails-app → example-rails-7-app}/config/database.yml +0 -0
  180. /data/{example-rails-app → example-rails-7-app}/config/environments/development.rb +0 -0
  181. /data/{example-rails-app → example-rails-7-app}/config/environments/production.rb +0 -0
  182. /data/{example-rails-app → example-rails-7-app}/config/environments/test.rb +0 -0
  183. /data/{example-rails-app → example-rails-7-app}/config/importmap.rb +0 -0
  184. /data/{example-rails-app → example-rails-7-app}/config/initializers/assets.rb +0 -0
  185. /data/{example-rails-app → example-rails-7-app}/config/initializers/content_security_policy.rb +0 -0
  186. /data/{example-rails-app → example-rails-7-app}/config/initializers/filter_parameter_logging.rb +0 -0
  187. /data/{example-rails-app → example-rails-7-app}/config/initializers/inflections.rb +0 -0
  188. /data/{example-rails-app → example-rails-7-app}/config/locales/en.yml +0 -0
  189. /data/{example-rails-app → example-rails-7-app}/config/puma.rb +0 -0
  190. /data/{example-rails-app → example-rails-7-app}/config/routes.rb +0 -0
  191. /data/{example-rails-app → example-rails-7-app}/config/storage.yml +0 -0
  192. /data/{example-rails-app → example-rails-7-app}/db/migrate/20221001175928_create_examples.rb +0 -0
  193. /data/{example-rails-app → example-rails-7-app}/db/schema.rb +0 -0
  194. /data/{example-rails-app → example-rails-7-app}/db/seeds.rb +0 -0
  195. /data/{example-rails-app → example-rails-7-app}/test/test_helper.rb +0 -0
@@ -0,0 +1,66 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>We're sorry, but something went wrong (500)</title>
5
+ <meta name="viewport" content="width=device-width,initial-scale=1">
6
+ <style>
7
+ .rails-default-error-page {
8
+ background-color: #EFEFEF;
9
+ color: #2E2F30;
10
+ text-align: center;
11
+ font-family: arial, sans-serif;
12
+ margin: 0;
13
+ }
14
+
15
+ .rails-default-error-page div.dialog {
16
+ width: 95%;
17
+ max-width: 33em;
18
+ margin: 4em auto 0;
19
+ }
20
+
21
+ .rails-default-error-page div.dialog > div {
22
+ border: 1px solid #CCC;
23
+ border-right-color: #999;
24
+ border-left-color: #999;
25
+ border-bottom-color: #BBB;
26
+ border-top: #B00100 solid 4px;
27
+ border-top-left-radius: 9px;
28
+ border-top-right-radius: 9px;
29
+ background-color: white;
30
+ padding: 7px 12% 0;
31
+ box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
32
+ }
33
+
34
+ .rails-default-error-page h1 {
35
+ font-size: 100%;
36
+ color: #730E15;
37
+ line-height: 1.5em;
38
+ }
39
+
40
+ .rails-default-error-page div.dialog > p {
41
+ margin: 0 0 1em;
42
+ padding: 1em;
43
+ background-color: #F7F7F7;
44
+ border: 1px solid #CCC;
45
+ border-right-color: #999;
46
+ border-left-color: #999;
47
+ border-bottom-color: #999;
48
+ border-bottom-left-radius: 4px;
49
+ border-bottom-right-radius: 4px;
50
+ border-top-color: #DADADA;
51
+ color: #666;
52
+ box-shadow: 0 3px 8px rgba(50, 50, 50, 0.17);
53
+ }
54
+ </style>
55
+ </head>
56
+
57
+ <body class="rails-default-error-page">
58
+ <!-- This file lives in public/500.html -->
59
+ <div class="dialog">
60
+ <div>
61
+ <h1>We're sorry, but something went wrong.</h1>
62
+ </div>
63
+ <p>If you are the application owner check the logs for more information.</p>
64
+ </div>
65
+ </body>
66
+ </html>
File without changes
File without changes
@@ -0,0 +1 @@
1
+ # See https://www.robotstxt.org/robotstxt.html for documentation on how to use the robots.txt file
File without changes
@@ -0,0 +1,5 @@
1
+ require "test_helper"
2
+
3
+ class ApplicationSystemTestCase < ActionDispatch::SystemTestCase
4
+ driven_by :selenium, using: :chrome, screen_size: [1400, 1400]
5
+ end
@@ -0,0 +1,11 @@
1
+ require "test_helper"
2
+
3
+ class ApplicationCable::ConnectionTest < ActionCable::Connection::TestCase
4
+ # test "connects with cookies" do
5
+ # cookies.signed[:user_id] = 42
6
+ #
7
+ # connect
8
+ #
9
+ # assert_equal connection.user_id, "42"
10
+ # end
11
+ end
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
data/exe/clock CHANGED
@@ -1,6 +1,7 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
3
  require 'ruby-clock'
4
+ require "ruby-clock/dsl"
4
5
  RubyClock.detect_and_load_rails_app
5
6
  require 'rufus_monkeypatch'
6
7
  RubyClock.instance.listen_to_signals
@@ -22,5 +22,21 @@ module RubyClock::DSL
22
22
  def every(...)
23
23
  RubyClock.instance.schedule.every(...)
24
24
  end
25
+
26
+ def shell(string)
27
+ RubyClock.instance.shell(string)
28
+ end
29
+
30
+ def rake(string)
31
+ RubyClock.instance.rake(string)
32
+ end
33
+
34
+ def rake_execute(string)
35
+ RubyClock.instance.rake_execute(string)
36
+ end
37
+
38
+ def rake_async(string)
39
+ RubyClock.instance.rake_async(string)
40
+ end
25
41
  end
26
42
  end
@@ -2,13 +2,11 @@ module RubyClock::Shell
2
2
  def shell_runner
3
3
  @shell_runner ||= begin
4
4
  require 'terrapin'
5
- require 'posix-spawn'
6
-
7
- unless Terrapin::CommandLine.runner.class == Terrapin::CommandLine::PosixRunner
5
+ unless Terrapin::CommandLine.runner.class == Terrapin::CommandLine::ProcessRunner
8
6
  puts <<~MESSAGE
9
7
 
10
- 🤷 terrapin and posix-spawn are installed, but for some reason terrapin is
11
- not using posix-spawn as its runner.
8
+ 🤷 terrapin is installed, but for some reason terrapin is
9
+ using backticks as its runner.
12
10
 
13
11
  MESSAGE
14
12
  end
@@ -19,7 +17,7 @@ module RubyClock::Shell
19
17
  puts <<~MESSAGE
20
18
 
21
19
  🦥 Using ruby backticks for shell commands.
22
- For better performance, install the terrapin and posix-spawn gems.
20
+ For better performance, install the terrapin gem.
23
21
  See README.md for more info.
24
22
 
25
23
  MESSAGE
@@ -1,3 +1,3 @@
1
1
  class RubyClock
2
- VERSION = "2.0.0.beta5"
2
+ VERSION = "2.0.0.beta7"
3
3
  end
data/lib/ruby-clock.rb CHANGED
@@ -1,10 +1,7 @@
1
- require "ruby-clock/dsl"
2
1
  require "ruby-clock/version"
3
2
  require "ruby-clock/rake"
4
3
  require "ruby-clock/shell"
5
4
  require "ruby-clock/around_actions"
6
- require "ruby-clock/dsl"
7
- require "ruby-clock/runners"
8
5
  require "ruby-clock/rails"
9
6
  require 'rufus-scheduler'
10
7
  require 'singleton'
@@ -1,8 +1,15 @@
1
1
  require 'method_source'
2
2
  class Rufus::Scheduler::Job
3
+ UNDESIRED_ELEMENTS = ['', '}', 'end']
3
4
  def identifier
4
5
  @identifier ||= begin
5
- name || handler.source.split("\n").reject(&:empty?).grep_v(/#.*/)[-2].strip
6
+ return name if name
7
+
8
+ lines = handler.source.split("\n")
9
+ whitespace_removed = lines.map(&:strip)
10
+ undesired_removed = whitespace_removed - UNDESIRED_ELEMENTS
11
+ comment_only_lines_removed = undesired_removed.grep_v(/#.*/)
12
+ comment_only_lines_removed[-1] # final line
6
13
  rescue
7
14
  begin
8
15
  source_location.join('-')
data/ruby-clock.gemspec CHANGED
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
19
19
 
20
20
  spec.homepage = "https://github.com/jjb/ruby-clock"
21
21
  spec.license = "MIT"
22
- spec.required_ruby_version = Gem::Requirement.new(">= 2.7.0")
22
+ spec.required_ruby_version = Gem::Requirement.new(">= 3.0.0")
23
23
 
24
24
  # spec.metadata["allowed_push_host"] = "TODO: Set to 'http://mygemserver.com'"
25
25
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-clock
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0.beta5
4
+ version: 2.0.0.beta7
5
5
  platform: ruby
6
6
  authors:
7
7
  - John Bachir
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-10-23 00:00:00.000000000 Z
11
+ date: 2023-04-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rufus-scheduler
@@ -59,94 +59,191 @@ files:
59
59
  - example-app/Gemfile
60
60
  - example-app/Gemfile.lock
61
61
  - example-app/README.md
62
- - example-rails-app/.gitattributes
63
- - example-rails-app/.gitignore
64
- - example-rails-app/.ruby-version
65
- - example-rails-app/Clockfile
66
- - example-rails-app/Gemfile
67
- - example-rails-app/README.md
68
- - example-rails-app/Rakefile
69
- - example-rails-app/app/assets/config/manifest.js
70
- - example-rails-app/app/assets/images/.keep
71
- - example-rails-app/app/assets/stylesheets/application.css
72
- - example-rails-app/app/channels/application_cable/channel.rb
73
- - example-rails-app/app/channels/application_cable/connection.rb
74
- - example-rails-app/app/controllers/application_controller.rb
75
- - example-rails-app/app/controllers/concerns/.keep
76
- - example-rails-app/app/helpers/application_helper.rb
77
- - example-rails-app/app/javascript/application.js
78
- - example-rails-app/app/javascript/controllers/application.js
79
- - example-rails-app/app/javascript/controllers/hello_controller.js
80
- - example-rails-app/app/javascript/controllers/index.js
81
- - example-rails-app/app/jobs/application_job.rb
82
- - example-rails-app/app/mailers/application_mailer.rb
83
- - example-rails-app/app/models/application_record.rb
84
- - example-rails-app/app/models/concerns/.keep
85
- - example-rails-app/app/models/example.rb
86
- - example-rails-app/app/views/layouts/application.html.erb
87
- - example-rails-app/app/views/layouts/mailer.html.erb
88
- - example-rails-app/app/views/layouts/mailer.text.erb
89
- - example-rails-app/bin/bundle
90
- - example-rails-app/bin/importmap
91
- - example-rails-app/bin/rails
92
- - example-rails-app/bin/rake
93
- - example-rails-app/bin/setup
94
- - example-rails-app/config.ru
95
- - example-rails-app/config/application.rb
96
- - example-rails-app/config/boot.rb
97
- - example-rails-app/config/cable.yml
98
- - example-rails-app/config/credentials.yml.enc
99
- - example-rails-app/config/database.yml
100
- - example-rails-app/config/environment.rb
101
- - example-rails-app/config/environments/development.rb
102
- - example-rails-app/config/environments/production.rb
103
- - example-rails-app/config/environments/test.rb
104
- - example-rails-app/config/importmap.rb
105
- - example-rails-app/config/initializers/assets.rb
106
- - example-rails-app/config/initializers/content_security_policy.rb
107
- - example-rails-app/config/initializers/filter_parameter_logging.rb
108
- - example-rails-app/config/initializers/inflections.rb
109
- - example-rails-app/config/initializers/permissions_policy.rb
110
- - example-rails-app/config/locales/en.yml
111
- - example-rails-app/config/puma.rb
112
- - example-rails-app/config/routes.rb
113
- - example-rails-app/config/storage.yml
114
- - example-rails-app/db/migrate/20221001175928_create_examples.rb
115
- - example-rails-app/db/schema.rb
116
- - example-rails-app/db/seeds.rb
117
- - example-rails-app/lib/assets/.keep
118
- - example-rails-app/lib/tasks/.keep
119
- - example-rails-app/log/.keep
120
- - example-rails-app/public/404.html
121
- - example-rails-app/public/422.html
122
- - example-rails-app/public/500.html
123
- - example-rails-app/public/apple-touch-icon-precomposed.png
124
- - example-rails-app/public/apple-touch-icon.png
125
- - example-rails-app/public/favicon.ico
126
- - example-rails-app/public/robots.txt
127
- - example-rails-app/storage/.keep
128
- - example-rails-app/test/application_system_test_case.rb
129
- - example-rails-app/test/channels/application_cable/connection_test.rb
130
- - example-rails-app/test/controllers/.keep
131
- - example-rails-app/test/fixtures/files/.keep
132
- - example-rails-app/test/helpers/.keep
133
- - example-rails-app/test/integration/.keep
134
- - example-rails-app/test/mailers/.keep
135
- - example-rails-app/test/models/.keep
136
- - example-rails-app/test/system/.keep
137
- - example-rails-app/test/test_helper.rb
138
- - example-rails-app/tmp/.keep
139
- - example-rails-app/tmp/pids/.keep
140
- - example-rails-app/tmp/storage/.keep
141
- - example-rails-app/vendor/.keep
142
- - example-rails-app/vendor/javascript/.keep
62
+ - example-rails-6-app/.browserslistrc
63
+ - example-rails-6-app/.gitattributes
64
+ - example-rails-6-app/.gitignore
65
+ - example-rails-6-app/.ruby-version
66
+ - example-rails-6-app/Clockfile
67
+ - example-rails-6-app/Gemfile
68
+ - example-rails-6-app/Gemfile.lock
69
+ - example-rails-6-app/README.md
70
+ - example-rails-6-app/Rakefile
71
+ - example-rails-6-app/app/assets/config/manifest.js
72
+ - example-rails-6-app/app/assets/images/.keep
73
+ - example-rails-6-app/app/assets/stylesheets/application.css
74
+ - example-rails-6-app/app/channels/application_cable/channel.rb
75
+ - example-rails-6-app/app/channels/application_cable/connection.rb
76
+ - example-rails-6-app/app/controllers/application_controller.rb
77
+ - example-rails-6-app/app/controllers/concerns/.keep
78
+ - example-rails-6-app/app/helpers/application_helper.rb
79
+ - example-rails-6-app/app/javascript/channels/consumer.js
80
+ - example-rails-6-app/app/javascript/channels/index.js
81
+ - example-rails-6-app/app/javascript/packs/application.js
82
+ - example-rails-6-app/app/jobs/application_job.rb
83
+ - example-rails-6-app/app/mailers/application_mailer.rb
84
+ - example-rails-6-app/app/models/application_record.rb
85
+ - example-rails-6-app/app/models/concerns/.keep
86
+ - example-rails-6-app/app/models/example.rb
87
+ - example-rails-6-app/app/views/layouts/application.html.erb
88
+ - example-rails-6-app/app/views/layouts/mailer.html.erb
89
+ - example-rails-6-app/app/views/layouts/mailer.text.erb
90
+ - example-rails-6-app/babel.config.js
91
+ - example-rails-6-app/bin/bundle
92
+ - example-rails-6-app/bin/rails
93
+ - example-rails-6-app/bin/rake
94
+ - example-rails-6-app/bin/setup
95
+ - example-rails-6-app/bin/spring
96
+ - example-rails-6-app/bin/webpack
97
+ - example-rails-6-app/bin/webpack-dev-server
98
+ - example-rails-6-app/bin/yarn
99
+ - example-rails-6-app/config.ru
100
+ - example-rails-6-app/config/application.rb
101
+ - example-rails-6-app/config/boot.rb
102
+ - example-rails-6-app/config/cable.yml
103
+ - example-rails-6-app/config/credentials.yml.enc
104
+ - example-rails-6-app/config/database.yml
105
+ - example-rails-6-app/config/environment.rb
106
+ - example-rails-6-app/config/environments/development.rb
107
+ - example-rails-6-app/config/environments/production.rb
108
+ - example-rails-6-app/config/environments/test.rb
109
+ - example-rails-6-app/config/initializers/application_controller_renderer.rb
110
+ - example-rails-6-app/config/initializers/assets.rb
111
+ - example-rails-6-app/config/initializers/backtrace_silencers.rb
112
+ - example-rails-6-app/config/initializers/content_security_policy.rb
113
+ - example-rails-6-app/config/initializers/cookies_serializer.rb
114
+ - example-rails-6-app/config/initializers/filter_parameter_logging.rb
115
+ - example-rails-6-app/config/initializers/inflections.rb
116
+ - example-rails-6-app/config/initializers/mime_types.rb
117
+ - example-rails-6-app/config/initializers/permissions_policy.rb
118
+ - example-rails-6-app/config/initializers/wrap_parameters.rb
119
+ - example-rails-6-app/config/locales/en.yml
120
+ - example-rails-6-app/config/puma.rb
121
+ - example-rails-6-app/config/routes.rb
122
+ - example-rails-6-app/config/spring.rb
123
+ - example-rails-6-app/config/storage.yml
124
+ - example-rails-6-app/config/webpack/development.js
125
+ - example-rails-6-app/config/webpack/environment.js
126
+ - example-rails-6-app/config/webpack/production.js
127
+ - example-rails-6-app/config/webpack/test.js
128
+ - example-rails-6-app/config/webpacker.yml
129
+ - example-rails-6-app/db/migrate/20221102224703_create_examples.rb
130
+ - example-rails-6-app/db/schema.rb
131
+ - example-rails-6-app/db/seeds.rb
132
+ - example-rails-6-app/lib/assets/.keep
133
+ - example-rails-6-app/lib/tasks/.keep
134
+ - example-rails-6-app/log/.keep
135
+ - example-rails-6-app/package.json
136
+ - example-rails-6-app/postcss.config.js
137
+ - example-rails-6-app/public/404.html
138
+ - example-rails-6-app/public/422.html
139
+ - example-rails-6-app/public/500.html
140
+ - example-rails-6-app/public/apple-touch-icon-precomposed.png
141
+ - example-rails-6-app/public/apple-touch-icon.png
142
+ - example-rails-6-app/public/favicon.ico
143
+ - example-rails-6-app/public/robots.txt
144
+ - example-rails-6-app/storage/.keep
145
+ - example-rails-6-app/test/application_system_test_case.rb
146
+ - example-rails-6-app/test/channels/application_cable/connection_test.rb
147
+ - example-rails-6-app/test/controllers/.keep
148
+ - example-rails-6-app/test/fixtures/files/.keep
149
+ - example-rails-6-app/test/helpers/.keep
150
+ - example-rails-6-app/test/integration/.keep
151
+ - example-rails-6-app/test/mailers/.keep
152
+ - example-rails-6-app/test/models/.keep
153
+ - example-rails-6-app/test/system/.keep
154
+ - example-rails-6-app/test/test_helper.rb
155
+ - example-rails-6-app/tmp/.keep
156
+ - example-rails-6-app/tmp/pids/.keep
157
+ - example-rails-6-app/vendor/.keep
158
+ - example-rails-6-app/yarn.lock
159
+ - example-rails-7-app/.gitattributes
160
+ - example-rails-7-app/.gitignore
161
+ - example-rails-7-app/.ruby-version
162
+ - example-rails-7-app/Clockfile
163
+ - example-rails-7-app/Gemfile
164
+ - example-rails-7-app/Gemfile.lock
165
+ - example-rails-7-app/README.md
166
+ - example-rails-7-app/Rakefile
167
+ - example-rails-7-app/app/assets/config/manifest.js
168
+ - example-rails-7-app/app/assets/images/.keep
169
+ - example-rails-7-app/app/assets/stylesheets/application.css
170
+ - example-rails-7-app/app/channels/application_cable/channel.rb
171
+ - example-rails-7-app/app/channels/application_cable/connection.rb
172
+ - example-rails-7-app/app/controllers/application_controller.rb
173
+ - example-rails-7-app/app/controllers/concerns/.keep
174
+ - example-rails-7-app/app/helpers/application_helper.rb
175
+ - example-rails-7-app/app/javascript/application.js
176
+ - example-rails-7-app/app/javascript/controllers/application.js
177
+ - example-rails-7-app/app/javascript/controllers/hello_controller.js
178
+ - example-rails-7-app/app/javascript/controllers/index.js
179
+ - example-rails-7-app/app/jobs/application_job.rb
180
+ - example-rails-7-app/app/mailers/application_mailer.rb
181
+ - example-rails-7-app/app/models/application_record.rb
182
+ - example-rails-7-app/app/models/concerns/.keep
183
+ - example-rails-7-app/app/models/example.rb
184
+ - example-rails-7-app/app/views/layouts/application.html.erb
185
+ - example-rails-7-app/app/views/layouts/mailer.html.erb
186
+ - example-rails-7-app/app/views/layouts/mailer.text.erb
187
+ - example-rails-7-app/bin/bundle
188
+ - example-rails-7-app/bin/importmap
189
+ - example-rails-7-app/bin/rails
190
+ - example-rails-7-app/bin/rake
191
+ - example-rails-7-app/bin/setup
192
+ - example-rails-7-app/config.ru
193
+ - example-rails-7-app/config/application.rb
194
+ - example-rails-7-app/config/boot.rb
195
+ - example-rails-7-app/config/cable.yml
196
+ - example-rails-7-app/config/credentials.yml.enc
197
+ - example-rails-7-app/config/database.yml
198
+ - example-rails-7-app/config/environment.rb
199
+ - example-rails-7-app/config/environments/development.rb
200
+ - example-rails-7-app/config/environments/production.rb
201
+ - example-rails-7-app/config/environments/test.rb
202
+ - example-rails-7-app/config/importmap.rb
203
+ - example-rails-7-app/config/initializers/assets.rb
204
+ - example-rails-7-app/config/initializers/content_security_policy.rb
205
+ - example-rails-7-app/config/initializers/filter_parameter_logging.rb
206
+ - example-rails-7-app/config/initializers/inflections.rb
207
+ - example-rails-7-app/config/initializers/permissions_policy.rb
208
+ - example-rails-7-app/config/locales/en.yml
209
+ - example-rails-7-app/config/puma.rb
210
+ - example-rails-7-app/config/routes.rb
211
+ - example-rails-7-app/config/storage.yml
212
+ - example-rails-7-app/db/migrate/20221001175928_create_examples.rb
213
+ - example-rails-7-app/db/schema.rb
214
+ - example-rails-7-app/db/seeds.rb
215
+ - example-rails-7-app/lib/assets/.keep
216
+ - example-rails-7-app/lib/tasks/.keep
217
+ - example-rails-7-app/log/.keep
218
+ - example-rails-7-app/public/404.html
219
+ - example-rails-7-app/public/422.html
220
+ - example-rails-7-app/public/500.html
221
+ - example-rails-7-app/public/apple-touch-icon-precomposed.png
222
+ - example-rails-7-app/public/apple-touch-icon.png
223
+ - example-rails-7-app/public/favicon.ico
224
+ - example-rails-7-app/public/robots.txt
225
+ - example-rails-7-app/storage/.keep
226
+ - example-rails-7-app/test/application_system_test_case.rb
227
+ - example-rails-7-app/test/channels/application_cable/connection_test.rb
228
+ - example-rails-7-app/test/controllers/.keep
229
+ - example-rails-7-app/test/fixtures/files/.keep
230
+ - example-rails-7-app/test/helpers/.keep
231
+ - example-rails-7-app/test/integration/.keep
232
+ - example-rails-7-app/test/mailers/.keep
233
+ - example-rails-7-app/test/models/.keep
234
+ - example-rails-7-app/test/system/.keep
235
+ - example-rails-7-app/test/test_helper.rb
236
+ - example-rails-7-app/tmp/.keep
237
+ - example-rails-7-app/tmp/pids/.keep
238
+ - example-rails-7-app/tmp/storage/.keep
239
+ - example-rails-7-app/vendor/.keep
240
+ - example-rails-7-app/vendor/javascript/.keep
143
241
  - exe/clock
144
242
  - lib/ruby-clock.rb
145
243
  - lib/ruby-clock/around_actions.rb
146
244
  - lib/ruby-clock/dsl.rb
147
245
  - lib/ruby-clock/rails.rb
148
246
  - lib/ruby-clock/rake.rb
149
- - lib/ruby-clock/runners.rb
150
247
  - lib/ruby-clock/shell.rb
151
248
  - lib/ruby-clock/version.rb
152
249
  - lib/rufus_monkeypatch.rb
@@ -172,14 +269,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
172
269
  requirements:
173
270
  - - ">="
174
271
  - !ruby/object:Gem::Version
175
- version: 2.7.0
272
+ version: 3.0.0
176
273
  required_rubygems_version: !ruby/object:Gem::Requirement
177
274
  requirements:
178
275
  - - ">"
179
276
  - !ruby/object:Gem::Version
180
277
  version: 1.3.1
181
278
  requirements: []
182
- rubygems_version: 3.1.6
279
+ rubygems_version: 3.3.7
183
280
  signing_key:
184
281
  specification_version: 4
185
282
  summary: A job scheduler which runs jobs each in their own thread in a persistent
@@ -1,23 +0,0 @@
1
- # if we ever want to make these available at the top-level using refinements,
2
- # like we do with the DSL, it doesn't work in Rails because Rails prepends Kernel after
3
- # we use the refinment. Initial tests show that prepending ActiveSupport::ForkTracker::CoreExtPrivate
4
- # works, but maybe that's not reliable or has unknown side effects
5
- # https://stackoverflow.com/questions/74119178/
6
-
7
- module RubyClock::Runners
8
- def self.shell(string)
9
- RubyClock.instance.shell(string)
10
- end
11
-
12
- def self.rake(string)
13
- RubyClock.instance.rake(string)
14
- end
15
-
16
- def self.rake_execute(string)
17
- RubyClock.instance.rake_execute(string)
18
- end
19
-
20
- def self.rake_async(string)
21
- RubyClock.instance.rake_async(string)
22
- end
23
- end