Function
Static Public Summary | ||
public |
checkForFile(path: string) Removes a file if it exists. |
|
public |
createFile(originalPath: string, linkPath: string) |
|
public |
createLinks(paths: string[]) Creates symbolic links. |
|
public |
fileExists(path: string): boolean |
|
public |
Gets files in a directory. |
|
public |
Creates symbolic links for designated files and directories. |
|
public |
Bundles source files for release. |
|
public |
Destroys symbolic links for designated files and directories. |
|
public |
removeFile(path: string): boolean |
|
public |
removeLinks(dir: string) Empties a directory. |
|
public |
resolvePaths(path: string): {originalPath: string, linkPath: string} Resolves file against current working directory and MyBB root. |
|
public |
Destroys symbolic links for designated files and directories. |
Static Public
public checkForFile(path: string) source
import {checkForFile} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Removes a file if it exists.
Params:
Name | Type | Attribute | Description |
path | string | Path to file |
Throw:
If file exists and could not be removed |
public createFile(originalPath: string, linkPath: string) source
import {createFile} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Throw:
If file could not be created |
public createLinks(paths: string[]) source
import {createLinks} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Creates symbolic links.
Params:
Name | Type | Attribute | Description |
paths | string[] | Relative paths of files |
public fileExists(path: string): boolean source
import {fileExists} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Params:
Name | Type | Attribute | Description |
path | string | Path to file |
public getLinks(dir: string): string[] source
import {getLinks} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Gets files in a directory.
Params:
Name | Type | Attribute | Description |
dir | string | Path to directory |
public link(cmd: Command, config: Object) source
import {link} from 'shinka-cli/src/commands/link.js'
Creates symbolic links for designated files and directories.
public release(cmd: Object, config: Object) source
import {release} from 'shinka-cli/src/commands/release.js'
Bundles source files for release.
public relink(cmd: Object, config: Object) source
import {relink} from 'shinka-cli/src/commands/relink.js'
Destroys symbolic links for designated files and directories.
public removeFile(path: string): boolean source
import {removeFile} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Params:
Name | Type | Attribute | Description |
path | string | Path to file |
public removeLinks(dir: string) source
import {removeLinks} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Empties a directory.
Params:
Name | Type | Attribute | Description |
dir | string |
|
Path to directory |
public resolvePaths(path: string): {originalPath: string, linkPath: string} source
import {resolvePaths} from 'shinka-cli/src/Linker/__tests__/helpers.js'
Resolves file against current working directory and MyBB root.
Params:
Name | Type | Attribute | Description |
path | string |
|
Path to file |