Class: Ace::Handbook::Organisms::SkillInventory
- Inherits:
-
Object
- Object
- Ace::Handbook::Organisms::SkillInventory
- Defined in:
- lib/ace/handbook/organisms/skill_inventory.rb
Constant Summary collapse
- FRONTMATTER_PATTERN =
/\A---\s*\n(.*?)\n---\s*\n?(.*)\z/m
Instance Attribute Summary collapse
-
#project_root ⇒ Object
readonly
Returns the value of attribute project_root.
Instance Method Summary collapse
- #all ⇒ Object
-
#initialize(project_root: Ace::Handbook.project_root) ⇒ SkillInventory
constructor
A new instance of SkillInventory.
Constructor Details
#initialize(project_root: Ace::Handbook.project_root) ⇒ SkillInventory
Returns a new instance of SkillInventory.
16 17 18 |
# File 'lib/ace/handbook/organisms/skill_inventory.rb', line 16 def initialize(project_root: Ace::Handbook.project_root) @project_root = project_root end |
Instance Attribute Details
#project_root ⇒ Object (readonly)
Returns the value of attribute project_root.
14 15 16 |
# File 'lib/ace/handbook/organisms/skill_inventory.rb', line 14 def project_root @project_root end |
Instance Method Details
#all ⇒ Object
20 21 22 |
# File 'lib/ace/handbook/organisms/skill_inventory.rb', line 20 def all skill_paths.filter_map { |path| parse_skill(path) } end |