aboutsummaryrefslogtreecommitdiffstats
path: root/docs
diff options
context:
space:
mode:
Diffstat (limited to 'docs')
-rw-r--r--docs/HACKING_QUICKSTART.md25
1 files changed, 17 insertions, 8 deletions
diff --git a/docs/HACKING_QUICKSTART.md b/docs/HACKING_QUICKSTART.md
index d391ae5da08..b97d6a5ff4b 100644
--- a/docs/HACKING_QUICKSTART.md
+++ b/docs/HACKING_QUICKSTART.md
@@ -108,20 +108,29 @@ This is how my projects are laid out:
```
~/my-projects/servo/
-~/my-projects/cocoa-rs/
-~/my-projects/glutin/
+~/my-projects/mozjs/
```
+Both folder are git repositories.
-These are all git repositories.
+To make it so that servo uses `~/my-projects/mozjs/`, first ascertain which version of the crate Servo is using and whether it is a git dependency or one from crates.io.
-To make it so that servo uses `~/my-projects/cocoa-rs/` and `~/my-projects/glutin/` , create a `~/my-projects/servo/.cargo/config` file:
+Both information can be found using, in this example, `/mach cargo pkgid mozjs_sys`(`mozjs_sys` is the actual crate name, which doesn't necessarily match the repo folder name).
-``` shell
-$ cat ~/my-projects/servo/.cargo/config
-paths = ['../glutin', '../cocoa-rs']
+If the output is in the format `https://github.com/servo/mozjs#mozjs_sys:0.0.0`, you are dealing with a git dependency and you will have to edit the `~/my-projects/servo/Cargo.toml` file and add at the bottom:
+
+``` toml
+[replace]
+"https://github.com/servo/mozjs#mozjs_sys:0.0.0" = { path = '../mozjs' }
+```
+
+If the output is in the format `https://github.com/rust-lang/crates.io-index#mozjs_sys#0.0.0`, you are dealing with a crates.io dependency and you will have to edit the `~/my-projects/servo/Cargo.toml` in the following way:
+
+``` toml
+[replace]
+"mozjs_sys:0.0.0" = { path = '../mozjs' }
```
-This will tell any cargo project to not use the online version of the dependency, but your local clone.
+Both will tell any cargo project to not use the online version of the dependency, but your local clone.
For more details about overriding dependencies, see [Cargo's documentation](http://doc.crates.io/specifying-dependencies.html#overriding-dependencies).