This monorepo serves as a workspace for Crossify projects, providing an organized structure for managing related repositories.
This monorepo is designed to manage and organize Crossify projects using a monorepo structure. It uses tools like NPM Workspaces to manage multiple packages and shared dependencies efficiently.
- Clone this repository to your local machine:
git clone https://github.com/crossify/workspace.git
- Navigate to the root directory of the cloned repository:
cd workspace
- Prep repos using prep script ( if there is any change in the package.json file of any repo, you need to run this script again ):
npm run prep
The workspace is organized as follows:
workspace/
├── types/
├── mongoose/
├── web/
├── api/
├── analytics/
├── event-bus/
├── ... (other repos)
├── .gitignore
├── package.json
├── README.md
├── LICENSE.md
├── *.js
└── *.sh
@crossify/types/
: Shared types and interfaces used across different projects.@crossify/mongoose/
: Mongoose schema and models package.web/
,api/
,analytics/
,event-bus/
: Project-specific repos..gitignore
: Git ignore rules for the monorepo.package.json
: Workspace-level package.json file.package-lock.json
: NPM lockfile.
You can use NPM scripts to manage and work with the packages in this monorepo:
- To run dev:
bun run dev
- To push changes:
bun run push
For specific packages, navigate to their directories and run NPM commands as needed.
While the monorepo processes are running, you can interact with them directly from the terminal:
- To send a command to all processes:
<any_command>
- To target a specific repository:
<repo_name>:<any_command>
For example, to send a restart command only to the web repo, you would type:
web:rs
This feature allows for flexible and fine-grained control over each repository process directly from your terminal.
This README provides an overview of the monorepo structure, how to get started, how to use NPM commands, contributing guidelines, and licensing information. Customize it further to match your specific monorepo setup and needs.