Mark Probst
e439b931a6
Default signature
2015-03-04 15:52:57 -08:00
Carlos Martín Nieto
a9d993f3d1
Remove useless includes
2014-12-11 02:59:07 +01:00
Carlos Martín Nieto
8c631b0c25
Add missing thread locking
2014-12-06 02:45:26 +01:00
Carlos Martín Nieto
668aa5dae1
Make the constants have types
...
While Go will assign the correct type to a const block when it
auto-creates the values, assigning makes the const be typeless and will
only gain it in each particular use.
Make each constant in the blocks have an assigned type.
2014-10-28 11:29:31 +01:00
Carlos Martín Nieto
8a73c75f1a
Keep a pointer to the repository in the objects and references
...
Otherwise, the garbage collector might decide it's a good idea to throw
away the repository instance while the C object still has a pointer to
it. Hilarity ensues.
2014-05-26 09:28:07 +02:00
Carlos Martín Nieto
2942e18d05
Give Object and Reference an Onwer accessor
...
This reduces the need to carry around a pointer to the repository as
well as the objects.
2014-05-25 09:12:10 +02:00
Carlos Martín Nieto
22bcd7decf
Reference: expose Peel()
...
Peel a reference to a particular type of object, returning an Object,
which you then perform a type assertion on.
2014-05-23 11:37:00 +02:00
Jesse Ezell
fc999289a2
Merge branch 'oid-parse-protection' into branch-iterator
2014-04-04 00:50:41 -07:00
Jesse Ezell
39f59d921b
fix typo / return name iterator
2014-04-04 00:27:07 -07:00
Jesse Ezell
b660db0a4b
make it possible to handle errors
2014-04-02 10:31:48 -07:00
Jesse Ezell
5590078e6f
remove channel based iteration for branch / ref. Add ReferenceNameIterator. All iterators use Next(). Remove interfaces.
2014-03-20 20:28:41 -07:00
Jesse Ezell
37b950bc90
various improvements to interface
2014-03-19 20:24:19 -07:00
Jesse Ezell
27bea93efe
split out name iterator
2014-03-19 00:36:00 -07:00
Jesse Ezell
006286edb7
remove Branch struct, unify reference iterators
2014-03-19 00:19:02 -07:00
Jesse Ezell
5f01bd7abd
add branch iterator / remove useless repo from reference iterator
2014-03-12 15:49:11 -07:00
Carlos Martín Nieto
fc6d0fbfff
Merge pull request #59 from libgit2/cmn/refs
...
Add a few reference utility functions
2014-02-27 17:03:39 +01:00
Carlos Martín Nieto
c431fe3c2c
Merge pull request #60 from libgit2/cmn/reflogs-default
...
Allow for a default in reflog messages
2014-02-27 17:03:20 +01:00
Carlos Martín Nieto
00ea11691b
Convert the rest of the errors
2014-02-26 16:14:31 +01:00
Jesper Hansen
499f52a354
Added git error code to the error object.
2014-02-26 16:10:00 +01:00
Carlos Martín Nieto
2c8de242ee
Allow for a default in reflog messages
...
We don't have a way to represent a NULL string, so if the user passes an
empty string, let's pass NULL down so we tell libgit2 to use the default.
2014-02-26 15:01:23 +01:00
Carlos Martín Nieto
ca2c3c6db2
Add a few reference utility functions
2014-02-26 14:51:04 +01:00
Carlos Martín Nieto
8efcdd0e16
Merge pull request #55 from lye/add-is-x-reference-methods
...
Add Is$Type methods to Reference.
2014-02-23 15:43:02 +01:00
Carlos Martín Nieto
1b09b03c0e
Merge commit 'refs/pull/53/head' of github.com:libgit2/git2go
...
On top: fix git_buf handling and rename signature
This fixes #57 , #54 .
Conflicts:
git.go
reference.go
repository.go
submodule.go
2014-02-23 15:31:22 +01:00
lye
53b5ecacbe
Add Is$Type methods to Reference.
...
This patch adds the following methods to Reference:
IsBranch() bool
IsRemote() bool
IsTag() bool
which correspond to the `git_reference_is_$type` functions in libgit2.
2014-02-20 00:28:31 -06:00
Aidan Nulman
f66502aaf4
update git2go to support latest libgit2 development commit (id: 66af84)
2014-01-29 18:01:26 -05:00
Carlos Martín Nieto
a40bdfd420
Lock the OS thread when acessing errors
...
The library stores error information in thread-local storage, which
means we need to make sure that the Go runtime doesn't switch OS
threads between the time we call a function and th time we attempt to
retrieve the error information.
2013-12-18 16:18:32 +01:00
Carlos Martín Nieto
a5ad8de506
Don't repeat the pkg-config line
...
This is only needed once per package. Having it on every file makes the
build system ask about it n times, which is silly.
2013-11-14 00:23:04 +01:00
Vicent Martí
6c97b9ac9d
Merge pull request #36 from libgit2/ref-iter
...
reference: get references out of the iterator
2013-09-17 08:03:50 -07:00
Carlos Martín Nieto
b5aca803db
Give each const group a type
...
This allows us to restrict which constants the compiler will allow
through, and makes the sorting in the documentation better.
2013-09-12 10:46:20 +02:00
Carlos Martín Nieto
00e3df94c7
Camel-case constants
...
Make the names look more like what you'd expect from Go.
2013-09-12 10:40:57 +02:00
Carlos Martín Nieto
4abda3a60b
reference: get references out of the iterator
...
Allow getting references out of the iterator instead of just names.
2013-08-09 18:22:26 +02:00
Carlos Martín Nieto
f5fc7e5f78
Reference: adjust to iterator changes
...
The Library's iterators now can return either the reference or the
reference's name. As the name is what we're set up for, rename the
functions appropriately so we compile against altest development.
2013-06-17 02:08:13 +02:00
Carlos Martín Nieto
931f187301
Implement a reference iterator
...
Wrap the reference iterators, and provide a Iter() function to get
them through a channel.
2013-05-23 11:13:42 +02:00
Carlos Martín Nieto
0b2f16665d
Wrap immutable refs
2013-03-07 21:01:21 +01:00