Tools for Jsparagus and SmooshMonkey development
- Clone this repository
- Add
bin
directory in the clone into yourPATH
- Place the
mozilla-central
clone next to thejsparagus
clone - Make sure
origin
remote ofjsparagus
is your fork of official jsparagus - Make sure
upstream
remote ofjsparagus
is official jsparagus - Make sure
mozilla-central
is git repository with git-cinnabar tohg::https://hg.mozilla.org/mozilla-unified
, if you want to push to try with single command
cd {path-to-mozilla-central}
smoosh-tools build --local
This does the following:
- Run
make all
in jsparagus - Modify m-c/js/src/frontend/smoosh/Cargo.toml to point local jsparagus
- Run
./mach build
with a mozconfig for debug build, with--enable-smoosh
option added
If you want to use optimized build, pass --opt
.
smoosh-tools build --local --opt
cd {path-to-mozilla-central}
smoosh-tools run
If you want to use optimized build, pass --opt
.
smoosh-tools run --opt
cd {path-to-mozilla-central}
smoosh-tools jstests
smoosh-tools jit-test
If you want to use optimized build, pass --opt
.
smoosh-tools jstests --opt
smoosh-tools jit-test --opt
Push to try with current local jsparagus and mozilla-central. (This needs Level 1 Commit Access to hg.mozilla.org, and SSH set up for it)
cd {path-to-jsparagus}
# Create a branch {branch-name} for the modification here, if not yet.
# Commit modified files here, if not yet.
cd {path-to-mozilla-central}
# Commit modified files here, if not yet.
smoosh-tools try
This does th following:
- create
{branch-name}-generated-branch
branch on jsparagus, with generated files - push above to jsparagus fork (
origin
) - push to try with the following commits:
- update Cargo.toml to refer the above
{branch-name}-generated-branch
branch, and./mach vendor rust
- try syntax
try: -b do -p sm-smoosh-linux64 -u none -t none
(note that SM(smoosh) is tier3 job, that is hidden by default)
- update Cargo.toml to refer the above
- Remove all temporary commits generated above
Bump jsparagus revision to ci_generated
branch HEAD.
Once the PR for jsparagus gets merged, it needs to be vendored into mozilla-central, by bumping the referred revision.
cd {path-to-mozilla-central}
smoosh-tools cargo o -
./mach vendor rust
# Commit updated/vendored files here.
See Commands.md