GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — lowcode-engine/scripts/set-repo.js at main · liylong/lowcode-engine Expand file tree/ Copy pathset-repo.jsMore file actions 45 lines (42 loc) · 1.54 KB / Copy pathset-repo.jsFile metadata and controls45 lines (42 loc) · 1.54 KB 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 #!/usr/bin/env node const path = require('path'); const fs = require('fs-extra'); (async () => { const root = path.join(__dirname, '../'); const workspaces = ['modules', 'packages']; for (const workspace of workspaces) { const pkgDir = path.join(root, workspace); const pkgs = await fs.readdir(pkgDir); for (const pkg of pkgs) { if (pkg.charAt(0) === '.') continue; if (!(await fs.statSync(path.join(pkgDir, pkg))).isDirectory()) continue; await setRepo({ workspace, pkgDir, pkg, }); } } async function setRepo(opts) { const pkgDir = path.join(opts.pkgDir, opts.pkg); const pkgPkgJSONPath = path.join(pkgDir, 'package.json'); if (!fs.existsSync(pkgPkgJSONPath)) { console.log(`${opts.pkg} exists`); } else { const pkgPkgJSON = require(pkgPkgJSONPath); fs.writeJSONSync( pkgPkgJSONPath, Object.assign(pkgPkgJSON, { repository: { type: 'http', url: `https://github.com/alibaba/lowcode-engine/tree/main/${opts.workspace}/${opts.pkg}`, }, bugs: 'https://github.com/alibaba/lowcode-engine/issues', homepage: 'https://github.com/alibaba/lowcode-engine/#readme', }), { spaces: ' ' }, ); console.log(`[Write] ${opts.pkg}`); } } })(); |
| You are visitor 01402792 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |