Skip to content

Commit 2a2a5ec

Browse files
authored
Use where on Windows instead of which (#299) (#300)
If the call is on Windows, it uses `where` instead of `which` and correctly sends the output to NUL so that it does not show unnecessary message on the installer's output. This fixes the incorrect/ misleading message shown on Windows currently.
1 parent acbb925 commit 2a2a5ec

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/tasks/turbo_tasks.rake

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@ def run_turbo_install_template(path)
33
end
44

55
def redis_installed?
6-
system('which redis-server > /dev/null')
6+
Gem.win_platform? ?
7+
system('where redis-server > NUL 2>&1') :
8+
system('which redis-server > /dev/null')
79
end
810

911
def switch_on_redis_if_available

0 commit comments

Comments
 (0)