https://github.com/krmao/bspatch
To run the example project, clone the repo, and run pod install
from the Example directory first.
bspatch-ios is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'bspatch-ios'
the details please see the exmples project
#import "BSPatch.h"
// bsdiff
int bsdiffResult = bsdiff([oldPath UTF8String], [newPath UTF8String], [patchPath UTF8String]);
NSLog(@"bsdiffResult = %d", bsdiffResult);
NSData *patchData = [NSData dataWithContentsOfFile:patchPath];
NSLog(@"patchData = %@", patchData);
// bspatch
int bspatchResult = bspatch([oldPath UTF8String], [new2Path UTF8String], [patchPath UTF8String]);
NSLog(@"bspatchResult = %d", bspatchResult);
- new repository of github
- pod lib create bspatch-ios
- add/change code
- check code lint
- pod lib lint bspatch-ios.podspec --allow-warnings
- change the version in bspatch-ios.podspec
- s.version = '0.1.0'
- add/push new tag, tag name == new version
- git tag 0.1.0 && git push --tags
- pod trunk register "kr.mao@qq.com" "krmao" --description="ios libs of krmao"
- pod trunk push bspatch-ios.podspec --allow-warnings
- check is pushed success
krmao, kr.mao@qq.com
bspatch-ios is available under the MIT license. See the LICENSE file for more info.