()
| 31 | } |
| 32 | |
| 33 | async function createWallpapers() { |
| 34 | const inputDirectory = path.join(process.cwd(), "data", "wallpapers"); |
| 35 | const outputDirectory = path.join( |
| 36 | process.cwd(), |
| 37 | "public", |
| 38 | "images", |
| 39 | "wallpapers" |
| 40 | ); |
| 41 | const filenames = fs.readdirSync(inputDirectory); |
| 42 | await Promise.all( |
| 43 | filenames.map(async (file: string) => { |
| 44 | await createWallpaper(inputDirectory, outputDirectory, file, 2880, 1800); |
| 45 | await createWallpaper(inputDirectory, outputDirectory, file, 1920, 1080); |
| 46 | await createWallpaper(inputDirectory, outputDirectory, file, 1920, 1200); |
| 47 | await createWallpaper(inputDirectory, outputDirectory, file, 660, 400); |
| 48 | }) |
| 49 | ); |
| 50 | } |
| 51 | |
| 52 | export async function createLogo( |
| 53 | inputDirectory: string, |
no test coverage detected