- Introduced a Makefile for streamlined commands related to building, running, and managing presentations. - Created package.json to define project metadata, dependencies, and scripts for development and testing. - Added .gitignore entries to exclude build artifacts and temporary files from version control. - Included playwright.config.mjs for end-to-end testing setup with Playwright. - Added README.md for project documentation, outlining setup instructions and development guidelines.
21 lines
634 B
JavaScript
21 lines
634 B
JavaScript
/**
|
|
* Dossiers de présentation sous slides/ (hors wip_*), avec meta.json + slides.md.
|
|
*/
|
|
import fs from 'node:fs'
|
|
import path from 'node:path'
|
|
|
|
export function listPresentationSlugs(root) {
|
|
const slides = path.join(root, 'slides')
|
|
if (!fs.existsSync(slides)) return []
|
|
return fs
|
|
.readdirSync(slides, { withFileTypes: true })
|
|
.filter((d) => d.isDirectory() && !d.name.startsWith('wip_') && !d.name.startsWith('_'))
|
|
.map((d) => d.name)
|
|
.filter((slug) => {
|
|
return (
|
|
fs.existsSync(path.join(slides, slug, 'meta.json')) &&
|
|
fs.existsSync(path.join(slides, slug, 'slides.md'))
|
|
)
|
|
})
|
|
}
|