aboutsummaryrefslogtreecommitdiff
path: root/hyde.rb
diff options
context:
space:
mode:
authorAlessandro Iezzi <aiezzi@alessandroiezzi.it>2024-04-24 15:36:13 +0200
committerAlessandro Iezzi <aiezzi@alessandroiezzi.it>2024-04-25 11:33:30 +0200
commit56e06420ca9b211304802118f355fb0c3139fa06 (patch)
treee364753422321a10bb7467db1594f7b8de9452e8 /hyde.rb
parent8fc9304e3b1185ce3140c6fac35e877aed8fbd7d (diff)
downloadhyde-56e06420ca9b211304802118f355fb0c3139fa06.tar.gz
hyde-56e06420ca9b211304802118f355fb0c3139fa06.zip
Move the config parser inside Page class
Diffstat (limited to 'hyde.rb')
-rwxr-xr-xhyde.rb17
1 files changed, 0 insertions, 17 deletions
diff --git a/hyde.rb b/hyde.rb
index d64872c..c2bb412 100755
--- a/hyde.rb
+++ b/hyde.rb
@@ -58,26 +58,9 @@ Considerations on file formats.
=end
-# Every file needs a config file. It is similar to the YAML block in head to files processed by gohugo or jekyll.
-configfile = options[:fileName] + '.config'
-if(!File.exist?(configfile) && !options[:fileName].end_with?("tmpl"))
- puts 'Cannot find configuration file: ' + configfile
- exit 1
-end
-if(File.exist?(configfile))
- config = YAML.load_file(configfile)
- if(config != nil)
- title = config['title']
- pageNames = config['pageNames']
- description = config['description']
- classes = config['classes']
- master = config['master']
- category = config['category']
- end
-end
page = Page.new(title, options[:fileName], pageNames, description, nil, classes, category)