Lines 1-21javascript
1import { spawn, spawnSync } from 'child_process';
2import { existsSync, readFileSync, writeFileSync, mkdirSync, readdirSync, lstatSync, rmdirSync, unlinkSync } from 'fs';
HighChild Process
Package source references child process execution.
dist/git.jsView on unpkg · L1 3import { join, resolve, dirname } from 'path';
4import { homedir } from 'os';
5import { createHash } from 'crypto';
6import { friendlyName } from './draftname.js';
7/** Run a git command in `cwd`, capturing output. Never throws — failure is data. */
8function git(cwd, args) {
9 const r = spawnSync('git', args, { cwd, encoding: 'utf8' });
10 return { ok: !r.error && r.status === 0, out: ((r.stdout ?? '') + (r.stderr ?? '')).trim() };
13 * Step-by-step trace of a publish/reconcile, so an operation that reshapes history (auto-rebase,
14 * FF, dep install) is debuggable after the fact. Always attached to the `PublishResult` (the UI
15 * can surface it under an expandable "details" affordance); also echoed to the server console when
16 * `FLOPOD_DEBUG` is set, so a headless run leaves a trail too. Purely diagnostic — never a value
17 * anything branches on.
19const DEBUG = !!process.env.FLOPOD_DEBUG;
20function trace(log, msg) {
LowWeak Crypto
Package source references weak cryptographic algorithms.
dist/git.jsView on unpkg · L1