2162 Add asset watcher in twenty-sdk dev mode (#17513)

- assets are pushed in .twenty/output
- assets are uploaded in FileFolder.Assets
- not handled yet by the sync-manifest endpoint
This commit is contained in:
martmull
2026-01-29 10:08:44 +01:00
committed by GitHub
parent 1cc08b84c4
commit 3412992e99
42 changed files with 414 additions and 135 deletions
@@ -1,6 +1,7 @@
import * as fs from 'fs-extra';
import { join } from 'path';
import { v4 } from 'uuid';
import { ASSETS_DIR } from 'twenty-shared/application';
const APP_FOLDER = 'src';
@@ -21,6 +22,8 @@ export const copyBaseApplicationProject = async ({
await createGitignore(appDirectory);
await createPublicAssetDirectory(appDirectory);
await createYarnLock(appDirectory);
const appFolderPath = join(appDirectory, APP_FOLDER);
@@ -47,6 +50,10 @@ export const copyBaseApplicationProject = async ({
});
};
const createPublicAssetDirectory = async (appDirectory: string) => {
await fs.ensureDir(join(appDirectory, ASSETS_DIR));
};
const createYarnLock = async (appDirectory: string) => {
const yarnLockContent = `# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
# yarn lockfile v1