Commit Graph

219 Commits

Author SHA1 Message Date
Carlos Martín Nieto
3cafc28a35 Merge branch 'config' 2014-05-19 17:08:08 +02:00
Carlos Martín Nieto
8ade44a868 config: string get/set 2014-05-19 13:11:55 +02:00
Carlos Martín Nieto
4b0379f3ee config: expose get_bool/2 2014-05-19 12:55:12 +02:00
Carlos Martín Nieto
d6ad01836f config: another failing test 2014-05-19 12:50:53 +02:00
Carlos Martín Nieto
f568955a95 config: test for setting and getting bool 2014-05-19 12:40:55 +02:00
Carlos Martín Nieto
29d468c90a Add missing files 2014-05-19 12:15:14 +02:00
Carlos Martín Nieto
98b176c925 Add a minimum of config
This lets us revive the reflog test by letting us set
core.logallrefupdates to true.
2014-05-18 12:03:53 +02:00
Carlos Martín Nieto
688c052f6d Temporarily remove a test
libgit2 recently started caring about the reflog rules and as we use a
bare repo for testing, it does not append.
2014-05-18 11:19:15 +02:00
Carlos Martín Nieto
ee41214322 Merge pull request #2 from KlausTrainer/master
Fix compilation errors with Elixir 0.13.0
2014-04-22 16:37:14 +02:00
Klaus Trainer
2b4e2eec01 Fix compilation errors with Elixir 0.13.0 2014-04-22 15:50:25 +02:00
Carlos Martín Nieto
fcec57c84f Fix alloc_binary param order 2014-02-15 19:28:49 +01:00
Carlos Martín Nieto
fe4c72a811 Expose utility ref-type functions
These allow you to determine whether you're dealing with a branch, tag,
note or remote-tracking branch.
2014-02-15 01:38:33 +01:00
Carlos Martín Nieto
1a79093274 Get rid of a few dialyzer warnings 2014-02-14 00:51:06 +01:00
Carlos Martín Nieto
378c04284a Remove left-over debugging code 2014-02-14 00:07:43 +01:00
Carlos Martín Nieto
7b951fec74 Merge branch 'reflog' 2014-02-13 23:32:42 +01:00
Carlos Martín Nieto
73af429633 Add geef_reflog:delete() 2014-02-13 18:26:33 +01:00
Carlos Martín Nieto
5520efb72a Correct the signature output from the reflog
The function to convert signatures into erlang terms was returning ok
with the rest of the tuple which geef_sig expects. We do not want the
ok there, so let that function give us the four terms and decide what to
do in each case.

The signature functions still want to return with ok before it, but the
reflog wants them together with the other parameters.
2014-02-13 18:21:45 +01:00
Carlos Martín Nieto
22ab293910 Basic reflog support
For now it simply includes reading in the reflog as a list of
entries. This does mean that the drop/append functions don't need to be
wrapped, as we can use erlang's list handling.

It however also means that we cannot write this back out, as there is
currently no way to create an empty reflog that we can fill with our own
list.
2014-02-13 17:41:11 +01:00
Carlos Martín Nieto
d9822de604 Extract string->binary conversion 2014-02-13 16:36:10 +01:00
Carlos Martín Nieto
d4204b4b79 Extract signature conversion code 2014-02-13 16:32:46 +01:00
Carlos Martín Nieto
9501ed2377 Add reference has_log() 2014-02-13 14:53:19 +01:00
Carlos Martín Nieto
42d0aef29d Adjust to git_buf and oid->id changes 2014-02-13 14:51:24 +01:00
Carlos Martín Nieto
bb726f90a0 Adjust to reference signature changes
For now we don't use anything significant for the reflog.
2014-02-13 10:50:40 +01:00
Carlos Martín Nieto
adadabdc26 Make sure to set flags to 0 on no option 2014-02-13 02:20:04 +01:00
Carlos Martín Nieto
167666cd23 Listen to dialyzer 2013-11-30 20:43:19 +01:00
Carlos Martín Nieto
9ccf966c58 Merge branch 'create-commit' 2013-11-24 16:34:54 +01:00
Carlos Martín Nieto
568f9b2daf Wrap commit creation in elixir 2013-11-24 16:34:08 +01:00
Carlos Martín Nieto
3110f37ff7 Wrap commit creation 2013-11-24 16:23:01 +01:00
Carlos Martín Nieto
a8078fba69 Commit: grab the tree 2013-10-26 02:44:05 +02:00
Carlos Martín Nieto
c2e64e7fc8 Fix typo 2013-10-17 10:29:13 +02:00
Carlos Martín Nieto
fd390306b3 Also alias Geef.Signature 2013-10-16 16:10:53 +02:00
Carlos Martín Nieto
6c272e2c30 index: write out all fields to disc
There is still now way to access what the flags mean, and the times
need to be in pure timestamp form, rather than erlang's.

Non-essential fields are allowed to be 'undefined' and then the
entry's field will remain zeroed.
2013-10-16 15:01:16 +02:00
Carlos Martín Nieto
179f424bb5 index: grab all of the fields from C-land 2013-10-16 14:23:38 +02:00
Carlos Martín Nieto
3c9e429038 Remove old signature test 2013-10-16 14:23:03 +02:00
Carlos Martín Nieto
c511675d59 Merge branch 'revparse' 2013-10-16 13:58:20 +02:00
Carlos Martín Nieto
b930c1519f nif: add support for CFLAGS 2013-10-16 13:27:40 +02:00
Carlos Martín Nieto
05e1781356 More sensible signature functions
Remove all of the older functions. Bind git_signature_default() and
implement the _now() equivalent in erlang.
2013-10-15 22:31:13 +02:00
Carlos Martín Nieto
ec63e08780 Correctly identify which object type we're trying to transform 2013-09-05 15:37:01 +02:00
Carlos Martín Nieto
21464aeece Wrap git_revparse_single 2013-09-05 15:37:01 +02:00
Carlos Martín Nieto
72078cb099 Wrap ref creation in elixir 2013-09-04 01:16:50 +02:00
Carlos Martín Nieto
ee1d719ef4 Remove some dead code 2013-09-03 20:42:28 +02:00
Carlos Martín Nieto
0d24afb089 Get rid of the tagged OID
This means we no longer accept any iolist in some of the functions,
but we might bring it back later.

There is also a new function, geef_ref:create_symbolic() to create
symbolic references, since we can no longer differentiate between a
name and an OID.
2013-09-03 20:37:00 +02:00
Carlos Martín Nieto
a400d3ca85 Introduce an elixir OID type
This is still fairly experimental.
2013-09-02 20:10:56 +02:00
Carlos Martín Nieto
895041b2a7 tests: properly setup and teardown 2013-09-02 20:10:38 +02:00
Carlos Martín Nieto
8f9ca440d9 Fix geef_ref:resolve/1
We never updated what the NIF returns, and we were making a lookup too
many by trying to load the reference which we already have.
2013-09-02 20:08:58 +02:00
Carlos Martín Nieto
9e4826741c Add a tiny elixir test 2013-09-02 02:18:41 +02:00
Carlos Martín Nieto
5ada4fe0c1 Warp geef_index in elixir 2013-09-01 20:26:11 +02:00
Carlos Martín Nieto
15ba2dd65f Add support for index_entry's size field 2013-09-01 19:56:35 +02:00
Carlos Martín Nieto
e39a17fe43 Allow retrieval of index entries
This is still very basic, as we only actually load three fields into
the record.
2013-09-01 15:30:15 +02:00
Carlos Martín Nieto
808a8176bc Make dialyzer happy 2013-08-31 17:57:55 +02:00