Class: Papers::Configuration
- Inherits:
-
Object
- Object
- Papers::Configuration
- Defined in:
- lib/papers/configuration.rb
Instance Attribute Summary collapse
-
#javascript_paths ⇒ Object
Returns the value of attribute javascript_paths.
-
#license_whitelist ⇒ Object
Returns the value of attribute license_whitelist.
-
#manifest_file ⇒ Object
Returns the value of attribute manifest_file.
-
#validate_gems ⇒ Object
Returns the value of attribute validate_gems.
-
#validate_javascript ⇒ Object
Returns the value of attribute validate_javascript.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #validate_gems? ⇒ Boolean
- #validate_javascript? ⇒ Boolean
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 |
# File 'lib/papers/configuration.rb', line 13 def initialize @license_whitelist = [ 'MIT', 'BSD', 'Apache 2.0', 'Apache-2.0', 'LGPLv2.1', 'LGPLv3', 'Ruby', 'Manually Reviewed', 'Unlicensed' ] @manifest_file = File.join(Dir.pwd, 'config', 'papers_manifest.yml') @validate_gems = true @validate_javascript = true @javascript_paths = [ File.join(Dir.pwd, 'app', 'assets', 'javascripts'), File.join(Dir.pwd, 'lib', 'assets', 'javascripts'), File.join(Dir.pwd, 'vendor', 'assets', 'javascripts') ] end |
Instance Attribute Details
#javascript_paths ⇒ Object
Returns the value of attribute javascript_paths.
11 12 13 |
# File 'lib/papers/configuration.rb', line 11 def javascript_paths @javascript_paths end |
#license_whitelist ⇒ Object
Returns the value of attribute license_whitelist.
3 4 5 |
# File 'lib/papers/configuration.rb', line 3 def license_whitelist @license_whitelist end |
#manifest_file ⇒ Object
Returns the value of attribute manifest_file.
5 6 7 |
# File 'lib/papers/configuration.rb', line 5 def manifest_file @manifest_file end |
#validate_gems ⇒ Object
Returns the value of attribute validate_gems.
7 8 9 |
# File 'lib/papers/configuration.rb', line 7 def validate_gems @validate_gems end |
#validate_javascript ⇒ Object
Returns the value of attribute validate_javascript.
9 10 11 |
# File 'lib/papers/configuration.rb', line 9 def validate_javascript @validate_javascript end |
Instance Method Details
#validate_gems? ⇒ Boolean
38 39 40 |
# File 'lib/papers/configuration.rb', line 38 def validate_gems? !!@validate_gems end |
#validate_javascript? ⇒ Boolean
42 43 44 |
# File 'lib/papers/configuration.rb', line 42 def validate_javascript? !!@validate_javascript end |