Skip to content

Conversation

naps62
Copy link
Member

@naps62 naps62 commented Jul 25, 2025

We often need to work on multiple of these components simultaneously, so it's useful to have a way to start this whole stack in one command

@Copilot Copilot AI review requested due to automatic review settings July 25, 2025 10:59
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a mprocs.yaml configuration file to enable starting multiple development services simultaneously with a single command. This is useful for developers who need to work on multiple components of the project at once.

  • Adds configuration for 6 different processes including app, anvil, demo components, UI storybook, and explorer
  • Uses conditional execution to gracefully handle missing directories
  • Sets up proper working directories for components in sibling directories

cmd: ["anvil", "--host", "0.0.0.0"]
demo/web:
cwd: "../demo"
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../demo not found'"]
Copy link
Preview

Copilot AI Jul 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The command uses a complex shell construct with conditional execution. Consider splitting this into a more readable format or using a dedicated script file for better maintainability.

Copilot uses AI. Check for mistakes.

cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../demo not found'"]
demo/contracts:
cwd: "../demo"
cmd: ["sh", "-c", "[ -f package.json ] && yarn eth-watch || echo '../demo not found'"]
Copy link
Preview

Copilot AI Jul 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This command pattern is duplicated across multiple processes. Consider extracting the conditional logic into a reusable script to reduce code duplication.

Copilot uses AI. Check for mistakes.

Comment on lines +8 to +17
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../demo not found'"]
demo/contracts:
cwd: "../demo"
cmd: ["sh", "-c", "[ -f package.json ] && yarn eth-watch || echo '../demo not found'"]
ui/storybook:
cwd: "../ui"
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../ui not found'"]
explorer:
cwd: "../explorer"
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../explorer not found'"]
Copy link
Preview

Copilot AI Jul 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] The error messages are inconsistent - some reference the directory path while others don't. Consider standardizing the error message format across all processes.

Suggested change
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../demo not found'"]
demo/contracts:
cwd: "../demo"
cmd: ["sh", "-c", "[ -f package.json ] && yarn eth-watch || echo '../demo not found'"]
ui/storybook:
cwd: "../ui"
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../ui not found'"]
explorer:
cwd: "../explorer"
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '../explorer not found'"]
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '[../demo] not found or package.json missing'"]
demo/contracts:
cwd: "../demo"
cmd: ["sh", "-c", "[ -f package.json ] && yarn eth-watch || echo '[../demo] not found or package.json missing'"]
ui/storybook:
cwd: "../ui"
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '[../ui] not found or package.json missing'"]
explorer:
cwd: "../explorer"
cmd: ["sh", "-c", "[ -f package.json ] && yarn dev || echo '[../explorer] not found or package.json missing'"]

Copilot uses AI. Check for mistakes.

@naps62 naps62 added the C-chore tedious but necessary label Jul 25, 2025
@naps62 naps62 merged commit 1511c70 into main Jul 25, 2025
7 of 8 checks passed
@naps62 naps62 deleted the mprocs branch July 25, 2025 11:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-chore tedious but necessary
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant