chef

https://github.com/opscode/chef

Ruby

A systems integration framework, built to bring the benefits of configuration management to your entire infrastructure.

Chef::ResourceCollection::ResourceSet#validate_lookup_spec!

Returns true if +query_object+ is a valid string for looking up a
resource, or raises InvalidResourceSpecification if not.
=== Arguments
* query_object should be a string of the form
"resource_type[resource_name]", a single element Hash (e.g., :service =>
"apache2"), or a Chef::Resource (this is the happy path). Other arguments
will raise an exception.
=== Returns
* true returns true for all valid input.
=== Raises
* Chef::Exceptions::InvalidResourceSpecification for all invalid input.

Source | Google | Stack overflow

Edit

git clone [email protected]:opscode/chef.git

cd chef

open lib/chef/resource_collection/resource_set.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-Chef--ResourceCollection--ResourceSet-validate_lookup_spec--for-pr


# Commit to git

git add lib/chef/resource_collection/resource_set.rbgit commit -m "better docs for Chef::ResourceCollection::ResourceSet#validate_lookup_spec!"


# Open pull request

gem install hub # on a mac you can `brew install hub`

hub fork

git push <your name> -your-name--update-docs-Chef--ResourceCollection--ResourceSet-validate_lookup_spec--for-pr

hub pull-request


# Celebrate!