Thank you for your interest in contributing to our project. Whether it's a bug report, new feature, correction, or additional documentation, we greatly value feedback and contributions from our community.
Please read through this document before editing the code base, submitting any issues, or submitting pull requests to ensure we have all the necessary information to effectively respond to your bug report or contribution.
In this document:
We welcome you to use the GitHub issue tracker to report bugs or suggest features.
When filing an issue, please check existing open, or recently closed, issues to make sure somebody else hasn't already reported the issue. Please try to include as much information as you can. Details like these are incredibly useful:
- A reproducible test case or series of steps
- The version of our code being used
- Any modifications you've made relevant to the bug
- Anything unusual about your environment or deployment
If you discover a potential security issue in this project we ask that you notify AWS/Amazon Security via our vulnerability reporting page. Please do not create a public GitHub issue.
Looking at the existing issues is a great way to find something to contribute on. As our projects, by default, use the default GitHub issue labels (enhancement/bug/duplicate/help wanted/invalid/question/wontfix), looking at any 'help wanted' issues is a great place to start.
This project has adopted the Amazon Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opensource-codeofconduct@amazon.com with any additional questions or comments.
See the LICENSE file for our project's licensing. We will ask you to confirm the licensing of your contribution.
We may ask you to sign a Contributor License Agreement (CLA) for larger changes.
- Git
- Windows only - Windows Subsystem for Linux (WSL)
- Node.js and npm - Tested with Node.js 16 and npm 8
- Clone this repository.
- From the root directory of the repository run:
npm install
To build all packages in the repository, run:
npm run build
Distributable build artifacts will be generated into a dist/
directory within each package folder.
This repository has three methods of testing: unit tests, integration tests, and example applications.
Unit tests and integration tests for each package can be found under <package name>/test/
.
Example applications for Babylon.js can be found in the packages/demos-babylon/
directory. An example application for Three.js can be found in the packages/amazon-sumerian-hosts-three/examples/
directory.
If you've already built the packages, you can execute the unit tests for all packages using the command:
npm run test
Alternately, you can both build and run the unit tests with a single command:
npm run build-test
Integration tests for each package are found under <package name>/test/integration_tests/
. The steps for configuring and running integration tests differ for each package. Details can be found in the README within each package's test/integration_test/
folder.
See the README within packages/demos-babylon/
for instructions on how to set up and run the included Babylon.js demos.
See the README within packages/amazon-sumerian-hosts-three/
for instructions on how to set up and run the included Three.js example.
Contributions via pull requests are much appreciated. Before sending us a pull request, please ensure that:
- You are working against the latest source on the mainline2.0 branch.
- You check existing open and recently merged pull requests to make sure someone else hasn't addressed the problem already.
- You open an issue to discuss any significant work - we would hate for your time to be wasted.
To send us a pull request, please:
- Fork the repository.
- Modify the source; please focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change.
- Ensure local tests pass.
- Commit to your fork using clear commit messages.
- Send us a pull request, answering any default questions in the pull request interface.
- Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation.
GitHub provides additional documentation on forking a repository and creating a pull request.
The @amazon-sumerian-hosts/core
, @amazon-sumerian-hosts/babylon
, and @amazon-sumerian-hosts/three
packages are all published and distributed via the npmjs.com registry. To publish a new version of the packages to the NPM registry, follow these steps...
- Update
package.json
with a new version number using semantic versioning. All of the packages in the repo should always share the same version number, so ensure that updates have been made to thepackage.json
files in the following directories:- The root of the mono repository
amazon-sumerian-hosts-babylon
amazon-sumerian-hosts-core
amazon-sumerian-hosts-three
demos-babylon
- Make sure to run
npm install
to regenerate thepackage-lock.json
file. - Create a new release using the GitHub.com console. See previous releases for reference.
- In the release creation form, create a new repository tag labeling it using the package version number prefixed with "v". Example: "v2.1.3"
- Set the target of the release to the
mainline2.0
branch. - Set the title of the release to match the tag name. Example: "v2.1.3"
- In the release description field, add a heading in the form "Host Release {version number} - {Reason for Release}". Example: "Host Release 1.3.1 - Bug Fixes"
- Append all significant changes as bullet points.
- Click "Publish release". This will automatically trigger a GitHub Action that publishes the release to the NPM registry.
- Validate the GitHub properly releases to NPM through Actions tab.