Skip to content

Commit 562846d

Browse files
For rake dist, grab the submodule for whatever selector engine was specified, even if it’s the default.
This is the thing I forgot to do when I removed our repo’s copy of Sizzle. That version of Sizzle _did_ get used if you tried to `rake dist` but you didn’t have the Sizzle submodule initialized. Considering that we’d have fetched the submodule automatically anyway, it’s not clear how much of a victory this was for user-friendliness.
1 parent 4f4803a commit 562846d

File tree

1 file changed

+2
-8
lines changed

1 file changed

+2
-8
lines changed

Rakefile

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -170,18 +170,12 @@ EOF
170170

171171
def self.get_selector_engine(name)
172172
return if !name
173-
# If the submodule exists, we should use it, even if we're using the
174-
# default engine; the user might have fetched it manually, and thus would
175-
# want to build a distributable with the most recent version of that
176-
# engine.
173+
# If the submodule exists, we should use it.
177174
submodule_path = File.join(ROOT_DIR, "vendor", name)
178175
return submodule_path if File.exist?(File.join(submodule_path, "repository", ".git"))
179176
return submodule_path if name === "legacy_selector"
180177

181-
# If it doesn't exist, we should fetch it, _unless_ it's the default
182-
# engine. We've already got a known version of the default engine in our
183-
# load path.
184-
return if name == DEFAULT_SELECTOR_ENGINE
178+
# If it doesn't exist, we should fetch it.
185179
get_submodule('the required selector engine', "#{name}/repository")
186180
unless File.exist?(submodule_path)
187181
puts "The selector engine you required isn't available at vendor/#{name}.\n\n"

0 commit comments

Comments
 (0)