HEX
Server: Apache
System: Linux s198.coreserver.jp 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC 2025 x86_64
User: nagasaki (10062)
PHP: 7.1.33
Disabled: NONE
Upload Files
File: //usr/local/rvm/gems/ruby-2.7.4/bin/ruby_executable_hooks
#!/usr/bin/env ruby

title = "ruby #{ARGV*" "}"
$0    = ARGV.shift
Process.setproctitle(title) if Process.methods.include?(:setproctitle)

require 'rubygems'
begin
  require 'executable-hooks/hooks'
  Gem::ExecutableHooks.run($0)
rescue LoadError
  warn "unable to load executable-hooks/hooks" if ENV.key?('ExecutableHooks_DEBUG')
end unless $0.end_with?('/executable-hooks-uninstaller')

content = File.read($0)

if (index = content.index("\n#!ruby\n")) && index > 0
  skipped_content = content.slice!(0..index)
  start_line = skipped_content.count("\n") + 1
  eval content, binding, $0, start_line
else
  eval content, binding, $0
end