bullet_train 1.2.18 → 1.2.20
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/views/account/teams/_form.html.erb +0 -1
- data/app/views/layouts/docs.html.erb +3 -3
- data/lib/bullet_train/version.rb +1 -1
- data/lib/tasks/bullet_train_tasks.rake +24 -12
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4561ddbfaa81217ae48ea15b210025cb0390f3acecb2a7be5f0cd239eb0ec731
|
4
|
+
data.tar.gz: 610569262d3a98cf8778a702202f21c0739b62e4e68691befa83b90b1800fab2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a2a672f5278fa428754aeee9f17a4115e4bf0b9420b9768790bd3d7e9a29c2a98dfeec7ce82b6d33338cd61674fc7ebf4074a7b4b7f3f239733a3e20ef8e194
|
7
|
+
data.tar.gz: 4dc593a08ee2e2137a807038ca554be019b1a3fb8362e691be55f4e9834be6636a9475947b51e272205968b5665306261bc8bc63aec9e4cc6f4dbab23c9361f3
|
@@ -32,7 +32,7 @@
|
|
32
32
|
<meta property="og:url" content="<%= request.base_url + request.path %>" />
|
33
33
|
<meta property="og:description" content="<%= description.truncate(200) %>" />
|
34
34
|
</head>
|
35
|
-
<body class="bg-
|
35
|
+
<body class="<%= BulletTrain::Themes::Light.background || "bg-gradient-to-br from-secondary-200 to-primary-400 dark:from-primary-900 dark:to-primary-600" %> text-slate-700 text-sm font-normal dark:text-slate-300">
|
36
36
|
<div class="md:p-5">
|
37
37
|
<div class="min-h-screen md:h-auto overflow-hidden md:rounded-lg flex shadow"
|
38
38
|
data-controller="mobile-menu"
|
@@ -296,7 +296,7 @@
|
|
296
296
|
|
297
297
|
class="fixed inset-0" aria-hidden="true"
|
298
298
|
>
|
299
|
-
<div class="absolute inset-0 bg-
|
299
|
+
<div class="absolute inset-0 bg-gradient-to-br from-secondary-200 to-primary-400 opacity-75"></div>
|
300
300
|
</button>
|
301
301
|
<div
|
302
302
|
data-mobile-menu-target="revealable"
|
@@ -308,7 +308,7 @@
|
|
308
308
|
data-transition-leave-start="translate-x-0"
|
309
309
|
data-transition-leave-end="-translate-x-full"
|
310
310
|
|
311
|
-
class="relative flex-1 flex flex-col max-w-xs w-full pb-4 bg-
|
311
|
+
class="relative flex-1 flex flex-col max-w-xs w-full pb-4 bg-gradient-to-br from-primary-900 to-primary-600 shadow-xl"
|
312
312
|
>
|
313
313
|
<%= menu %>
|
314
314
|
</div>
|
data/lib/bullet_train/version.rb
CHANGED
@@ -109,14 +109,17 @@ namespace :bullet_train do
|
|
109
109
|
flags_with_values.each do |process|
|
110
110
|
case process[:flag]
|
111
111
|
when "--help"
|
112
|
-
puts "
|
113
|
-
puts "bin/hack
|
114
|
-
puts "bin/hack --
|
115
|
-
puts "bin/hack --
|
116
|
-
puts "bin/hack --
|
112
|
+
puts ""
|
113
|
+
puts "bin/hack: " + "Clone bullet_train-core and link up gems (will only link up gems if already cloned).".blue
|
114
|
+
puts "bin/hack --link: " + "Link all of your Bullet Train gems to `local/bullet_train-core`.".blue
|
115
|
+
puts "bin/hack --link (version-number): " + "Link all of your Bullet Train gems to the version number passed.".blue
|
116
|
+
puts "bin/hack --reset: " + "Resets all of your gems to their original definition.".blue
|
117
|
+
puts "bin/hack --watch-js: " + "Watches for any changes in JavaScript files gems that have an npm package.".blue
|
118
|
+
puts "bin/hack --clean-js: " + "Resets all of your npm packages from `local/bullet_train-core` to their original definition.".blue
|
117
119
|
exit
|
118
120
|
when "--link", "--reset"
|
119
|
-
|
121
|
+
version = process[:values].pop
|
122
|
+
set_core_gems(process[:flag], version, framework_packages)
|
120
123
|
stream "bundle install"
|
121
124
|
when "--watch-js", "--clean-js"
|
122
125
|
package_name = process[:values].pop
|
@@ -185,7 +188,7 @@ namespace :bullet_train do
|
|
185
188
|
|
186
189
|
# Link all of the local gems to the current Gemfile.
|
187
190
|
puts "Now we'll try to link up the Bullet Train core repositories in the `Gemfile`.".blue
|
188
|
-
set_core_gems("--link", framework_packages)
|
191
|
+
set_core_gems("--link", nil, framework_packages)
|
189
192
|
|
190
193
|
puts ""
|
191
194
|
puts "Now we'll run `bundle install`.".blue
|
@@ -215,7 +218,7 @@ namespace :bullet_train do
|
|
215
218
|
end
|
216
219
|
|
217
220
|
# Pass "--link" or "--reset" as a flag to set the gems.
|
218
|
-
def set_core_gems(flag, framework_packages)
|
221
|
+
def set_core_gems(flag, version, framework_packages)
|
219
222
|
packages = framework_packages.keys
|
220
223
|
gemfile_lines = File.readlines("./Gemfile")
|
221
224
|
|
@@ -231,15 +234,20 @@ namespace :bullet_train do
|
|
231
234
|
if flag == "--link"
|
232
235
|
if `cat Gemfile | grep "gem \\\"#{package}\\\", path: \\\"local/bullet_train-core/#{package}\\\""`.chomp.present?
|
233
236
|
puts "#{package} is already linked to a checked out copy in `local` in the `Gemfile`.".green
|
234
|
-
|
237
|
+
# We can update this later to match a regular expression at the end
|
238
|
+
# (git: "...", require: "...", etc.), but this will do for now.
|
239
|
+
elsif `cat Gemfile | grep "gem \\\"#{package}\\\", path:"`.chomp.present?
|
235
240
|
puts "#{package} already has some sort of alternative source configured in the `Gemfile`.".yellow
|
236
241
|
puts "We can't do anything with this. Sorry! We'll proceed, but you have to link this package yourself.".red
|
237
242
|
elsif `cat Gemfile | grep "gem \\\"#{package}\\\""`.chomp.present?
|
238
243
|
puts "#{package} is directly present in the `Gemfile`, so we'll update that line.".green
|
239
|
-
line.gsub
|
244
|
+
line = version.present? ? "#{line.chomp}, \"#{version}\"\n" : line.gsub(original_path, local_path)
|
240
245
|
end
|
241
246
|
elsif flag == "--reset"
|
242
|
-
line.
|
247
|
+
if line.match?(/bullet_train/)
|
248
|
+
line.gsub!(local_path, original_path) # Reset local path
|
249
|
+
line.gsub!(/, "[0-9|.]*"$/, "") # Reset specific version
|
250
|
+
end
|
243
251
|
puts "Resetting '#{package}' package in the Gemfile...".blue
|
244
252
|
end
|
245
253
|
end
|
@@ -250,7 +258,11 @@ namespace :bullet_train do
|
|
250
258
|
if flag == "--link"
|
251
259
|
unless match_found
|
252
260
|
puts "Could not find #{package}. Adding to the end of the Gemfile.".blue
|
253
|
-
new_lines <<
|
261
|
+
new_lines << if version
|
262
|
+
"#{original_path.chomp}, \"#{version}\"\n"
|
263
|
+
else
|
264
|
+
"#{local_path}\n"
|
265
|
+
end
|
254
266
|
end
|
255
267
|
elsif flag == "--reset"
|
256
268
|
gem_regexp = /bullet_train-[a-z|A-Z_-]+/
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bullet_train
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.20
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew Culver
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-03-
|
11
|
+
date: 2023-03-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: standard
|
@@ -296,14 +296,14 @@ dependencies:
|
|
296
296
|
requirements:
|
297
297
|
- - "~>"
|
298
298
|
- !ruby/object:Gem::Version
|
299
|
-
version: '0.
|
299
|
+
version: '0.9'
|
300
300
|
type: :runtime
|
301
301
|
prerelease: false
|
302
302
|
version_requirements: !ruby/object:Gem::Requirement
|
303
303
|
requirements:
|
304
304
|
- - "~>"
|
305
305
|
- !ruby/object:Gem::Version
|
306
|
-
version: '0.
|
306
|
+
version: '0.9'
|
307
307
|
- !ruby/object:Gem::Dependency
|
308
308
|
name: showcase-rails
|
309
309
|
requirement: !ruby/object:Gem::Requirement
|