Skip to content

Commit b55ae60

Browse files
ARBhosaleaniket.bhosale
authored andcommitted
feat: Non-blocking checkout (#2108)
* feat: Non-blocking checkout * removing console logs; changing dummy repo URL * removing disabled test and perf time recording * using isomorphic-git's dummy repo in test --------- Co-authored-by: aniket.bhosale <aniket.bhosale@servicenow.com>
1 parent 6f859ca commit b55ae60

File tree

16 files changed

+468
-145
lines changed

16 files changed

+468
-145
lines changed

docs/en/checkout.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@
7474
<tr><td>force</td><td>boolean = false</td><td>If true, conflicts will be ignored and files will be overwritten regardless of local changes.</td></tr>
7575
<tr><td>track</td><td>boolean = true</td><td>If false, will not set the remote branch tracking information. Defaults to true.</td></tr>
7676
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/cache">cache</a> object</td></tr>
77+
<tr><td>nonBlocking</td><td>boolean = false</td><td>If true, will use non-blocking file system operations to allow for better performance in certain environments (For example, in Browsers)</td></tr>
78+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
7779
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when filesystem operations are complete</td></tr>
7880
</tbody>
7981
</table>

docs/en/checkout/index.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@
7474
<tr><td>force</td><td>boolean = false</td><td>If true, conflicts will be ignored and files will be overwritten regardless of local changes.</td></tr>
7575
<tr><td>track</td><td>boolean = true</td><td>If false, will not set the remote branch tracking information. Defaults to true.</td></tr>
7676
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/cache">cache</a> object</td></tr>
77+
<tr><td>nonBlocking</td><td>boolean = false</td><td>If true, will use non-blocking file system operations to allow for better performance in certain environments (For example, in Browsers)</td></tr>
78+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
7779
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when filesystem operations are complete</td></tr>
7880
</tbody>
7981
</table>

docs/en/clone.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,8 @@
8383
<tr><td>relative</td><td>boolean = false</td><td>Changes the meaning of <code>depth</code> to be measured from the current shallow depth rather than from the branch tip.</td></tr>
8484
<tr><td><a href="./headers">headers</a></td><td>Object&lt;string, string&gt; = {}</td><td>Additional headers to include in HTTP requests, similar to git's <code>extraHeader</code> config</td></tr>
8585
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/cache">cache</a> object</td></tr>
86+
<tr><td>nonBlocking</td><td>boolean = false</td><td>if true, checkout will happen non-blockingly (useful for long-running operations blocking the thread in browser environments)</td></tr>
87+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
8688
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when clone completes</td></tr>
8789
</tbody>
8890
</table>

docs/en/clone/index.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,8 @@
8383
<tr><td>relative</td><td>boolean = false</td><td>Changes the meaning of <code>depth</code> to be measured from the current shallow depth rather than from the branch tip.</td></tr>
8484
<tr><td><a href="./headers">headers</a></td><td>Object&lt;string, string&gt; = {}</td><td>Additional headers to include in HTTP requests, similar to git's <code>extraHeader</code> config</td></tr>
8585
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/cache">cache</a> object</td></tr>
86+
<tr><td>nonBlocking</td><td>boolean = false</td><td>if true, checkout will happen non-blockingly (useful for long-running operations blocking the thread in browser environments)</td></tr>
87+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
8688
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when clone completes</td></tr>
8789
</tbody>
8890
</table>

docs/en/next/checkout.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@
7474
<tr><td>force</td><td>boolean = false</td><td>If true, conflicts will be ignored and files will be overwritten regardless of local changes.</td></tr>
7575
<tr><td>track</td><td>boolean = true</td><td>If false, will not set the remote branch tracking information. Defaults to true.</td></tr>
7676
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/next/cache">cache</a> object</td></tr>
77+
<tr><td>nonBlocking</td><td>boolean = false</td><td>If true, will use non-blocking file system operations to allow for better performance in certain environments (For example, in Browsers)</td></tr>
78+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
7779
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when filesystem operations are complete</td></tr>
7880
</tbody>
7981
</table>

docs/en/next/checkout/index.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,8 @@
7474
<tr><td>force</td><td>boolean = false</td><td>If true, conflicts will be ignored and files will be overwritten regardless of local changes.</td></tr>
7575
<tr><td>track</td><td>boolean = true</td><td>If false, will not set the remote branch tracking information. Defaults to true.</td></tr>
7676
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/next/cache">cache</a> object</td></tr>
77+
<tr><td>nonBlocking</td><td>boolean = false</td><td>If true, will use non-blocking file system operations to allow for better performance in certain environments (For example, in Browsers)</td></tr>
78+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
7779
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when filesystem operations are complete</td></tr>
7880
</tbody>
7981
</table>

docs/en/next/clone.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,8 @@
8383
<tr><td>relative</td><td>boolean = false</td><td>Changes the meaning of <code>depth</code> to be measured from the current shallow depth rather than from the branch tip.</td></tr>
8484
<tr><td><a href="./headers">headers</a></td><td>Object&lt;string, string&gt; = {}</td><td>Additional headers to include in HTTP requests, similar to git's <code>extraHeader</code> config</td></tr>
8585
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/next/cache">cache</a> object</td></tr>
86+
<tr><td>nonBlocking</td><td>boolean = false</td><td>if true, checkout will happen non-blockingly (useful for long-running operations blocking the thread in browser environments)</td></tr>
87+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
8688
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when clone completes</td></tr>
8789
</tbody>
8890
</table>

docs/en/next/clone/index.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,8 @@
8383
<tr><td>relative</td><td>boolean = false</td><td>Changes the meaning of <code>depth</code> to be measured from the current shallow depth rather than from the branch tip.</td></tr>
8484
<tr><td><a href="./headers">headers</a></td><td>Object&lt;string, string&gt; = {}</td><td>Additional headers to include in HTTP requests, similar to git's <code>extraHeader</code> config</td></tr>
8585
<tr><td>cache</td><td>object</td><td>a <a href="/docs/en/next/cache">cache</a> object</td></tr>
86+
<tr><td>nonBlocking</td><td>boolean = false</td><td>if true, checkout will happen non-blockingly (useful for long-running operations blocking the thread in browser environments)</td></tr>
87+
<tr><td>batchSize</td><td>number = 100</td><td>If args.nonBlocking is true, batchSize is the number of files to process at a time avoid blocking the executing thread. The default value of 100 is a good starting point.</td></tr>
8688
<tr><td>return</td><td>Promise&lt;void&gt;</td><td>Resolves successfully when clone completes</td></tr>
8789
</tbody>
8890
</table>

js/isomorphic-git/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,7 @@ Thanks goes to these wonderful people ([emoji key](https://github.com/kentcdodds
388388
<td align="center"><a href="https://github.com/lukecotter"><img src="https://avatars.githubusercontent.com/u/4013877?v=4?s=60" width="60px;" alt=""/><br /><sub><b>Luke Cotter</b></sub></a><br /><a href="https://github.com/isomorphic-git/isomorphic-git/commits?author=lukecotter" title="Code">💻</a></td>
389389
<td align="center"><a href="https://tomlarkworthy.endpointservices.net/"><img src="https://avatars.githubusercontent.com/u/1848162?v=4?s=60" width="60px;" alt=""/><br /><sub><b>Tom Larkworthy</b></sub></a><br /><a href="https://github.com/isomorphic-git/isomorphic-git/commits?author=tomlarkworthy" title="Documentation">📖</a></td>
390390
<td align="center"><a href="https://github.com/kofta999"><img src="https://avatars.githubusercontent.com/u/99273340?v=4?s=60" width="60px;" alt=""/><br /><sub><b>Mostafa Mahmoud</b></sub></a><br /><a href="https://github.com/isomorphic-git/isomorphic-git/commits?author=kofta999" title="Code">💻</a> <a href="https://github.com/isomorphic-git/isomorphic-git/commits?author=kofta999" title="Tests">⚠️</a> <a href="#question-kofta999" title="Answering Questions">💬</a></td>
391+
<td align="center"><a href="https://github.com/ARBhosale"><img src="https://avatars.githubusercontent.com/u/26981417?v=4?s=60" width="60px;" alt=""/><br /><sub><b>Aniket Bhosale</b></sub></a><br /><a href="https://github.com/isomorphic-git/isomorphic-git/commits?author=ARBhosale" title="Code">💻</a> <a href="https://github.com/isomorphic-git/isomorphic-git/commits?author=ARBhosale" title="Documentation">📖</a> <a href="https://github.com/isomorphic-git/isomorphic-git/commits?author=ARBhosale" title="Tests">⚠️</a></td>
391392
</tr>
392393
</table>
393394

0 commit comments

Comments
 (0)