Module: EasyCaddy::Paths
- Defined in:
- lib/easy_caddy/paths.rb
Class Method Summary collapse
- .brew_caddyfile ⇒ Object
- .caddyfile ⇒ Object
- .disabled_dir ⇒ Object
- .disabled_file(name) ⇒ Object
- .registry ⇒ Object
- .root ⇒ Object
- .site_file(name) ⇒ Object
- .sites_dir ⇒ Object
Class Method Details
.brew_caddyfile ⇒ Object
13 |
# File 'lib/easy_caddy/paths.rb', line 13 def self.brew_caddyfile = Pathname.new('/opt/homebrew/etc/Caddyfile') |
.caddyfile ⇒ Object
12 |
# File 'lib/easy_caddy/paths.rb', line 12 def self.caddyfile = root.join('Caddyfile') |
.disabled_dir ⇒ Object
10 |
# File 'lib/easy_caddy/paths.rb', line 10 def self.disabled_dir = root.join('disabled') |
.disabled_file(name) ⇒ Object
16 |
# File 'lib/easy_caddy/paths.rb', line 16 def self.disabled_file(name) = disabled_dir.join("#{name}.caddy") |
.registry ⇒ Object
11 |
# File 'lib/easy_caddy/paths.rb', line 11 def self.registry = root.join('ecaddy.yml') |
.root ⇒ Object
5 6 7 |
# File 'lib/easy_caddy/paths.rb', line 5 def self.root Pathname.new(ENV.fetch('ECADDY_HOME', File.join(Dir.home, '.config', 'caddy'))) end |
.site_file(name) ⇒ Object
15 |
# File 'lib/easy_caddy/paths.rb', line 15 def self.site_file(name) = sites_dir.join("#{name}.caddy") |
.sites_dir ⇒ Object
9 |
# File 'lib/easy_caddy/paths.rb', line 9 def self.sites_dir = root.join('sites') |