From 1cd0209aec84b0135adbe6b5fc2769f0053c26f3 Mon Sep 17 00:00:00 2001 From: Hunter Haugen Date: Wed, 17 Aug 2016 10:27:54 -0700 Subject: Add pry() function from hunner-pry --- README.markdown | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'README.markdown') diff --git a/README.markdown b/README.markdown index a6b7bda..3039a2a 100644 --- a/README.markdown +++ b/README.markdown @@ -935,6 +935,20 @@ For example: *Type*: rvalue. +#### `pry` + +This function invokes a pry debugging session in the current scope object. This is useful for debugging manifest code at specific points during a compilation. Should only be used when running `puppet apply` or running a puppet master in the foreground. This requires the `pry` gem to be installed in puppet's rubygems. + +*Examples:* +```puppet +pry() +``` +Once in a pry session, some interesting commands: + +* Run `catalog` to see the contents currently compiling catalog +* Run `cd catalog` and `ls` to see catalog methods and instance variables +* Run `@resource_table` to see the current catalog resource table + #### `assert_private` Sets the current class or definition as private. Calling the class or definition from outside the current module will fail. -- cgit v1.2.3