Install scene: fix cmd-bar overlap, swap install command
The "CLICK TO COPY" hint was absolute-positioned at top:10/right:14 of the cmd-box, landing on top of "~/facere — bash" in the bar header. Move the hint into the bar as a flex sibling so the title and hint share the row cleanly without overlap. Replace the placeholder install command with the real installer pulled from raw.githubusercontent.com, with FACERE_GH_TOKEN as a "contact us for demo" placeholder. Also fix deploy/build.sh: `npm init -y` rejects the leading-dot dir name `.build`, and the preset must be resolved by absolute path since babel runs from the repo root.
This commit is contained in:
@@ -15,13 +15,20 @@ BUILD_DIR=".build"
|
||||
mkdir -p "$BUILD_DIR"
|
||||
|
||||
if [ ! -f "$BUILD_DIR/package.json" ]; then
|
||||
( cd "$BUILD_DIR" && npm init -y >/dev/null \
|
||||
&& npm install --silent --no-audit --no-fund \
|
||||
@babel/core@7 @babel/cli@7 @babel/preset-react@7 )
|
||||
# Write package.json directly — `npm init -y` rejects the leading-dot dir name.
|
||||
cat > "$BUILD_DIR/package.json" <<'EOF'
|
||||
{ "name": "facere-build", "version": "1.0.0", "private": true }
|
||||
EOF
|
||||
fi
|
||||
if [ ! -d "$BUILD_DIR/node_modules/@babel/preset-react" ]; then
|
||||
( cd "$BUILD_DIR" && npm install --silent --no-audit --no-fund \
|
||||
@babel/core@7 @babel/cli@7 @babel/preset-react@7 )
|
||||
fi
|
||||
|
||||
# Resolve the preset by absolute path: babel CLI runs from the repo root and
|
||||
# wouldn't find it via the bare name (preset lives in .build/node_modules).
|
||||
"$BUILD_DIR/node_modules/.bin/babel" app.jsx \
|
||||
--presets=@babel/preset-react \
|
||||
--presets="$ROOT/$BUILD_DIR/node_modules/@babel/preset-react" \
|
||||
-o app.js
|
||||
|
||||
echo "Built app.js ($(wc -c < app.js) bytes)"
|
||||
|
||||
Reference in New Issue
Block a user