You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
| Parameters | Type |
| --- | --- | --- |
| write_index | Number | Boolean if this should immediately write the index file. If you pass this as false, you will have to get the git_index and explicitly call git_index_write() on it to save the change. |
| Parameters | Type |
| --- | --- | --- |
| overwrite | Number | By default, existing entries will not be overwritten, but setting this to true forces them to be updated. |
Returns
Number
0 on success,
<
0 on failure.
Submodule#name SyncExperimental
varstring=submodule.name();
Returns
String
Submodule#open SyncExperimental
varresult=submodule.open(repo);
| Parameters | Type |
| --- | --- | --- |
| repo | Repository | Pointer to the submodule repo which was opened |
| Parameters | Type |
| --- | --- | --- |
| force | Number | Force reload even if the data doesn't seem out of date |
Returns
Number
0 on success,
<
0 on error
Submodule#repoInit AsyncExperimental
submodule.repoInit(use_gitlink).then(function(repository){// Use repository});
| Parameters | Type |
| --- | --- | --- |
| use_gitlink | Number | Should the workdir contain a gitlink to the repo in .git/modules vs. repo directly in workdir. |
| Parameters | Type |
| --- | --- | --- |
| fetch_recurse_submodules | Number | Boolean value |
Returns
Number
old value for fetchRecurseSubmodules
Submodule#setIgnore SyncExperimental
varresult=submodule.setIgnore(ignore);
| Parameters | Type |
| --- | --- | --- |
| ignore | Number | The new value for the ignore rule |
Returns
Number
old value for ignore
Submodule#setUpdate SyncExperimental
varresult=submodule.setUpdate(update);
| Parameters | Type |
| --- | --- | --- |
| update | Number | The new value to use |
Returns
Number
old value for update
Submodule#setUrl SyncExperimental
varresult=submodule.setUrl(url);
| Parameters | Type |
| --- | --- | --- |
| url | String | URL that should be used for the submodule |
Returns
Number
0 on success,
<
0 on failure
Submodule#sync SyncExperimental
varresult=submodule.sync();
Returns
Number
Submodule#update SyncExperimental
varresult=submodule.update(init,options);
| Parameters | Type |
| --- | --- | --- |
| init | Number | If the submodule is not initialized, setting this flag to true will initialize the submodule before updating. Otherwise, this will return an error if attempting to update an uninitialzed repository. but setting this to true forces them to be updated. |
| options | SubmoduleUpdateOptions | configuration options for the update. If NULL, the function works as though GIT_SUBMODULE_UPDATE_OPTIONS_INIT was passed. |
Returns
Number
0 on success, any non-zero return value from a callback
function, or a negative value to indicate an error (use
`giterr_last` for a detailed error message). |
Submodule#updateStrategy SyncExperimental
varresult=submodule.updateStrategy();
Returns
Number
The current git_submodule_update_t value that will be used