Skip to content

Conversation

andrew-fleming
Copy link
Contributor

Types of changes

What types of changes does your code introduce to OpenZeppelin Midnight Contracts?
Put an x in the boxes that apply

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation Update (if none of the other choices apply)

Fixes #240.

PR Checklist

  • I have read the Contributing Guide
  • I have added tests that prove my fix is effective or that my feature works
  • I have added documentation of new methods and any new behavior or changes to existing behavior
  • CI Workflows Are Passing

Overview

This PR proposes to add the compact format feature from Compact dev tools. To better support this feature, and forthcoming features, this PR proposes to refactor the compiler workflow (again) by utilizing an abstract BaseServices module that can be easily extended for more features. This approach provides consistency and allows each feature to be tested well.

This PR also proposes to change fmt-and-lint to simply check i.e. check and check:fix (which follows biome's naming convention). The idea is to better delineate Compact formatting and TS formatting (via biome). This also keeps the command short

Finally, this PR includes proper formatting for Compact modules and mock contracts

Additions

  • Abstract BaseServices module
  • format and format:fix commands
  • tests for format files
  • CI check for Compact formatting

Changes

  • Abstract logic from compiler to BaseServices
  • Change fmt-and-lint to check
  • useLiteralKeys: false in biome (to simplify testing)
  • Format Compact modules and contracts

Waiting on #233 (requires compact v0.25.0)

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.

Support compact format
1 participant