def inject_podfile_post_install_hook(context)
        podfile = context.podfile
        previous_block = podfile.instance_variable_get(:@post_install_callback)
        
        new_callback = lambda do |installer|
            @pod_project = installer.pods_project
            @sandbox_root = installer.sandbox.root
            prune!
            previous_block.call(installer) if previous_block
        end
        
        if previous_block
            podfile.instance_variable_set(:@post_install_callback, new_callback)
        else
            podfile.post_install do |installer|
                new_callback.call(installer)
            end
        end
    end
def inject_podfile_post_install_hook(context)
        podfile = context.podfile
        previous_block = podfile.instance_variable_get(:@post_install_callback)
        
        new_callback = lambda do |installer|
            @pod_project = installer.pods_project
            @sandbox_root = installer.sandbox.root
            prune!
            previous_block.call(installer) if previous_block
        end
        
        if previous_block
            podfile.instance_variable_set(:@post_install_callback, new_callback)
        else
            podfile.post_install do |installer|
                new_callback.call(installer)
            end
        end
    end
Because the pre_install hook is executed before anything at all is generated
The plugin hooks to the Podfile's post_install hook, which (as documented)
happens after the Project is generated but before is saved, a perfect spot for this