diff options
author | Minteck <contact@minteck.org> | 2022-02-12 10:33:06 +0100 |
---|---|---|
committer | Minteck <contact@minteck.org> | 2022-02-12 10:33:06 +0100 |
commit | 01160246e4a0c0052181c72a53737e356ea7d02d (patch) | |
tree | c6f8ea675f9147d4c06ef503697fb35d58493991 /node_modules/simple-git/src/lib/tasks | |
parent | af898a152a14e31bdbcbbedb952ad333697553ef (diff) | |
download | twilight-01160246e4a0c0052181c72a53737e356ea7d02d.tar.gz twilight-01160246e4a0c0052181c72a53737e356ea7d02d.tar.bz2 twilight-01160246e4a0c0052181c72a53737e356ea7d02d.zip |
First commit
Diffstat (limited to 'node_modules/simple-git/src/lib/tasks')
26 files changed, 200 insertions, 0 deletions
diff --git a/node_modules/simple-git/src/lib/tasks/apply-patch.d.ts b/node_modules/simple-git/src/lib/tasks/apply-patch.d.ts new file mode 100644 index 0000000..c1e1551 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/apply-patch.d.ts @@ -0,0 +1,3 @@ +import { OptionFlags, Options, StringTask } from '../types'; +export declare type ApplyOptions = Options & OptionFlags<'--stat' | '--numstat' | '--summary' | '--check' | '--index' | '--intent-to-add' | '--3way' | '--apply' | '--no-add' | '-R' | '--reverse' | '--allow-binary-replacement' | '--binary' | '--reject' | '-z' | '--inaccurate-eof' | '--recount' | '--cached' | '--ignore-space-change' | '--ignore-whitespace' | '--verbose' | '--unsafe-paths'> & OptionFlags<'--whitespace', 'nowarn' | 'warn' | 'fix' | 'error' | 'error-all'> & OptionFlags<'--build-fake-ancestor' | '--exclude' | '--include' | '--directory', string> & OptionFlags<'-p' | '-C', number>; +export declare function applyPatchTask(patches: string[], customArgs: string[]): StringTask<string>; diff --git a/node_modules/simple-git/src/lib/tasks/branch.d.ts b/node_modules/simple-git/src/lib/tasks/branch.d.ts new file mode 100644 index 0000000..157b2ae --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/branch.d.ts @@ -0,0 +1,7 @@ +import { BranchMultiDeleteResult, BranchSingleDeleteResult, BranchSummary } from '../../../typings'; +import { StringTask } from '../types'; +export declare function containsDeleteBranchCommand(commands: string[]): boolean; +export declare function branchTask(customArgs: string[]): StringTask<BranchSummary | BranchSingleDeleteResult>; +export declare function branchLocalTask(): StringTask<BranchSummary>; +export declare function deleteBranchesTask(branches: string[], forceDelete?: boolean): StringTask<BranchMultiDeleteResult>; +export declare function deleteBranchTask(branch: string, forceDelete?: boolean): StringTask<BranchSingleDeleteResult>; diff --git a/node_modules/simple-git/src/lib/tasks/change-working-directory.d.ts b/node_modules/simple-git/src/lib/tasks/change-working-directory.d.ts new file mode 100644 index 0000000..1ad1009 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/change-working-directory.d.ts @@ -0,0 +1,2 @@ +import { SimpleGitExecutor } from '../types'; +export declare function changeWorkingDirectoryTask(directory: string, root?: SimpleGitExecutor): import("./task").EmptyTask; diff --git a/node_modules/simple-git/src/lib/tasks/check-ignore.d.ts b/node_modules/simple-git/src/lib/tasks/check-ignore.d.ts new file mode 100644 index 0000000..7b34b8d --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/check-ignore.d.ts @@ -0,0 +1,2 @@ +import { StringTask } from '../types'; +export declare function checkIgnoreTask(paths: string[]): StringTask<string[]>; diff --git a/node_modules/simple-git/src/lib/tasks/check-is-repo.d.ts b/node_modules/simple-git/src/lib/tasks/check-is-repo.d.ts new file mode 100644 index 0000000..580846f --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/check-is-repo.d.ts @@ -0,0 +1,9 @@ +import { Maybe, StringTask } from '../types'; +export declare enum CheckRepoActions { + BARE = "bare", + IN_TREE = "tree", + IS_REPO_ROOT = "root" +} +export declare function checkIsRepoTask(action: Maybe<CheckRepoActions>): StringTask<boolean>; +export declare function checkIsRepoRootTask(): StringTask<boolean>; +export declare function checkIsBareRepoTask(): StringTask<boolean>; diff --git a/node_modules/simple-git/src/lib/tasks/clean.d.ts b/node_modules/simple-git/src/lib/tasks/clean.d.ts new file mode 100644 index 0000000..c3f7ce7 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/clean.d.ts @@ -0,0 +1,25 @@ +import { CleanSummary } from '../../../typings'; +import { StringTask } from '../types'; +export declare const CONFIG_ERROR_INTERACTIVE_MODE = "Git clean interactive mode is not supported"; +export declare const CONFIG_ERROR_MODE_REQUIRED = "Git clean mode parameter (\"n\" or \"f\") is required"; +export declare const CONFIG_ERROR_UNKNOWN_OPTION = "Git clean unknown option found in: "; +/** + * All supported option switches available for use in a `git.clean` operation + */ +export declare enum CleanOptions { + DRY_RUN = "n", + FORCE = "f", + IGNORED_INCLUDED = "x", + IGNORED_ONLY = "X", + EXCLUDING = "e", + QUIET = "q", + RECURSIVE = "d" +} +/** + * The two modes `git.clean` can run in - one of these must be supplied in order + * for the command to not throw a `TaskConfigurationError` + */ +export declare type CleanMode = CleanOptions.FORCE | CleanOptions.DRY_RUN; +export declare function cleanWithOptionsTask(mode: CleanMode | string, customArgs: string[]): import("./task").EmptyTask | StringTask<CleanSummary>; +export declare function cleanTask(mode: CleanMode, customArgs: string[]): StringTask<CleanSummary>; +export declare function isCleanOptionsArray(input: string[]): input is CleanOptions[]; diff --git a/node_modules/simple-git/src/lib/tasks/clone.d.ts b/node_modules/simple-git/src/lib/tasks/clone.d.ts new file mode 100644 index 0000000..2662ece --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/clone.d.ts @@ -0,0 +1,4 @@ +import { OptionFlags, Options, StringTask } from '../types'; +export declare type CloneOptions = Options & OptionFlags<'--bare' | '--dissociate' | '--mirror' | '--no-checkout' | '--no-remote-submodules' | '--no-shallow-submodules' | '--no-single-branch' | '--no-tags' | '--remote-submodules' | '--single-branch' | '--shallow-submodules' | '--verbose'> & OptionFlags<'--depth' | '-j' | '--jobs', number> & OptionFlags<'--branch' | '--origin' | '--recurse-submodules' | '--separate-git-dir' | '--shallow-exclude' | '--shallow-since' | '--template', string>; +export declare function cloneTask(repo: string | undefined, directory: string | undefined, customArgs: string[]): StringTask<string>; +export declare function cloneMirrorTask(repo: string | undefined, directory: string | undefined, customArgs: string[]): StringTask<string>; diff --git a/node_modules/simple-git/src/lib/tasks/commit.d.ts b/node_modules/simple-git/src/lib/tasks/commit.d.ts new file mode 100644 index 0000000..a84d2f5 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/commit.d.ts @@ -0,0 +1,3 @@ +import { CommitResult } from '../../../typings'; +import { StringTask } from '../types'; +export declare function commitTask(message: string[], files: string[], customArgs: string[]): StringTask<CommitResult>; diff --git a/node_modules/simple-git/src/lib/tasks/config.d.ts b/node_modules/simple-git/src/lib/tasks/config.d.ts new file mode 100644 index 0000000..14bc2bb --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/config.d.ts @@ -0,0 +1,8 @@ +import { SimpleGit } from '../../../typings'; +export declare enum GitConfigScope { + system = "system", + global = "global", + local = "local", + worktree = "worktree" +} +export default function (): Pick<SimpleGit, 'addConfig' | 'getConfig' | 'listConfig'>; diff --git a/node_modules/simple-git/src/lib/tasks/diff.d.ts b/node_modules/simple-git/src/lib/tasks/diff.d.ts new file mode 100644 index 0000000..c1e37aa --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/diff.d.ts @@ -0,0 +1,3 @@ +import { StringTask } from '../types'; +import { DiffResult } from '../../../typings'; +export declare function diffSummaryTask(customArgs: string[]): StringTask<DiffResult>; diff --git a/node_modules/simple-git/src/lib/tasks/fetch.d.ts b/node_modules/simple-git/src/lib/tasks/fetch.d.ts new file mode 100644 index 0000000..db4626d --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/fetch.d.ts @@ -0,0 +1,3 @@ +import { FetchResult } from '../../../typings'; +import { StringTask } from '../types'; +export declare function fetchTask(remote: string, branch: string, customArgs: string[]): StringTask<FetchResult>; diff --git a/node_modules/simple-git/src/lib/tasks/grep.d.ts b/node_modules/simple-git/src/lib/tasks/grep.d.ts new file mode 100644 index 0000000..653159a --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/grep.d.ts @@ -0,0 +1,12 @@ +import { SimpleGit } from '../../../typings'; +export interface GitGrepQuery extends Iterable<string> { + /** Adds one or more terms to be grouped as an "and" to any other terms */ + and(...and: string[]): this; + /** Adds one or more search terms - git.grep will "or" this to other terms */ + param(...param: string[]): this; +} +/** + * Creates a new builder for a `git.grep` query with optional params + */ +export declare function grepQueryBuilder(...params: string[]): GitGrepQuery; +export default function (): Pick<SimpleGit, 'grep'>; diff --git a/node_modules/simple-git/src/lib/tasks/hash-object.d.ts b/node_modules/simple-git/src/lib/tasks/hash-object.d.ts new file mode 100644 index 0000000..cedf3e0 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/hash-object.d.ts @@ -0,0 +1,5 @@ +import { StringTask } from '../types'; +/** + * Task used by `git.hashObject` + */ +export declare function hashObjectTask(filePath: string, write: boolean): StringTask<string>; diff --git a/node_modules/simple-git/src/lib/tasks/init.d.ts b/node_modules/simple-git/src/lib/tasks/init.d.ts new file mode 100644 index 0000000..ca7f126 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/init.d.ts @@ -0,0 +1,3 @@ +import { InitResult } from '../../../typings'; +import { StringTask } from '../types'; +export declare function initTask(bare: boolean | undefined, path: string, customArgs: string[]): StringTask<InitResult>; diff --git a/node_modules/simple-git/src/lib/tasks/log.d.ts b/node_modules/simple-git/src/lib/tasks/log.d.ts new file mode 100644 index 0000000..b4ae73f --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/log.d.ts @@ -0,0 +1,32 @@ +import { Options, StringTask } from '../types'; +import { LogResult, SimpleGit } from '../../../typings'; +export interface DefaultLogFields { + hash: string; + date: string; + message: string; + refs: string; + body: string; + author_name: string; + author_email: string; +} +export declare type LogOptions<T = DefaultLogFields> = { + file?: string; + format?: T; + from?: string; + mailMap?: boolean; + maxCount?: number; + multiLine?: boolean; + splitter?: string; + strictDate?: boolean; + symmetric?: boolean; + to?: string; +}; +interface ParsedLogOptions { + fields: string[]; + splitter: string; + commands: string[]; +} +export declare function parseLogOptions<T extends Options>(opt?: LogOptions<T>, customArgs?: string[]): ParsedLogOptions; +export declare function logTask<T>(splitter: string, fields: string[], customArgs: string[]): StringTask<LogResult<T>>; +export default function (): Pick<SimpleGit, 'log'>; +export {}; diff --git a/node_modules/simple-git/src/lib/tasks/merge.d.ts b/node_modules/simple-git/src/lib/tasks/merge.d.ts new file mode 100644 index 0000000..663e80b --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/merge.d.ts @@ -0,0 +1,4 @@ +import { MergeResult } from '../../../typings'; +import { StringTask } from '../types'; +import { EmptyTask } from './task'; +export declare function mergeTask(customArgs: string[]): EmptyTask | StringTask<MergeResult>; diff --git a/node_modules/simple-git/src/lib/tasks/move.d.ts b/node_modules/simple-git/src/lib/tasks/move.d.ts new file mode 100644 index 0000000..75ae9af --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/move.d.ts @@ -0,0 +1,3 @@ +import { MoveResult } from '../../../typings'; +import { StringTask } from '../types'; +export declare function moveTask(from: string | string[], to: string): StringTask<MoveResult>; diff --git a/node_modules/simple-git/src/lib/tasks/pull.d.ts b/node_modules/simple-git/src/lib/tasks/pull.d.ts new file mode 100644 index 0000000..c08062f --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/pull.d.ts @@ -0,0 +1,3 @@ +import { PullResult } from '../../../typings'; +import { Maybe, StringTask } from '../types'; +export declare function pullTask(remote: Maybe<string>, branch: Maybe<string>, customArgs: string[]): StringTask<PullResult>; diff --git a/node_modules/simple-git/src/lib/tasks/push.d.ts b/node_modules/simple-git/src/lib/tasks/push.d.ts new file mode 100644 index 0000000..4d18c71 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/push.d.ts @@ -0,0 +1,9 @@ +import { PushResult } from '../../../typings'; +import { StringTask } from '../types'; +declare type PushRef = { + remote?: string; + branch?: string; +}; +export declare function pushTagsTask(ref: PushRef | undefined, customArgs: string[]): StringTask<PushResult>; +export declare function pushTask(ref: PushRef | undefined, customArgs: string[]): StringTask<PushResult>; +export {}; diff --git a/node_modules/simple-git/src/lib/tasks/remote.d.ts b/node_modules/simple-git/src/lib/tasks/remote.d.ts new file mode 100644 index 0000000..fbaae7a --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/remote.d.ts @@ -0,0 +1,6 @@ +import { StringTask } from '../types'; +export declare function addRemoteTask(remoteName: string, remoteRepo: string, customArgs?: string[]): StringTask<string>; +export declare function getRemotesTask(verbose: boolean): StringTask<any>; +export declare function listRemotesTask(customArgs?: string[]): StringTask<string>; +export declare function remoteTask(customArgs?: string[]): StringTask<string>; +export declare function removeRemoteTask(remoteName: string): StringTask<string>; diff --git a/node_modules/simple-git/src/lib/tasks/reset.d.ts b/node_modules/simple-git/src/lib/tasks/reset.d.ts new file mode 100644 index 0000000..468fe87 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/reset.d.ts @@ -0,0 +1,11 @@ +import { Maybe, OptionFlags, Options } from '../types'; +export declare enum ResetMode { + MIXED = "mixed", + SOFT = "soft", + HARD = "hard", + MERGE = "merge", + KEEP = "keep" +} +export declare type ResetOptions = Options & OptionFlags<'-q' | '--quiet' | '--no-quiet' | '--pathspec-from-nul'> & OptionFlags<'--pathspec-from-file', string>; +export declare function resetTask(mode: Maybe<ResetMode>, customArgs: string[]): import("../types").StringTask<string>; +export declare function getResetMode(mode: ResetMode | any): Maybe<ResetMode>; diff --git a/node_modules/simple-git/src/lib/tasks/stash-list.d.ts b/node_modules/simple-git/src/lib/tasks/stash-list.d.ts new file mode 100644 index 0000000..5bf9a9c --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/stash-list.d.ts @@ -0,0 +1,3 @@ +import { LogOptions, LogResult } from '../../../typings'; +import { StringTask } from '../types'; +export declare function stashListTask(opt: LogOptions<import("./log").DefaultLogFields> | undefined, customArgs: string[]): StringTask<LogResult>; diff --git a/node_modules/simple-git/src/lib/tasks/status.d.ts b/node_modules/simple-git/src/lib/tasks/status.d.ts new file mode 100644 index 0000000..45fec0f --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/status.d.ts @@ -0,0 +1,3 @@ +import { StatusResult } from '../../../typings'; +import { StringTask } from '../types'; +export declare function statusTask(customArgs: string[]): StringTask<StatusResult>; diff --git a/node_modules/simple-git/src/lib/tasks/sub-module.d.ts b/node_modules/simple-git/src/lib/tasks/sub-module.d.ts new file mode 100644 index 0000000..ac4f6f8 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/sub-module.d.ts @@ -0,0 +1,5 @@ +import { StringTask } from '../types'; +export declare function addSubModuleTask(repo: string, path: string): StringTask<string>; +export declare function initSubModuleTask(customArgs: string[]): StringTask<string>; +export declare function subModuleTask(customArgs: string[]): StringTask<string>; +export declare function updateSubModuleTask(customArgs: string[]): StringTask<string>; diff --git a/node_modules/simple-git/src/lib/tasks/tag.d.ts b/node_modules/simple-git/src/lib/tasks/tag.d.ts new file mode 100644 index 0000000..b1dbb31 --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/tag.d.ts @@ -0,0 +1,18 @@ +import { TagResult } from '../../../typings'; +import { StringTask } from '../types'; +/** + * Task used by `git.tags` + */ +export declare function tagListTask(customArgs?: string[]): StringTask<TagResult>; +/** + * Task used by `git.addTag` + */ +export declare function addTagTask(name: string): StringTask<{ + name: string; +}>; +/** + * Task used by `git.addTag` + */ +export declare function addAnnotatedTagTask(name: string, tagMessage: string): StringTask<{ + name: string; +}>; diff --git a/node_modules/simple-git/src/lib/tasks/task.d.ts b/node_modules/simple-git/src/lib/tasks/task.d.ts new file mode 100644 index 0000000..9c64e4e --- /dev/null +++ b/node_modules/simple-git/src/lib/tasks/task.d.ts @@ -0,0 +1,14 @@ +import { BufferTask, EmptyTaskParser, SimpleGitTask, StringTask } from '../types'; +export declare const EMPTY_COMMANDS: []; +export declare type EmptyTask = { + commands: typeof EMPTY_COMMANDS; + format: 'empty'; + parser: EmptyTaskParser; + onError?: undefined; +}; +export declare function adhocExecTask(parser: EmptyTaskParser): EmptyTask; +export declare function configurationErrorTask(error: Error | string): EmptyTask; +export declare function straightThroughStringTask(commands: string[], trimmed?: boolean): StringTask<string>; +export declare function straightThroughBufferTask(commands: string[]): BufferTask<any>; +export declare function isBufferTask<R>(task: SimpleGitTask<R>): task is BufferTask<R>; +export declare function isEmptyTask<R>(task: SimpleGitTask<R>): task is EmptyTask; |