Skip to content

Commit f59ae8e

Browse files
committed
chore: re-run generate-docs.js
1 parent 5d49f51 commit f59ae8e

File tree

4 files changed

+88
-42
lines changed

4 files changed

+88
-42
lines changed

docs/hashBlob.md

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---
2+
title: hashBlob
3+
sidebar_label: hashBlob
4+
---
5+
6+
Compute what the SHA-1 object id of a file would be
7+
8+
| param | type [= default] | description |
9+
| ---------- | --------------------------- | -------------------------------------------------------------------------------------------------------- |
10+
| core | string = 'default' | The plugin core identifier to use for plugin injection |
11+
| **object** | Buffer | string | The object to write. If `object` is a String then it will be converted to a Buffer using UTF-8 encoding. |
12+
| return | Promise\<{HashBlobResult}\> | Resolves successfully with the SHA-1 object id and the wrapped object Buffer. |
13+
14+
The object returned has the following schema:
15+
16+
```ts
17+
type HashBlobResult = {
18+
oid: string; // The SHA-1 object id
19+
type: 'blob'; // The type of the object
20+
object: Buffer; // The wrapped git object (the thing that is hashed)
21+
format: 'wrapped'; // The format of the object
22+
}
23+
```
24+
25+
Example Code:
26+
27+
```js live
28+
let { oid, type, object, format } = await git.hashBlob({
29+
object: '$input((Hello world!))',
30+
})
31+
32+
console.log('oid', oid)
33+
console.log('type', type)
34+
console.log('object', object)
35+
console.log('format', format)
36+
```
37+
38+
<script>
39+
(function rewriteEditLink() {
40+
const el = document.querySelector('a.edit-page-link.button');
41+
if (el) {
42+
el.href = 'https://github.com/isomorphic-git/isomorphic-git/edit/master/src/commands/hashBlob.js';
43+
}
44+
})();
45+
</script>

docs/pull.md

Lines changed: 19 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -5,24 +5,25 @@ sidebar_label: pull
55

66
Fetch and merge commits from a remote repository *(Currently, only fast-forward merges are implemented.)*
77

