Project

net_dav

0.09
Repository is archived
No release in over 3 years
Low commit activity in last 3 years
There's a lot of open issues
WebDAV client library in the style of Net::HTTP, using Net::HTTP and libcurl, if installed
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.12
~> 10.0
>= 0

Runtime

 Project Readme

NOTE: NO LONGER ACTIVELY MAINTAINED¶ ↑

Net::Dav library, in the style of Net::HTTP <img src=“https://travis-ci.org/devrandom/net_dav.svg?branch=master” alt=“Build Status” />

Install¶ ↑

Installing the gem:

gem install net_dav

and if you want acceleration for large files (from 4MB/s to 20MB/s in my setup):

gem install curb

If you’re having install issues with nokogiri on Mac OS X read wiki.github.com/tenderlove/nokogiri/what-to-do-if-libxml2-is-being-a-jerk

Usage¶ ↑

require 'net/dav'

Net::DAV.start("https://localhost.localdomain/xyz/") do |dav|
  dav.find('.', :recursive => true) do |item|
    item.content = item.content.gsub(/silly/i, 'funny')
  end
end

(Note that if you want to use “.” to refer to the origin URL, it should end with a slash, otherwise it is assumed that the last component is a file and “.” will refer to the parent.)

Documentation¶ ↑

RDoc: rdoc.info/projects/devrandom/net_dav Wiki: wiki.github.com/devrandom/net_dav

Performance¶ ↑

This should be threadsafe if you use a different Net::DAV object for each thread. Check out script/multi-test for a multi-threaded application.

Installing the curb gem will gain speedup with large files, but currently is much slower doing many small get operations. If your usecase is the latter and you have curb installed, you can disable its use by passing the

:curl => false

option to Net::DAV::start or Net::DAV::new .

Other¶ ↑

Thanks go to Thomas ( github.com/thomasfl/ ) and others for their help.

Thomas is writing the easy to use github.com/thomasfl/open-uri-and-write based on net_dav.