unlimited ai usage for affine
This commit is contained in:
@@ -14,7 +14,7 @@
|
||||
openssl,
|
||||
inputs,
|
||||
system,
|
||||
frontendPatches ? [ ./gitea-document-typography.patch ./byok-model-picker.patch ],
|
||||
frontendPatches ? [ ./gitea-document-typography.patch ./byok-model-picker.patch ./self-hosted-ai-usage.patch ],
|
||||
}:
|
||||
|
||||
let
|
||||
@@ -188,11 +188,12 @@ let
|
||||
cp -R packages/frontend/apps/mobile/dist "$out/mobile"
|
||||
runHook postInstall
|
||||
'';
|
||||
} // lib.optionalAttrs (builtins.elem ./byok-model-picker.patch frontendPatches) {
|
||||
} // lib.optionalAttrs (builtins.elem ./byok-model-picker.patch frontendPatches || builtins.elem ./self-hosted-ai-usage.patch frontendPatches) {
|
||||
doCheck = true;
|
||||
checkPhase = ''
|
||||
runHook preCheck
|
||||
AFFINE_SOURCE_DIR="$PWD" ${nodejs}/bin/node ${../../test/package/affine/test/model-picker.cjs}
|
||||
${lib.optionalString (builtins.elem ./byok-model-picker.patch frontendPatches) ''AFFINE_SOURCE_DIR="$PWD" ${nodejs}/bin/node ${../../test/package/affine/test/model-picker.cjs}''}
|
||||
${lib.optionalString (builtins.elem ./self-hosted-ai-usage.patch frontendPatches) ''AFFINE_SOURCE_DIR="$PWD" ${nodejs}/bin/node ${../../test/package/affine/test/ai-usage.cjs}''}
|
||||
runHook postCheck
|
||||
'';
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user