Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/davidmfoley/node-trucker
/ functions
Functions
92 in github.com/davidmfoley/node-trucker
⨍
Functions
92
◇
Types & classes
10
↓ 35 callers
Function
findImports
(imports: ImportStatement[], node: ts.SourceFile)
src/analyzeFiles/findImports/typescript/getImportStatements.ts:39
↓ 10 callers
Function
expectMove
(from: string, toPath: string, toRequire?: string)
test/integration/fileLocationCalculator.test.ts:22
↓ 9 callers
Function
changedImportsByFile
(job: TruckerMoveJob)
src/findChangedImports/index.ts:8
↓ 8 callers
Function
moveJob
(from: string, to: string)
test/integration/changedRequiresByFile.test.ts:14
↓ 7 callers
Function
testFiles
(names: string[])
src/findSourceFiles/filterExcludedFiles.test.ts:75
↓ 7 callers
Function
whenLocationsAre
(froms: string | string[], to: string)
test/integration/fileLocationCalculator.test.ts:16
↓ 5 callers
Function
getPathMapper
( { paths, }: { paths: MapperPaths }, resolver: ImportResolver )
src/analyzeFiles/findImports/typescript/pathMapper.ts:45
↓ 4 callers
Function
FindImports
(pathMapper: PathMapper)
src/analyzeFiles/findImports/typescript/index.ts:9
↓ 4 callers
Function
applyToFile
( filePath: string, changedImports: ChangedImport[], sourceFile = importedSourceFile )
src/handleFileChanges/applyToFile.ts:6
↓ 4 callers
Function
buildResult
(filePath: string)
src/analyzeFiles/decorateImport.ts:18
↓ 4 callers
Function
testPath
(p: string)
test/integration/fileLocationCalculator.test.ts:14
↓ 3 callers
Function
applyAliasMapping
( mapping: { alias: string; destination: string }, absolutePath: string )
src/findChangedImports/applyAliasMapping.ts:3
↓ 3 callers
Function
findSourceFiles
(job: TruckerJob)
src/findSourceFiles/index.ts:6
↓ 3 callers
Function
getTsConfig
( { tsconfigPath, base }: TsConfigJob, existsSync = nodeFs.existsSync, readConfigFile = ts.readConfigFil
src/analyzeFiles/findImports/typescript/tsConfig.ts:56
↓ 3 callers
Function
isValidFile
(path: string)
src/analyzeFiles/decorateImport.ts:14
↓ 3 callers
Function
print
(file, leader)
src/printDependencies/printStandard.ts:46
↓ 2 callers
Function
addIfMatch
(imports: ImportInfo[], pathToken: BabelToken)
src/analyzeFiles/findImports/javascript.ts:122
↓ 2 callers
Function
detectBufferEncoding
(buffer: Buffer)
src/sourceFile.ts:4
↓ 2 callers
Function
digest
(graph, from, to)
src/printDependencies/printStandard.ts:13
↓ 2 callers
Function
editLine
(contents: string, edits: ChangedImport[])
src/handleFileChanges/editLine.ts:3
↓ 2 callers
Function
expectNoMove
(from: string)
test/integration/fileLocationCalculator.test.ts:31
↓ 2 callers
Function
getLineEdits
(requires: ChangedImport[])
src/handleFileChanges/getLineEdits.ts:3
↓ 2 callers
Function
importResolver
(isFile: (path: string) => boolean)
src/analyzeFiles/findImports/importResolver.ts:14
↓ 2 callers
Function
isString
(token: BabelToken)
src/analyzeFiles/findImports/javascript.ts:94
↓ 2 callers
Function
p
(subPath: string)
test/integration/changedRequiresByFile.test.ts:10
↓ 2 callers
Function
pushImport
(imports: ImportStatement[], statement: ts.Node)
src/analyzeFiles/findImports/typescript/getImportStatements.ts:64
↓ 2 callers
Function
readIgnores
(base)
src/buildJob/readIgnores.ts:4
↓ 2 callers
Function
requirePath
(filePath: string)
src/findChangedImports/fileLocationCalculator.ts:74
↓ 1 callers
Function
absolute
(fullImportPath: string)
src/analyzeFiles/findImports/importResolver.ts:16
↓ 1 callers
Function
applyEdits
(lines: string[], imports: ChangedImport[])
src/handleFileChanges/applyToFile.ts:17
↓ 1 callers
Function
babelFinder
(contents: string)
src/analyzeFiles/findImports/javascript.ts:46
↓ 1 callers
Function
buildConfig
( tsconfigPath: string, readConfigFile: ReadConfigFile )
src/analyzeFiles/findImports/typescript/tsConfig.ts:43
↓ 1 callers
Function
buildLoc
(node: ts.StringLiteral)
src/analyzeFiles/findImports/typescript/getImportStatements.ts:53
↓ 1 callers
Function
buildMapper
(pattern: string, destinations: string[], resolver: ImportResolver)
src/analyzeFiles/findImports/typescript/pathMapper.ts:15
↓ 1 callers
Function
fileMapper
(isFile: (name: string) => boolean)
src/findChangedImports/fileLocationCalculator.ts:56
↓ 1 callers
Function
getAction
(job: TruckerJob)
src/index.ts:23
↓ 1 callers
Function
getCandidatePaths
(dir: string)
src/analyzeFiles/findImports/typescript/tsConfig.ts:15
↓ 1 callers
Function
getFileImports
( findImports: FindImports, processImport: ProcessImport, importFilter: ImportFilter )
src/analyzeFiles/getFileImports.ts:14
↓ 1 callers
Function
getFiletype
(name: string)
src/findSourceFiles/findFiles.ts:42
↓ 1 callers
Function
handleShebang
(contents: string)
src/analyzeFiles/findImports/javascript.ts:136
↓ 1 callers
Function
isFrom
(token: BabelToken)
src/analyzeFiles/findImports/javascript.ts:90
↓ 1 callers
Function
isImportEquals
( statement: ts.Statement )
src/analyzeFiles/findImports/typescript/getImportStatements.ts:11
↓ 1 callers
Function
isImportOrExport
(statement: ts.Statement)
src/analyzeFiles/findImports/typescript/getImportStatements.ts:7
↓ 1 callers
Function
isStringLiteral
(child: ts.Node)
src/analyzeFiles/findImports/typescript/getImportStatements.ts:4
↓ 1 callers
Function
message
(destination: string, sources: string[])
src/handleFileChanges/checkForErrors.ts:21
↓ 1 callers
Function
parseGitignore
(gitignorePath)
src/buildJob/readIgnores.ts:25
↓ 1 callers
Function
parsePaths
( tsconfigPath: string, configPaths: undefined | Record<string, unknown> )
src/analyzeFiles/findImports/typescript/tsConfig.ts:28
↓ 1 callers
Function
printAnalyzeError
(fileInfo: SourceFile, err: Error)
src/analyzeFiles/sourceFileAnalyzer.ts:35
↓ 1 callers
Function
printChanges
(job: TruckerJob, changes: FileModification[])
src/handleFileChanges/printChanges.ts:8
↓ 1 callers
Function
printClusters
( tree: FolderTree, label: string, depth: number, override?: string )
src/printDependencies/printViz.ts:25
↓ 1 callers
Function
printDependencies
( files: SourceFileWithImports[], job: TruckerJob )
src/printDependencies/index.ts:11
↓ 1 callers
Function
printUnused
( job: TruckerJob, files: SourceFileWithImports[] )
src/printUnused.ts:5
↓ 1 callers
Function
pushImportEquals
( imports: ImportStatement[], statement: ts.ImportEqualsDeclaration )
src/analyzeFiles/findImports/typescript/getImportStatements.ts:28
↓ 1 callers
Function
readContents
(filePath: string)
src/sourceFile.ts:16
↓ 1 callers
Function
regexFinder
(contents: string)
src/analyzeFiles/findImports/javascript.ts:19
↓ 1 callers
Function
relativeImport
( relativePath: string, loc: ImportLocation )
src/analyzeFiles/requireInfo.ts:3
↓ 1 callers
Function
relativePath
(f: string)
src/handleFileChanges/checkForErrors.ts:30
↓ 1 callers
Function
scan
(tokens: BabelToken[], requires: ImportInfo[])
src/analyzeFiles/findImports/javascript.ts:98
↓ 1 callers
Function
shouldContinue
(current)
src/buildJob/readIgnores.ts:21
↓ 1 callers
Function
sourceFileAnalyzer
(job: TruckerJob)
src/analyzeFiles/sourceFileAnalyzer.ts:9
↓ 1 callers
Function
traverse
(base: string, current: string, files: SourceFile[])
src/findSourceFiles/findFiles.ts:11
↓ 1 callers
Function
weCareAboutDirectory
(name: string)
src/findSourceFiles/findFiles.ts:34
↓ 1 callers
Function
weCareAboutFile
(name: string)
src/findSourceFiles/findFiles.ts:38
Function
aliasImport
( text: string, relativePath: string, loc: ImportLocation, mapping: { alias: string; destination: stri
src/analyzeFiles/requireInfo.ts:13
Function
analyzeAndTick
(fileInfo: SourceFile)
src/analyzeFiles/index.ts:55
Function
applyChanges
(job: TruckerMoveJob, changes: FileModification[])
src/handleFileChanges/applyChanges.ts:9
Function
blowOutPath
(subPath: string)
src/buildJob/index.ts:41
Function
byFullPath
(a, b)
test/integration/fileFinder.test.ts:12
Function
cli
()
src/cli.ts:4
Function
decorate
(imp: ImportInfo)
src/analyzeFiles/sourceFileAnalyzer.ts:22
Function
directoryMapper
(f, to)
src/findChangedImports/fileLocationCalculator.ts:64
Function
existsSync
(path: string)
src/analyzeFiles/findImports/typescript/tsConfig.test.ts:9
Function
filterTsImport
(item: ImportInfo)
src/analyzeFiles/findImports/typescript/index.ts:10
Function
getEncoding
(filePath: string)
src/sourceFile.ts:11
Function
getImportStatements
( contents: string, filePath: string )
src/analyzeFiles/findImports/typescript/getImportStatements.ts:16
Function
getMapper
(f: string)
src/findChangedImports/fileLocationCalculator.ts:15
Function
isLocal
(requirePath)
src/analyzeFiles/findImports/importPathFilter.ts:1
Function
isMove
(change: FileModification)
src/handleFileChanges/checkForErrors.ts:35
Function
isValidFile
(path: string)
src/analyzeFiles/findImports/importResolver.ts:9
Function
moveFiles
(job: TruckerJob)
src/index.ts:29
Function
noBar
(analyzer: SourceFileAnalyzer, fileInfos: SourceFile[])
src/analyzeFiles/index.ts:34
Function
printFile
(f)
src/printDependencies/printStandard.ts:34
Function
printStandard
( files: SourceFileWithImports[], job: TruckerJob, write = console.log )
src/printDependencies/printStandard.ts:5
Function
printViz
( files: SourceFileWithImports[], job: TruckerJob, write = console.log )
src/printDependencies/printViz.ts:10
Function
removeEmpties
(line)
src/buildJob/readIgnores.ts:40
Function
requireResolve
(path: string, opts: unknown)
src/analyzeFiles/decorateImport.ts:6
Function
showInfo
(job: TruckerJob)
src/index.ts:35
Function
showUnused
(job: TruckerJob)
src/index.ts:40
Function
sortByFrom
(a: FileModification, b: FileModification)
test/integration/changedRequiresByFile.test.ts:26
Function
stripComment
(line)
src/buildJob/readIgnores.ts:35
Function
trim
(line)
src/buildJob/readIgnores.ts:31
Function
withBar
(analyzer: SourceFileAnalyzer, fileInfos: SourceFile[])
src/analyzeFiles/index.ts:38