chef

https://github.com/opscode/chef

Ruby

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

Chef::CookbookSynchronizer#sync_file

Sync an individual file if needed. If there is an up to date copy
locally, nothing is done. Updates +file+'s manifest with the full path to
the cached file.

=== Arguments
file<CookbookFile>
=== Returns
Full path to the cached file as a String

Source | Google | Stack overflow

Edit

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

cd chef

open lib/chef/cookbook/synchronizer.rb

Contribute

# Make a new branch

git checkout -b -your-name--update-docs-Chef--CookbookSynchronizer-sync_file-for-pr


# Commit to git

git add lib/chef/cookbook/synchronizer.rbgit commit -m "better docs for Chef::CookbookSynchronizer#sync_file"


# 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--CookbookSynchronizer-sync_file-for-pr

hub pull-request


# Celebrate!