Add dev environment setup instructions (#435)

This commit is contained in:
Martin Feckie 2019-10-28 20:53:07 +08:00 committed by 강동윤
parent ae3326cd9d
commit cf880d5b33

View File

@ -75,6 +75,20 @@ You can use `rustup component add --toolchain nightly rustfmt-preview` to instal
`rustfmt +nightly --unstable-features --skip-children` on the changed files to automatically format your code.
* Push your commits to GitHub and create a pull request against swc's `master` branch.
## Getting your development environment set up
After cloning the project there are a few steps required to get the project running.
1. `git submodule update --init --recursive` This will pull in the ecmascript test suited
2. Go to the folder `ecmascript/transforms` and run `yarn install`
3. You need to setup some environment variables in order for the tests to run
```
RUST_MIN_STACK=16777216
RUSTFLAGS="--cfg procmacro2_semver_exempt"
```
4. You can now run the tests with `RUST_BACKTRACE=full cargo test --color always --all --all-features`
## Pull requests