mirror of
https://github.com/pbakaus/impeccable.git
synced 2026-09-17 16:46:31 +03:00
Add browser questionnaire foundation
Prepared with AI assistance.
This commit is contained in:
@@ -109,9 +109,11 @@ function readSkillScripts(scriptsDir) {
|
||||
if (PER_PROJECT_SCRIPT_ARTIFACTS.has(entry.name)) continue;
|
||||
|
||||
const relPath = path.relative(scriptsDir, entryPath).split(path.sep).join('/');
|
||||
const isBinary = ['.png', '.jpg', '.jpeg', '.gif', '.webp', '.ico', '.woff', '.woff2']
|
||||
.includes(path.extname(entry.name).toLowerCase());
|
||||
scripts.push({
|
||||
name: relPath,
|
||||
content: fs.readFileSync(entryPath, 'utf-8'),
|
||||
content: fs.readFileSync(entryPath, isBinary ? undefined : 'utf-8'),
|
||||
filePath: entryPath,
|
||||
});
|
||||
}
|
||||
@@ -699,7 +701,8 @@ export function replacePlaceholders(content, provider, commandNames = [], allSki
|
||||
* their command prefix from lib/provider.mjs, whose declaration is replaced
|
||||
* here by an exact string match.
|
||||
*/
|
||||
export function replaceScriptProviderMarker(content, provider, buildProvider = provider) {
|
||||
export function replaceScriptProviderMarker(content, provider) {
|
||||
if (Buffer.isBuffer(content)) return content;
|
||||
const placeholders = PROVIDER_PLACEHOLDERS[provider] || PROVIDER_PLACEHOLDERS.cursor;
|
||||
const commandPrefix = placeholders.command_prefix || '/';
|
||||
const prefixMarker = "export const IMPECCABLE_COMMAND_PREFIX = '/'; // @impeccable-provider-command-prefix";
|
||||
|
||||
Reference in New Issue
Block a user