Module: ASConstants

Defined in:
common/asconstants.rb

Overview

will be adding this file to .gitignore the version and schema_info values should be updated with the ant dist task

Defined Under Namespace

Modules: Repository

Class Method Summary collapse

Class Method Details

.VERSIONObject



19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# File 'common/asconstants.rb', line 19

def self.VERSION
  return @VERSION if @VERSION

  begin
    version = java.lang.ClassLoader.getSystemClassLoader.getResourceAsStream("ARCHIVESSPACE_VERSION")
    if version
      @VERSION = version.to_io.read.strip
    else # some servlet containers have a hard time finding the resource...
      # fallback_version variable gets changed in dist ant task . The a is
      # just a cue that we're using this..
      fallback_version = "v2.8.1-rc1.a"
      @VERSION = fallback_version
    end
  rescue
    @VERSION = "NO VERSION"
  end
end