Skip to content

Commit 03a4c4c

Browse files
committed
Merge pull request #33 from nodegit/latest-0.5.0
Bump docs to 0.5.0
2 parents 03dc34d + 7cb4aa2 commit 03a4c4c

File tree

111 files changed

+1281
-555
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

111 files changed

+1281
-555
lines changed

_config.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@ title: NodeGit
33
description: Asynchronous native Node bindings to libgit2
44
url: "http://nodegit.org"
55
date_format: "ordinal"
6-
current_nodegit_version: 0.4.1
6+
current_nodegit_version: 0.5.0
77
other_nodegit_versions:
88
- HEAD
9+
- 0.4.1
910
- 0.4.0
1011
- 0.3.3
1112
- 0.2.7

api/annotated_commit/index.md

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@
22
layout: default
33
menu_item: api
44
title: AnnotatedCommit
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/
99
sections:
1010
"fromFetchhead": "#fromFetchhead"
1111
"fromRef": "#fromRef"
12+
"fromRevspec": "#fromRevspec"
1213
"lookup": "#lookup"
1314
"#free": "#free"
1415
"#id": "#id"
@@ -27,7 +28,7 @@ AnnotatedCommit.fromFetchhead(repo, branch_name, remote_url, id).then(function(a
2728
| repo | [Repository](/api/repository/) | repository that contains the given commit |
2829
| branch_name | String | name of the (remote) branch |
2930
| remote_url | String | url of the remote |
30-
| id | [Oid](/api/oid/) | |
31+
| id | [Oid](/api/oid/) | the commit object id of the remote branch |
3132

3233
| Returns | |
3334
| --- | --- |
@@ -50,6 +51,23 @@ AnnotatedCommit.fromRef(repo, ref).then(function(annotatedCommit) {
5051
| --- | --- |
5152
| [AnnotatedCommit](/api/annotated_commit/) | |
5253

54+
## <a name="fromRevspec"></a><span>AnnotatedCommit.</span>fromRevspec <span class="tags"><span class="async">Async</span><span class="experimental">Experimental</span></span>
55+
56+
```js
57+
AnnotatedCommit.fromRevspec(repo, revspec).then(function(annotatedCommit) {
58+
// Use annotatedCommit
59+
});
60+
```
61+
62+
| Parameters | Type | |
63+
| --- | --- | --- |
64+
| repo | [Repository](/api/repository/) | repository that contains the given commit |
65+
| revspec | String | the extended sha syntax string to use to lookup the commit |
66+
67+
| Returns | |
68+
| --- | --- |
69+
| [AnnotatedCommit](/api/annotated_commit/) | |
70+
5371
## <a name="lookup"></a><span>AnnotatedCommit.</span>lookup <span class="tags"><span class="async">Async</span><span class="experimental">Experimental</span></span>
5472

5573
```js

api/attr/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
layout: default
33
menu_item: api
44
title: Attr
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/

api/blame/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
layout: default
33
menu_item: api
44
title: Blame
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/

api/blame_hunk/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
layout: default
33
menu_item: api
44
title: BlameHunk
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/

api/blame_options/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
layout: default
33
menu_item: api
44
title: BlameOptions
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/

api/blob/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
layout: default
33
menu_item: api
44
title: Blob
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/

api/branch/index.md

Lines changed: 21 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,13 @@
22
layout: default
33
menu_item: api
44
title: Branch
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/
99
sections:
1010
"create": "#create"
11+
"createFromAnnotated": "#createFromAnnotated"
1112
"delete": "#delete"
1213
"isHead": "#isHead"
1314
"iteratorNew": "#iteratorNew"
@@ -22,7 +23,7 @@ sections:
2223
## <a name="create"></a><span>Branch.</span>create <span class="tags"><span class="async">Async</span></span>
2324

2425
```js
25-
Branch.create(repo, branch_name, target, force, signature, log_message).then(function(reference) {
26+
Branch.create(repo, branch_name, target, force).then(function(reference) {
2627
// Use reference
2728
});
2829
```
@@ -33,13 +34,28 @@ Branch.create(repo, branch_name, target, force, signature, log_message).then(fun
3334
| branch_name | String | Name for the branch; this name is validated for consistency. It should also not conflict with an already existing branch name. |
3435
| target | [Commit](/api/commit/) | Commit to which this branch should point. This object must belong to the given `repo`. |
3536
| force | Number | Overwrite existing branch. |
36-
| signature | [Signature](/api/signature/) | The identity that will used to populate the reflog entry |
37-
| log_message | String | The one line long message to be appended to the reflog. If NULL, the default is "Branch: created"; if you want something more useful, provide a message. |
3837

3938
| Returns | |
4039
| --- | --- |
4140
| [Reference](/api/reference/) | the underlying reference. |
4241

42+
## <a name="createFromAnnotated"></a><span>Branch.</span>createFromAnnotated <span class="tags"><span class="sync">Sync</span></span>
43+
44+
```js
45+
var reference = Branch.createFromAnnotated(repository, branch_name, commit, force);
46+
```
47+
48+
| Parameters | Type | |
49+
| --- | --- | --- |
50+
| repository | [Repository](/api/repository/) | |
51+
| branch_name | String | |
52+
| commit | [AnnotatedCommit](/api/annotated_commit/) | |
53+
| force | Number | |
54+
55+
| Returns | |
56+
| --- | --- |
57+
| [Reference](/api/reference/) | |
58+
4359
## <a name="delete"></a><span>Branch.</span>delete <span class="tags"><span class="sync">Sync</span></span>
4460

4561
```js
@@ -107,7 +123,7 @@ Branch.lookup(repo, branch_name, branch_type).then(function(reference) {
107123
## <a name="move"></a><span>Branch.</span>move <span class="tags"><span class="async">Async</span></span>
108124

109125
```js
110-
Branch.move(branch, new_branch_name, force, signature, log_message).then(function(reference) {
126+
Branch.move(branch, new_branch_name, force).then(function(reference) {
111127
// Use reference
112128
});
113129
```
@@ -117,8 +133,6 @@ Branch.move(branch, new_branch_name, force, signature, log_message).then(functio
117133
| branch | [Reference](/api/reference/) | Current underlying reference of the branch. |
118134
| new_branch_name | String | Target name of the branch once the move is performed; this name is validated for consistency. |
119135
| force | Number | Overwrite existing branch. |
120-
| signature | [Signature](/api/signature/) | The identity that will used to populate the reflog entry |
121-
| log_message | String | The one line long message to be appended to the reflog |
122136

123137
| Returns | |
124138
| --- | --- |

api/buf/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
layout: default
33
menu_item: api
44
title: Buf
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/

api/cert/index.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
layout: default
33
menu_item: api
44
title: Cert
5-
description: Version 0.4.1
5+
description: Version 0.5.0
66
menu_item: api
77
return_to:
88
"API Documentation Index": /api/
@@ -23,8 +23,10 @@ sections:
2323

2424
| Flag | Value |
2525
| --- | --- | --- |
26-
| <span>Cert.TYPE.</span>X509 | 0 |
27-
| <span>Cert.TYPE.</span>HOSTKEY_LIBSSH2 | 1 |
26+
| <span>Cert.TYPE.</span>NONE | 0 |
27+
| <span>Cert.TYPE.</span>X509 | 1 |
28+
| <span>Cert.TYPE.</span>HOSTKEY_LIBSSH2 | 2 |
29+
| <span>Cert.TYPE.</span>STRARRAY | 3 |
2830

2931
## <a name="ivars"></a>Instance Variables
3032

0 commit comments

Comments
 (0)