8-
| param | type [= default] | description |
9-
| -------------------- | ------------------------- | --------------------------------------------------------------------------------------------------------- |
10-
| core | string = 'default' | The plugin core identifier to use for plugin injection |
11-
| fs [deprecated] | FileSystem | The filesystem containing the git repo. Overrides the fs provided by the [plugin system](./plugin_fs.md). |
12-
| **dir** | string | The [working tree](dir-vs-gitdir.md) directory path |
13-
| **gitdir** | string = join(dir,'.git') | The [git directory](dir-vs-gitdir.md) path |
14-
| ref | string | Which branch to fetch. By default this is the currently checked out branch. |
15-
| singleBranch | boolean = false | Instead of the default behavior of fetching all the branches, only fetch a single branch. |
16-
| fastForwardOnly | boolean = false | Only perform simple fast-forward merges. (Don't create merge commits.) |
17-
| noGitSuffix | boolean = false | If true, do not auto-append a `.git` suffix to the `url`. (**AWS CodeCommit needs this option**) |
18-
| username | string | See the [Authentication](./authentication.html) documentation |
19-
| password | string | See the [Authentication](./authentication.html) documentation |
20-
| token | string | See the [Authentication](./authentication.html) documentation |
21-
| oauth2format | string | See the [Authentication](./authentication.html) documentation |
22-
| headers | object | Additional headers to include in HTTP requests, similar to git's `extraHeader` config |
23-
| emitter [deprecated] | EventEmitter | Overrides the emitter set via the ['emitter' plugin](./plugin_emitter.md). |
24-
| emitterPrefix | string = '' | Scope emitted events by prepending `emitterPrefix` to the event name. |
25-
| return | Promise\<void\> | Resolves successfully when pull operation completes |
8+
| param | type [= default] | description |
9+
| -------------------- | ------------------------- | ---------------------------------------------------------------------------------------------------------- |
10+
| core | string = 'default' | The plugin core identifier to use for plugin injection |
11+
| fs [deprecated] | FileSystem | The filesystem containing the git repo. Overrides the fs provided by the [plugin system](./plugin_fs.md). |
12+
| **dir** | string | The [working tree](dir-vs-gitdir.md) directory path |
13+
| **gitdir** | string = join(dir,'.git') | The [git directory](dir-vs-gitdir.md) path |
14+
| ref | string | Which branch to fetch. By default this is the currently checked out branch. |
15+
| corsProxy | string | Optional [CORS proxy](https://www.npmjs.com/%40isomorphic-git/cors-proxy). Overrides value in repo config. |
16+
| singleBranch | boolean = false | Instead of the default behavior of fetching all the branches, only fetch a single branch. |
17+
| fastForwardOnly | boolean = false | Only perform simple fast-forward merges. (Don't create merge commits.) |
18+
| noGitSuffix | boolean = false | If true, do not auto-append a `.git` suffix to the `url`. (**AWS CodeCommit needs this option**) |
19+
| username | string | See the [Authentication](./authentication.html) documentation |
20+
| password | string | See the [Authentication](./authentication.html) documentation |
21+
| token | string | See the [Authentication](./authentication.html) documentation |
22+
| oauth2format | string | See the [Authentication](./authentication.html) documentation |
23+
| headers | object | Additional headers to include in HTTP requests, similar to git's `extraHeader` config |
24+
| emitter [deprecated] | EventEmitter | Overrides the emitter set via the ['emitter' plugin](./plugin_emitter.md). |
25+
| emitterPrefix | string = '' | Scope emitted events by prepending `emitterPrefix` to the event name. |
26+
| return | Promise\<void\> | Resolves successfully when pull operation completes |
2627

2728
To monitor progress events, see the documentation for the [`'emitter'` plugin](./plugin_emitter.md).
2829

docs/readObject.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@ sidebar_label: readObject
55

66
Read a git object directly by its SHA-1 object id
77

8-
| param | type [= default] | description |
9-
| --------------- | -------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
10-
| core | string = 'default' | The plugin core identifier to use for plugin injection |
11-
| fs [deprecated] | FileSystem | The filesystem containing the git repo. Overrides the fs provided by the [plugin system](./plugin_fs.md). |
12-
| dir | string | The [working tree](dir-vs-gitdir.md) directory path |
13-
| **gitdir** | string = join(dir,'.git') | The [git directory](dir-vs-gitdir.md) path |
14-
| **oid** | string | The SHA-1 object id to get |
15-
| format | 'deflated' | 'wrapped' | 'content' | 'parsed' = 'parsed' | What format to return the object in. The choices are described in more detail below. |
16-
| filepath | string | Don't return the object with `oid` itself, but resolve `oid` to a tree and then return the object at that filepath. To return the root directory of a tree set filepath to `''` |
17-
| encoding | string | A convenience argument that only affects blobs. Instead of returning `object` as a buffer, it returns a string parsed using the given encoding. |
18-
| return | Promise\<GitObjectDescription\> | Resolves successfully with a git object description |
8+
| param | type [= default] | description |
9+
| --------------- | ----------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
10+
| core | string = 'default' | The plugin core identifier to use for plugin injection |
11+
| fs [deprecated] | FileSystem | The filesystem containing the git repo. Overrides the fs provided by the [plugin system](./plugin_fs.md). |
12+
| dir | string | The [working tree](dir-vs-gitdir.md) directory path |
13+
| **gitdir** | string = join(dir,'.git') | The [git directory](dir-vs-gitdir.md) path |
14+
| **oid** | string | The SHA-1 object id to get |
15+
| format | 'deflated' &#124; 'wrapped' &#124; 'content' &#124; 'parsed' = 'parsed' | What format to return the object in. The choices are described in more detail below. |
16+
| filepath | string | Don't return the object with `oid` itself, but resolve `oid` to a tree and then return the object at that filepath. To return the root directory of a tree set filepath to `''` |
17+
| encoding | string | A convenience argument that only affects blobs. Instead of returning `object` as a buffer, it returns a string parsed using the given encoding. |
18+
| return | Promise\<GitObjectDescription\> | Resolves successfully with a git object description |
1919

2020
The object returned has the following schema:
2121

0 commit comments

Comments
 (0)