Sha256: b26dcd4ff43646cc9cbf35ae97e5703fe1a2791d5d27123833f7f9302d947e90

Contents?: true

Size: 764 Bytes

Versions: 1

Compression:

Stored size: 764 Bytes

Contents

module Pod
  class Installer
    def _set_permissions(permissions)
      installer = installer_rep
      for pod in installer.pods
        # if the pod is actually in Pods/, and not a :path linked pod
        if pod.root.parent == installer.sandbox_root
          for file in pod.source_files
            File.chmod(permissions, file)
          end
        end
      end
    end
    
    alias_method :real_perform_post_install_actions, :perform_post_install_actions
    def perform_post_install_actions
      real_perform_post_install_actions
      _set_permissions(0444)
    end
    
    alias_method :real_run_pre_install_hooks, :run_pre_install_hooks
    def run_pre_install_hooks
      real_run_pre_install_hooks
      _set_permissions(0644)
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
cocoapods-readonly-1.0.0 lib/cocoapods-readonly/toggle_readonly.rb