(value: string)
| 94 | } |
| 95 | |
| 96 | export function parseDependencyInput(value: string): string[] { |
| 97 | if (!value) { |
| 98 | return []; |
| 99 | } |
| 100 | |
| 101 | const entries: string[] = []; |
| 102 | const lines = value.split(/\r?\n/); |
| 103 | for (const line of lines) { |
| 104 | const trimmedLine = line.trim(); |
| 105 | if (!trimmedLine) { |
| 106 | continue; |
| 107 | } |
| 108 | |
| 109 | const parts = splitListPreservingLinksAndQuotes(trimmedLine); |
| 110 | for (const part of parts) { |
| 111 | const token = part.trim(); |
| 112 | if (token.length === 0) { |
| 113 | continue; |
| 114 | } |
| 115 | entries.push(token); |
| 116 | } |
| 117 | } |
| 118 | |
| 119 | const seen = new Set<string>(); |
| 120 | const result: string[] = []; |
| 121 | for (const entry of entries) { |
| 122 | if (!seen.has(entry)) { |
| 123 | seen.add(entry); |
| 124 | result.push(entry); |
| 125 | } |
| 126 | } |
| 127 | return result; |
| 128 | } |
| 129 | |
| 130 | export function resolveDependencyEntry( |
| 131 | app: App, |
nothing calls this directly
no test coverage detected