Module: Hlsv
- Defined in:
- lib/hlsv/path_guard.rb,
lib/hlsv.rb,
lib/hlsv/cli.rb,
lib/hlsv/xpt.rb,
lib/hlsv/version.rb,
lib/hlsv/web_app.rb,
lib/hlsv/html2word.rb,
lib/hlsv/url_helper.rb,
lib/hlsv/config_manager.rb,
lib/hlsv/analysis_runner.rb,
lib/hlsv/sdtm_validation.rb,
lib/hlsv/analysis_registry.rb,
lib/hlsv/sdtm_validation/define.rb,
lib/hlsv/sdtm_validation/report.rb,
lib/hlsv/sdtm_validation/dataset.rb
Overview
frozen_string_literal: true
Defined Under Namespace
Modules: AnalysisRunner, OoxmlBuilder, PathGuard, UrlHelper
Classes: AnalysisRegistry, CLI, ConfigManager, DocxWriter, Error, RiReportParser, SdtmValidation, WebApp
Constant Summary
collapse
- INSTALL_ROOT =
File.expand_path("#{File.dirname(__FILE__)}/..")
- VERSION =
"2.0.0"
Class Method Summary
collapse
Class Method Details
.config_path ⇒ Object
26
27
28
|
# File 'lib/hlsv.rb', line 26
def self.config_path
"#{Dir.pwd}/config.yaml"
end
|
.default_config_path ⇒ Object
30
31
32
|
# File 'lib/hlsv.rb', line 30
def self.default_config_path
"#{INSTALL_ROOT}/config.default.yaml"
end
|
.ensure_config_file ⇒ Object
14
15
16
17
18
19
20
21
22
23
24
|
# File 'lib/hlsv.rb', line 14
def self.ensure_config_file
unless File.exist?(config_path)
if File.exist?(default_config_path)
config_default = YAML.load_file(default_config_path)
File.write(config_path, config_default.to_yaml)
puts "✓ config.yaml created from config.default.yaml"
else
puts "⚠ WARNING: Neither config.yaml nor config.default.yaml exists!"
end
end
end
|
.license_path ⇒ Object
34
35
36
|
# File 'lib/hlsv.rb', line 34
def self.license_path
"#{INSTALL_ROOT}/LICENSE"
end
|
.start_server(host: '127.0.0.1', port: 4567) ⇒ Object
9
10
11
12
|
# File 'lib/hlsv.rb', line 9
def self.start_server(host: '127.0.0.1', port: 4567)
ensure_config_file
WebApp.run! host: host, port: port
end
|