Skip to content

Conversation

@takaokouji
Copy link

@takaokouji takaokouji commented Jan 25, 2026

Summary

This PR adds root-level scripts to the monorepo package.json to facilitate CI/CD integration and ensure correct build order between workspaces.

Changes

  • Add build:vm, build:gui scripts
  • Add lint:gui, lint:vm scripts
  • Add test:unit:gui, test:unit:vm scripts
  • Add test:integration:gui, test:integration:vm scripts
  • Update build, lint, test, test:unit, test:integration to use these scripts

These changes are required for Phase 6 of the monorepo migration (smalruby/smalruby3-develop#40).

🤖 Generated with Gemini Code

- Add build:vm, build:gui scripts
- Add lint:gui, lint:vm scripts
- Add test:unit:gui, test:unit:vm scripts
- Add test:integration:gui, test:integration:vm scripts
- Update build, lint, test, test:unit, test:integration to use these scripts

These scripts ensure correct build order and allow CI to target specific workspaces easily.

🤖 Generated with [Gemini Code](https://gemini.google.com/code)

Co-Authored-By: Gemini <noreply@google.com>
takaokouji and others added 7 commits January 26, 2026 09:53
- Add globalIgnores for generated files (static, test, src/examples, coverage)
- Add max-len rule exception for locale files (src/locales/*.js)
- Fix react/jsx-max-props-per-line error in preference-menu.jsx
- Fix quotes errors in en.js (double to single quotes)
- Fix eol-last error in index.ts

Related to Phase 1 of #40

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Add new ci-cd.yml workflow for monorepo (build, lint, unit tests)
- Remove old ci.yml (merged into ci-cd.yml)
- Remove publish.yml (will restore when needed)
- Remove update-i18n.yml (will restore when needed)
- Remove signature-assistant.yml (will restore when needed)
- Remove ghpages-cleanup.yml (will restore when needed)
- Keep commitlint.yml and gha-debug.yml as-is

Implements Phase 1 of #40

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Add build:vm script to build dependencies in correct order:
  task-herder → scratch-svg-renderer → scratch-render → scratch-vm
- Add build:gui script to build scratch-gui separately
- Add lint scripts (lint:gui, lint:vm)
- Add test scripts (test:unit, test:integration for both gui and vm)

This ensures scratch-vm can find scratch-render's built files during webpack config loading.

Fixes CI build failure in Phase 1 of #40

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Restore upstream-compatible build script (NODE_ENV=production)
- Add build:dev script for lint/test workflows (development mode)
- Add build:dev to all workspace packages
  (task-herder, scratch-svg-renderer, scratch-render, scratch-vm)
- Update CI/CD workflow to use build:dev
- Use --workspaces flag (executes in package.json order)

This maintains upstream compatibility while providing separate
development builds for CI.

Implements Phase 1 of #40

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
- Add 'test' state to mocked Redux store in unit test.
- Use optional chaining when accessing 'state.scratchGui.test' in SBFileUploaderHOC.

Co-Authored-By: Gemini <noreply@google.com>
@takaokouji takaokouji force-pushed the feature/issue-40-cicd-monorepo branch from 5ed55af to 358f85e Compare January 26, 2026 06:32
takaokouji and others added 4 commits January 26, 2026 16:03
- Add lint, test:unit, test:integration to each package.json
- Update root package.json to use npm run --workspaces for these scripts
- Ensure CI/CD uses standardized commands

🤖 Generated with [Gemini Code](https://gemini.google.com/code)

Co-Authored-By: Gemini <noreply@google.com>
- Update package.json files for scratch-gui, scratch-render, scratch-vm,
  scratch-svg-renderer, and task-herder.
- Set unique JEST_JUNIT_OUTPUT_NAME or reporter-file names for each package.
- Ensure test results can be collected as separate artifacts in GitHub Actions.

🤖 Generated with [Gemini Code](https://gemini.google.com/code)

Co-Authored-By: Gemini <noreply@google.com>
- Revert package-specific JUnit output filenames to generic names (e.g., unit-tests-results.xml).
- Since npm run --workspaces stores results in separate directories per package,
  unique filenames are redundant.
- Affects scratch-gui, scratch-render, scratch-vm, scratch-svg-renderer, and task-herder.

🤖 Generated with [Gemini Code](https://gemini.google.com/code)

Co-Authored-By: Gemini <noreply@google.com>
- Remove VITEST_JUNIT_OUTPUT_FILE from task-herder/package.json test:unit script.
- The output is already correctly handled and the variable was being ignored.

🤖 Generated with [Gemini Code](https://gemini.google.com/code)

Co-Authored-By: Gemini <noreply@google.com>
@takaokouji takaokouji merged commit 1f64d01 into develop Jan 26, 2026
2 of 3 checks passed
@takaokouji takaokouji deleted the feature/issue-40-cicd-monorepo branch January 26, 2026 14:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants