diff options
author | yorah <yoram.harmelin@gmail.com> | 2013-01-11 19:42:42 +0400 |
---|---|---|
committer | yorah <yoram.harmelin@gmail.com> | 2013-12-13 17:26:41 +0400 |
commit | 36d40bd80e858004c3c8b92553082e3ceca4cf46 (patch) | |
tree | fcb428288a08894ae4b7264a386bbb237d851e71 /LibGit2Sharp/Core/StringExtensions.cs | |
parent | f2d5b19c35d703738d406d48e6c63b679246513d (diff) |
Add archive as tar functionality
Implemented as an extension method of `ObjectDatabase`.
Lots of logic taken from [archive-tar.c](https://github.com/git/git/blob/master/archive-tar.c).
Diffstat (limited to 'LibGit2Sharp/Core/StringExtensions.cs')
-rw-r--r-- | LibGit2Sharp/Core/StringExtensions.cs | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/LibGit2Sharp/Core/StringExtensions.cs b/LibGit2Sharp/Core/StringExtensions.cs new file mode 100644 index 00000000..2d557e23 --- /dev/null +++ b/LibGit2Sharp/Core/StringExtensions.cs @@ -0,0 +1,12 @@ +using System; + +namespace LibGit2Sharp.Core +{ + internal static class StringExtensions + { + public static int OctalToInt32(this string octal) + { + return Convert.ToInt32(octal, 8); + } + } +} |