This repository has been archived by the owner on May 28, 2022. It is now read-only.
design: Monorepo Refactor -> Multiple Repositories #142
Labels
design
This is a design issue - requires attention from a senior engineer
enhancement
New feature or request
needs more info
This issue is not yet actionable
We currently live in package dependency hell -- the monorepo's property that all code is co-located in the same filesystem ended up being a little bit of a crutch and we made some bad code hygiene decisions out of expediency.
We're going to claw ourselves out of Dante's Typescript Inferno via Yarn Workspaces, adding some enforced rules on dependencies and the relationships between typescript packages to make things intuitive and easy.
Goal:
Sequencing:
We're going to refactor
nomad-monorepo
into a series of smaller monorepo work trees.nomad-config
-> Configuration root, most releasable packages depend on this (this will be a git submodule on most of the other repos below that depend on it)nomad-sol
-> Contracts, depends onnomad-config
nomad-rs
-> Rust folder, same structure as current, depends onnomad-sol
rust bindings andnomad-config
nomad-ts
-> TS libraries and services, depends onnomad-sol
ABIs,nomad-config
(everything here would be a deployable package on npm)nomad-services
-> for tools such asnomad-indexer
,nomad-monitor
,keymaster
,local-environment
How do we get here?
In this order:
Post-move to new repo structure
Not in any order, doesn't need to happen immediately
Notable Changes:
solidity
andtypescript/typechain
packages into multiplecontracts-*
packagescontracts-core
- Core contract source code and typescript interfacescontracts-bridge
- Bridge contract source code and typescript interfacesexamples
workspace, containing sub-workspaces for individual examplesrust
workspace with sub-workspaces containing individual Rust cratesOutstanding Questions:
@nomad-xyz/sdk
package and namespace functionality via sub-directories (ex:@nomad-xyz/sdk/core
or@nomad-xyz/sdk/bridge
)?@nomad-xyz/contracts/core
vs@nomad-xyz/contracts-core
nomad-tests
and put tests for individual contract suites in their own packages? (core, bridge, etc)nomad-deploy
?What do we do when we add a new network?
Say we're adding a new network to the dev environment, what happens now?
The text was updated successfully, but these errors were encountered: