Skip to content

Commit 8772210

Browse files
Enhance contribution guidelines and add licensing FAQ for monorepo transition
1 parent 1204d15 commit 8772210

File tree

4 files changed

+289
-0
lines changed

4 files changed

+289
-0
lines changed

CONTRIBUTING.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,17 @@
11
# Tips for Contributors
22

3+
**🏗️ Important: Monorepo Merger in Progress**
4+
5+
We are currently working on merging the `react_on_rails` and `react_on_rails_pro` repositories into a unified monorepo. This will provide better development experience while maintaining separate package identities and licensing. See [docs/MONOREPO_MERGER_PLAN_REF.md](./docs/MONOREPO_MERGER_PLAN_REF.md) for details.
6+
7+
During this transition:
8+
9+
- Continue contributing to the current structure
10+
- License compliance remains critical - ensure no Pro code enters MIT-licensed areas
11+
- Major structural changes may be coordinated with the merger plan
12+
13+
---
14+
315
- [docs/contributor-info/Releasing](./docs/contributor-info/releasing.md) for instructions on releasing.
416
- [docs/contributor-info/pull-requests](./docs/contributor-info/pull-requests.md)
517
- See other docs in [docs/contributor-info](./docs/contributor-info)

docs/DIRECTORY_LICENSING.md

Lines changed: 135 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,135 @@
1+
# Directory Licensing Documentation
2+
3+
This document outlines the current and post-merger directory licensing structure for React on Rails projects.
4+
5+
## Current Structure (Pre-Merger)
6+
7+
### react_on_rails Repository - MIT Licensed
8+
9+
All directories in the `react_on_rails` repository are MIT licensed:
10+
11+
```
12+
react_on_rails/
13+
├── lib/react_on_rails/ # Core Ruby code (MIT)
14+
├── node_package/src/ # Core JS/TS code (MIT)
15+
│ └── pro/ # Pro features placeholder (MIT but references pro)
16+
├── spec/ # Core tests (MIT)
17+
├── docs/ # Documentation (MIT)
18+
├── .github/ # GitHub workflows (MIT)
19+
└── [all other directories] # MIT
20+
```
21+
22+
**Exception:** The `node_package/src/pro/` directory contains placeholder code that references Pro features, but the actual Pro implementation is in the separate `react_on_rails_pro` repository.
23+
24+
### react_on_rails_pro Repository - Pro Licensed
25+
26+
All directories in the `react_on_rails_pro` repository are Pro licensed:
27+
28+
```
29+
react_on_rails_pro/
30+
├── lib/react_on_rails_pro/ # Pro Ruby code
31+
├── packages/node-renderer/ # Pro Node.js renderer
32+
├── spec/ # Pro tests
33+
├── .circleci/ # CircleCI config
34+
└── [all other directories] # Pro licensed
35+
```
36+
37+
## Post-Merger Structure (Target)
38+
39+
After the monorepo merger, the unified repository will have clear directory-based licensing:
40+
41+
### MIT Licensed Directories
42+
43+
```
44+
react_on_rails/ (monorepo root)
45+
├── lib/react_on_rails/ # Core Ruby code
46+
├── packages/react-on-rails/ # Core NPM package
47+
├── spec/ruby/react_on_rails/ # Core Ruby tests
48+
├── spec/packages/react-on-rails/ # Core JS tests
49+
├── docs/ # Shared documentation
50+
├── tools/ # Shared development tools
51+
├── .github/ # Unified GitHub workflows
52+
└── [shared config files] # Build configs, etc.
53+
```
54+
55+
### Pro Licensed Directories
56+
57+
```
58+
react_on_rails/ (monorepo root)
59+
├── lib/react_on_rails_pro/ # Pro Ruby code
60+
├── packages/react-on-rails-pro/ # Pro NPM package
61+
├── packages/react-on-rails-pro-node-renderer/ # Pro Node renderer
62+
├── spec/ruby/react_on_rails_pro/ # Pro Ruby tests
63+
├── spec/packages/react-on-rails-pro/ # Pro JS tests
64+
└── spec/packages/react-on-rails-pro-node-renderer/ # Pro Node renderer tests
65+
```
66+
67+
## License Compliance Rules
68+
69+
### File-Level Compliance
70+
71+
1. **Repository-Level Licensing**: Files inherit their license from the directory they're located in
72+
2. **No Mixed Directories**: Each directory is either entirely MIT or entirely Pro - no mixed licensing within a directory
73+
3. **Clear Boundaries**: The `LICENSE.md` file explicitly lists which directories fall under which license
74+
75+
### Package-Level Compliance
76+
77+
1. **Gemspec Files**:
78+
79+
- `react_on_rails.gemspec`: `s.license = "MIT"`
80+
- `react_on_rails_pro.gemspec`: `s.license = "UNLICENSED"`
81+
82+
2. **Package.json Files**:
83+
- `packages/react-on-rails/package.json`: `"license": "MIT"`
84+
- `packages/react-on-rails-pro/package.json`: `"license": "UNLICENSED"`
85+
- `packages/react-on-rails-pro-node-renderer/package.json`: `"license": "UNLICENSED"`
86+
87+
### Critical Compliance Points
88+
89+
1. **Never Move Pro Code to MIT Directories**: During the merger, strict verification ensures no Pro-licensed code accidentally ends up in MIT-licensed directories
90+
91+
2. **Update LICENSE.md Immediately**: Whenever directories are moved or created, `LICENSE.md` must be updated to reflect the new structure
92+
93+
3. **Automated Verification**: CI checks will verify:
94+
- All Pro directories are listed in LICENSE.md
95+
- Package.json and gemspec files have correct license fields
96+
- No orphaned or unlisted directories exist
97+
98+
## Migration Phases and License Updates
99+
100+
The monorepo merger plan includes specific license compliance checkpoints at each phase:
101+
102+
- **Phase 1**: Update license references and documentation
103+
- **Phase 2**: Establish dual CI with clear directory boundaries
104+
- **Phase 3-4**: Reorganize directories while maintaining license compliance
105+
- **Phase 5-6**: Finalize structure and add automated license checking
106+
- **Phase 7**: Complete documentation and verification
107+
108+
Each phase includes mandatory license compliance verification before proceeding to the next phase.
109+
110+
## Developer Guidelines
111+
112+
### When Adding New Files
113+
114+
1. Determine if the functionality is Core (MIT) or Pro (subscription required)
115+
2. Place the file in the appropriate licensed directory
116+
3. Ensure the package.json or gemspec correctly reflects the license
117+
4. Update LICENSE.md if creating new directories
118+
119+
### When Moving Files
120+
121+
1. Verify the destination directory has the correct license for the file content
122+
2. Never move Pro features to MIT directories
123+
3. Update import statements and references
124+
4. Verify no licensing boundaries are crossed inappropriately
125+
126+
### When Contributing
127+
128+
1. Core features (MIT): Open for all contributors
129+
2. Pro features: Contributions become part of Pro offering
130+
3. Shared tooling/docs (MIT): Benefits both packages
131+
4. License compliance: Never compromise on proper licensing
132+
133+
---
134+
135+
_This document is maintained as part of the React on Rails monorepo merger plan. For implementation details, see [MONOREPO_MERGER_PLAN_REF.md](./MONOREPO_MERGER_PLAN_REF.md)_

docs/LICENSING_FAQ.md

Lines changed: 126 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
# React on Rails Licensing FAQ
2+
3+
## Post-Monorepo Merger Licensing
4+
5+
### Q: What will happen to licensing after the monorepo merger?
6+
7+
**A:** Nothing changes for end users! We'll maintain the same dual licensing structure:
8+
9+
- **MIT Licensed (Free & Open Source):**
10+
11+
- `react_on_rails` Ruby gem
12+
- `react-on-rails` NPM package
13+
- Core functionality remains completely free
14+
15+
- **Pro Licensed (Subscription Required for Production):**
16+
- `react_on_rails_pro` Ruby gem
17+
- `react-on-rails-pro` NPM package
18+
- `react-on-rails-pro-node-renderer` NPM package
19+
- Advanced features require valid subscription
20+
21+
### Q: Will package installation or usage change?
22+
23+
**A:** Yes. The Pro packages will become public instead of private. If you need Pro features, you will need to install the `react-on-rails-pro` NPM package in addition to `react-on-rails`, and import Pro features from `react-on-rails-pro`.
24+
25+
### Q: How will the monorepo structure maintain license separation?
26+
27+
**A:** The monorepo will have clear directory-based license boundaries:
28+
29+
```
30+
react_on_rails/ (monorepo root)
31+
├── lib/
32+
│ ├── react_on_rails/ # MIT Licensed
33+
│ └── react_on_rails_pro/ # Pro Licensed
34+
├── packages/
35+
│ ├── react-on-rails/ # MIT Licensed
36+
│ ├── react-on-rails-pro/ # Pro Licensed
37+
│ └── react-on-rails-pro-node-renderer/ # Pro Licensed
38+
└── LICENSE.md # Documents which directories use which license
39+
```
40+
41+
### Q: What about contributing to the project?
42+
43+
**A:** Contributors should be aware of license boundaries:
44+
45+
- **MIT areas:** Anyone can contribute freely
46+
- **Pro areas:** Contributions require agreement that improvements become part of the Pro offering
47+
- **License compliance:** Never move Pro code into MIT-licensed directories
48+
49+
### Q: Will there be automated license compliance checking?
50+
51+
**A:** Yes! The monorepo will include automated checks to ensure:
52+
53+
- Pro files have proper license headers
54+
- Pro code never accidentally enters MIT-licensed directories
55+
- LICENSE.md accurately reflects all directory classifications
56+
- CI fails if license compliance is violated
57+
58+
### Q: What if I'm currently using both packages?
59+
60+
**A:** Perfect! The monorepo makes this easier:
61+
62+
- Unified development and testing
63+
- Coordinated releases when needed
64+
- Shared tooling and documentation
65+
- Same separate billing and licensing as today
66+
67+
### Q: Will documentation change?
68+
69+
**A:** Documentation will be enhanced:
70+
71+
- Combined docs show both free and pro features clearly
72+
- Examples will be properly labeled by license
73+
- Installation guides remain the same
74+
- License boundaries clearly documented
75+
76+
### Q: When will this happen?
77+
78+
**A:** The merger is planned as a 7-phase process. Each phase maintains full functionality and CI compliance. See [MONOREPO_MERGER_PLAN_REF.md](./MONOREPO_MERGER_PLAN_REF.md) for details.
79+
80+
### Q: What if something goes wrong during the merger?
81+
82+
**A:** Each phase has:
83+
84+
- Complete rollback procedures
85+
- Clear success criteria
86+
- CI verification before proceeding
87+
- Community feedback integration
88+
- Immediate issue resolution process
89+
90+
---
91+
92+
## Current Licensing (Pre-Merger)
93+
94+
### Q: How does licensing work today?
95+
96+
**A:** We maintain two separate repositories:
97+
98+
- **react_on_rails** (MIT) - Core functionality, completely free except pro directories as stated in LICENSE.md
99+
- **react_on_rails_pro** (Pro License) - Advanced features, subscription required for production
100+
101+
### Q: What requires a Pro subscription?
102+
103+
**A:** Pro features include:
104+
105+
- Server-side rendering optimizations
106+
- Advanced caching strategies
107+
- React Server Components support
108+
- Node.js rendering process management
109+
- Premium support and consultation
110+
111+
See [REACT-ON-RAILS-PRO-LICENSE.md](../REACT-ON-RAILS-PRO-LICENSE.md) for complete Pro license terms.
112+
113+
### Q: Can I try Pro features for free?
114+
115+
**A:** Yes! Pro license allows free use for:
116+
117+
- Educational/classroom use
118+
- Personal hobby projects
119+
- Tutorials and demonstrations
120+
- Non-production evaluation
121+
122+
Production use requires a valid subscription.
123+
124+
---
125+
126+
_For more information about the monorepo merger, see [MONOREPO_MERGER_PLAN_REF.md](./MONOREPO_MERGER_PLAN_REF.md)_

docs/MONOREPO_MERGER_PLAN_REF.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# React on Rails Monorepo Merger Plan Reference
2+
3+
The complete React on Rails Monorepo Merger Plan is located at:
4+
5+
**[docs/MONOREPO_MERGER_PLAN.md](/mnt/ssd/react_on_rails_workspace/react_on_rails/docs/MONOREPO_MERGER_PLAN.md)**
6+
7+
This plan outlines the 7-phase implementation for merging the `react_on_rails` and `react_on_rails_pro` repositories into a unified monorepo while maintaining:
8+
9+
- Separate package identities (2 Ruby gems + 3 NPM packages)
10+
- Proper license compliance (MIT vs Pro)
11+
- Complete git history preservation
12+
- CI integrity at every step
13+
14+
**Status:** Phase 1 - License Cleanup & Documentation (In Progress)
15+
16+
For implementation details, progress tracking, and specific tasks, refer to the main plan document.

0 commit comments

Comments
 (0)