Skip to content
This repository has been archived by the owner on May 18, 2018. It is now read-only.
/ rb-bsdiff Public archive
forked from taf2/rb-bsdiff

Ruby bindings to bindary diff tools bsdiff and bspatch

License

Notifications You must be signed in to change notification settings

cloudability/rb-bsdiff

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

30 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ruby bindings to bsdiff and bspatch

Installation

gem install 'rb-bsdiff'

Or via Gemfile:

gem 'rb-bsdiff'

As this uses native-code extensions you will of course require a working build toolchain. Additionally, you will need the BZip2 libraries to be present on your system. On OSX they should already be present. On Linux, you may need to install relevant packages, for example:

sudo apt-get install libbz2-1.0 libbz2-dev

See http://bzip.org/ for more information.

Usage

  # Generate a patch from ext/b0 to ext/b1 as p0.
  BSDiff.diff('ext/b0', 'ext/b1', 'p0')

  # apply patch p0 to ext/b0 and produce output as b3.  b3 should be
  # identical to ext/b1.
  BSDiff.patch('ext/b0', 'b3', 'p0')

Caveats

As the underlying code only works with files, so does this API. Pass in only filenames for parameters.

License

About

Ruby bindings to bindary diff tools bsdiff and bspatch

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C 82.2%
  • Ruby 17.8%