Skip to content

Commit

Permalink
msi: set GEM_HOME / GEM_PATH in batch file
Browse files Browse the repository at this point in the history
Signed-off-by: Shizuo Fujita <[email protected]>
  • Loading branch information
Watson1978 authored and kenhys committed Nov 8, 2024
1 parent 54d9451 commit 11163f6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion fluent-package/msi/assets/fluentd.bat
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,12 @@ if "%~nx0" == "td-agent.bat" (
@rem Convert path separator from backslash to forwardslash
set FLUENT_PACKAGE_TOPDIR=%FLUENT_PACKAGE_TOPDIR:\=/%

set PATH=%FLUENT_PACKAGE_TOPDIR%bin;%PATH%
set "FLUENT_PACKAGE_BINDIR=%FLUENT_PACKAGE_TOPDIR%bin"
set PATH=%FLUENT_PACKAGE_BINDIR%;%PATH%
set PATH=%FLUENT_PACKAGE_TOPDIR%;%PATH%
for /f "usebackq" %%i in (`^""%FLUENT_PACKAGE_BINDIR%\ruby.exe" -rrbconfig -e "print RbConfig::CONFIG['ruby_version']"^"`) do set RUBY_VERSION=%%i
set "GEM_HOME=%FLUENT_PACKAGE_TOPDIR%lib/ruby/gems/%RUBY_VERSION%"
set "GEM_PATH=%FLUENT_PACKAGE_TOPDIR%lib/ruby/gems/%RUBY_VERSION%"
set "FLUENT_CONF=%FLUENT_PACKAGE_TOPDIR%etc/fluent/fluentd.conf"
set "FLUENT_PLUGIN=%FLUENT_PACKAGE_TOPDIR%etc/fluent/plugin"

Expand Down

0 comments on commit 11163f6

Please sign in to comment.