es-git 0.5.0-next.167 → 0.5.0-next.169
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +72 -0
- package/index.js +3 -0
- package/package.json +11 -11
package/index.d.ts
CHANGED
|
@@ -2677,6 +2677,27 @@ export declare class Repository {
|
|
|
2677
2677
|
* @returns The postimage of the application
|
|
2678
2678
|
*/
|
|
2679
2679
|
applyToTree(tree: Tree, diff: Diff, options?: ApplyOptions | undefined | null): Index
|
|
2680
|
+
/**
|
|
2681
|
+
* Get the value of a git attribute for a path.
|
|
2682
|
+
*
|
|
2683
|
+
* @ository/Methods
|
|
2684
|
+
* @signature
|
|
2685
|
+
* ```ts
|
|
2686
|
+
* class Repository {
|
|
2687
|
+
* getAttr(
|
|
2688
|
+
* path: string,
|
|
2689
|
+
* name: string,
|
|
2690
|
+
* options?: AttrOptions | null | undefined
|
|
2691
|
+
* ): boolean | string | Buffer | null;
|
|
2692
|
+
* ```
|
|
2693
|
+
*
|
|
2694
|
+
* @param {string} path - The path to check for attributes. Relative paths are interpreted relative to the repo root.
|
|
2695
|
+
* @param {string} name - The name of the attribute to look up.
|
|
2696
|
+
* @param {AttrOptions} [options] - Options for attribute lookup.
|
|
2697
|
+
*
|
|
2698
|
+
* @returns Output of the value of the attribute.
|
|
2699
|
+
*/
|
|
2700
|
+
getAttr(path: string, name: string, options?: AttrOptions | undefined | null): boolean | string | Buffer | null
|
|
2680
2701
|
/**
|
|
2681
2702
|
* Creates a blame object for the file at the given path
|
|
2682
2703
|
*
|
|
@@ -5727,6 +5748,17 @@ export interface ApplyOptions {
|
|
|
5727
5748
|
check?: boolean
|
|
5728
5749
|
}
|
|
5729
5750
|
|
|
5751
|
+
export interface AttrOptions {
|
|
5752
|
+
/** Check the working directory, then the index. */
|
|
5753
|
+
checkFileThenIndex?: boolean
|
|
5754
|
+
/** Check the index, then the working directory. */
|
|
5755
|
+
checkIndexThenFile?: boolean
|
|
5756
|
+
/** Check the index only. */
|
|
5757
|
+
checkIndexOnly?: boolean
|
|
5758
|
+
/** Do not use the system gitattributes file. */
|
|
5759
|
+
checkNoSystem?: boolean
|
|
5760
|
+
}
|
|
5761
|
+
|
|
5730
5762
|
/**
|
|
5731
5763
|
* - `Unspecified` : Use the setting from the remote's configuration
|
|
5732
5764
|
* - `Auto` : Ask the server for tags pointing to objects we're already downloading
|
|
@@ -8028,6 +8060,46 @@ export type StatusShow = 'Index'|
|
|
|
8028
8060
|
'Workdir'|
|
|
8029
8061
|
'IndexAndWorkdir';
|
|
8030
8062
|
|
|
8063
|
+
/**
|
|
8064
|
+
* Clear the global subscriber
|
|
8065
|
+
*
|
|
8066
|
+
* @category Tracing
|
|
8067
|
+
* @signature
|
|
8068
|
+
* ```ts
|
|
8069
|
+
* function traceClear(): void;
|
|
8070
|
+
* ```
|
|
8071
|
+
*/
|
|
8072
|
+
export declare function traceClear(): void
|
|
8073
|
+
|
|
8074
|
+
/**
|
|
8075
|
+
* Available tracing levels. When tracing is set to a particular level,
|
|
8076
|
+
* callers will be provided tracing at the given level and all lower levels.
|
|
8077
|
+
*/
|
|
8078
|
+
export type TraceLevel = 'None'|
|
|
8079
|
+
'Fatal'|
|
|
8080
|
+
'Error'|
|
|
8081
|
+
'Warn'|
|
|
8082
|
+
'Info'|
|
|
8083
|
+
'Debug'|
|
|
8084
|
+
'Trace';
|
|
8085
|
+
|
|
8086
|
+
/**
|
|
8087
|
+
* Set the global subscriber called when libgit2 produces a tracing message.
|
|
8088
|
+
*
|
|
8089
|
+
* @category Tracing
|
|
8090
|
+
* @signature
|
|
8091
|
+
* ```ts
|
|
8092
|
+
* function traceSet(
|
|
8093
|
+
* level: TraceLevel,
|
|
8094
|
+
* callback: (level: TraceLevel, message: string) => void,
|
|
8095
|
+
* ): void;
|
|
8096
|
+
* ```
|
|
8097
|
+
*
|
|
8098
|
+
* @param {TraceLevel} level - Level to set tracing to
|
|
8099
|
+
* @param {(level: TraceLevel, message: string) => void} callback - Callback to call with trace data
|
|
8100
|
+
*/
|
|
8101
|
+
export declare function traceSet(level: TraceLevel, callback: (level: TraceLevel, message: string) => void): void
|
|
8102
|
+
|
|
8031
8103
|
/**
|
|
8032
8104
|
* - `PreOrder` : Runs the traversal in pre-order.
|
|
8033
8105
|
* - `PostOrder` : Runs the traversal in post-order.
|
package/index.js
CHANGED
|
@@ -656,5 +656,8 @@ module.exports.RevparseMode = nativeBinding.RevparseMode
|
|
|
656
656
|
module.exports.revparseModeContains = nativeBinding.revparseModeContains
|
|
657
657
|
module.exports.RevwalkSort = nativeBinding.RevwalkSort
|
|
658
658
|
module.exports.StatusShow = nativeBinding.StatusShow
|
|
659
|
+
module.exports.traceClear = nativeBinding.traceClear
|
|
660
|
+
module.exports.TraceLevel = nativeBinding.TraceLevel
|
|
661
|
+
module.exports.traceSet = nativeBinding.traceSet
|
|
659
662
|
module.exports.TreeWalkMode = nativeBinding.TreeWalkMode
|
|
660
663
|
module.exports.zeroOid = nativeBinding.zeroOid
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "es-git",
|
|
3
|
-
"version": "0.5.0-next.
|
|
3
|
+
"version": "0.5.0-next.169+9b1c12a",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"types": "index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -54,15 +54,15 @@
|
|
|
54
54
|
"vitest": "^3.0.5"
|
|
55
55
|
},
|
|
56
56
|
"optionalDependencies": {
|
|
57
|
-
"es-git-darwin-x64": "0.5.0-next.
|
|
58
|
-
"es-git-darwin-arm64": "0.5.0-next.
|
|
59
|
-
"es-git-win32-x64-msvc": "0.5.0-next.
|
|
60
|
-
"es-git-win32-arm64-msvc": "0.5.0-next.
|
|
61
|
-
"es-git-linux-x64-gnu": "0.5.0-next.
|
|
62
|
-
"es-git-linux-x64-musl": "0.5.0-next.
|
|
63
|
-
"es-git-android-arm64": "0.5.0-next.
|
|
64
|
-
"es-git-linux-arm64-gnu": "0.5.0-next.
|
|
65
|
-
"es-git-linux-arm64-musl": "0.5.0-next.
|
|
66
|
-
"es-git-android-arm-eabi": "0.5.0-next.
|
|
57
|
+
"es-git-darwin-x64": "0.5.0-next.169+9b1c12a",
|
|
58
|
+
"es-git-darwin-arm64": "0.5.0-next.169+9b1c12a",
|
|
59
|
+
"es-git-win32-x64-msvc": "0.5.0-next.169+9b1c12a",
|
|
60
|
+
"es-git-win32-arm64-msvc": "0.5.0-next.169+9b1c12a",
|
|
61
|
+
"es-git-linux-x64-gnu": "0.5.0-next.169+9b1c12a",
|
|
62
|
+
"es-git-linux-x64-musl": "0.5.0-next.169+9b1c12a",
|
|
63
|
+
"es-git-android-arm64": "0.5.0-next.169+9b1c12a",
|
|
64
|
+
"es-git-linux-arm64-gnu": "0.5.0-next.169+9b1c12a",
|
|
65
|
+
"es-git-linux-arm64-musl": "0.5.0-next.169+9b1c12a",
|
|
66
|
+
"es-git-android-arm-eabi": "0.5.0-next.169+9b1c12a"
|
|
67
67
|
}
|
|
68
68
|
}
|