Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap-rubygem.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGleb Mazovetskiy <glex.spb@gmail.com>2020-08-09 11:09:29 +0300
committerGleb Mazovetskiy <glex.spb@gmail.com>2020-08-09 11:09:29 +0300
commit43f87174d8d3a9b473c12fd807511b46bf7b4bd4 (patch)
treeb0d135173f2a7c0cf78c905bc17d321b0e70e609
parentca9e27946b00f0600ed3ca346e09ca0bb7e12899 (diff)
updater/js.rb: Update paths for v5
-rw-r--r--tasks/updater/js.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/tasks/updater/js.rb b/tasks/updater/js.rb
index 0542629..fbcb466 100644
--- a/tasks/updater/js.rb
+++ b/tasks/updater/js.rb
@@ -29,13 +29,13 @@ class Updater
def bootstrap_js_files
@bootstrap_js_files ||= begin
- src_files = get_paths_by_type('js/src', /\.js$/) - %w[index.js tools/sanitizer.js]
+ src_files = get_paths_by_type('js/src', /\.js$/) - %w[util/index.js util/sanitizer.js]
imports = Deps.new
# Get the imports from the ES6 files to order requires correctly.
read_files('js/src', src_files).each do |name, content|
imports.add name,
- *content.scan(%r{import [a-zA-Z]* from '\./(\w+)})
- .flatten(1).map { |f| "#{f}.js" }
+ *content.scan(%r{import [a-zA-Z]* from '\./([\w/-]+)})
+ .flatten(1).map { |f| "#{f}.js" }.uniq
end
imports.tsort
end