bun-git-hooks 0.1.0

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.
@@ -0,0 +1,4 @@
1
+ import type { GitHooksConfig } from './types';
2
+
3
+ export declare const defaultConfig: GitHooksConfig;
4
+ export declare const config: GitHooksConfig;
@@ -0,0 +1,50 @@
1
+ export declare const VALID_GIT_HOOKS: Array<
2
+ 'applypatch-msg' |
3
+ 'pre-applypatch' |
4
+ 'post-applypatch' |
5
+ 'pre-commit' |
6
+ 'pre-merge-commit' |
7
+ 'prepare-commit-msg' |
8
+ 'commit-msg' |
9
+ 'post-commit' |
10
+ 'pre-rebase' |
11
+ 'post-checkout' |
12
+ 'post-merge' |
13
+ 'pre-push' |
14
+ 'pre-receive' |
15
+ 'update' |
16
+ 'proc-receive' |
17
+ 'post-receive' |
18
+ 'post-update' |
19
+ 'reference-transaction' |
20
+ 'push-to-checkout' |
21
+ 'pre-auto-gc' |
22
+ 'post-rewrite' |
23
+ 'sendemail-validate' |
24
+ 'fsmonitor-watchman' |
25
+ 'p4-changelist' |
26
+ 'p4-prepare-changelist' |
27
+ 'p4-post-changelist' |
28
+ 'p4-pre-submit' |
29
+ 'post-index-change'
30
+ >;
31
+ export declare const VALID_OPTIONS: Array<'preserveUnused'>;
32
+ export declare const PREPEND_SCRIPT: unknown;
33
+ export declare function getGitProjectRoot(directory: string): string | undefined;
34
+ export declare function checkBunGitHooksInDependencies(projectRootPath: string): boolean;
35
+ declare function _getPackageJson(projectPath): void;
36
+ export declare function setHooksFromConfig(projectRootPath: string, options?: { configFile?: , string }): void;
37
+ declare function _setHook(hook: string, command: string, projectRoot: string): void;
38
+ export declare function removeHooks(projectRoot: string, verbose): void;
39
+ declare function _removeHook(hook: string, projectRoot, verbose): void;
40
+ declare function _validateHooks(config: Record<string, string>): void;
41
+ declare const gitHooks: {
42
+ PREPEND_SCRIPT: typeof PREPEND_SCRIPT
43
+ setHooksFromConfig: typeof setHooksFromConfig
44
+ removeHooks: typeof removeHooks
45
+ checkBunGitHooksInDependencies: typeof checkBunGitHooksInDependencies
46
+ getProjectRootDirectoryFromNodeModules: typeof getProjectRootDirectoryFromNodeModules
47
+ getGitProjectRoot: typeof getGitProjectRoot
48
+ };
49
+
50
+ export default gitHooks;
@@ -0,0 +1,3 @@
1
+ export * from './config'
2
+ export * from './git-hooks'
3
+ export * from './types'