bors [Thu, 18 Jan 2018 19:02:11 +0000 (19:02 +0000)]
Auto merge of #4955 - sfackler:allow-package, r=alexcrichton
Allow packaging of crates with unstable features
We don't want them to land on crates.io, but it's fine to make a .crate
file.
Closes #4954
Steven Fackler [Thu, 18 Jan 2018 18:35:40 +0000 (10:35 -0800)]
Allow packaging of crates with unstable features
We don't want them to land on crates.io, but it's fine to make a .crate
file.
Closes #4954
bors [Thu, 18 Jan 2018 06:19:55 +0000 (06:19 +0000)]
Auto merge of #4951 - sfackler:log-bump, r=alexcrichton
Upgrade env_logger
0.4 depends on log 0.3 and so misses out on module names.
Steven Fackler [Tue, 16 Jan 2018 20:43:04 +0000 (12:43 -0800)]
Upgrade env_logger
0.4 depends on log 0.3 and so misses out on module names.
bors [Wed, 17 Jan 2018 16:22:07 +0000 (16:22 +0000)]
Auto merge of #4950 - alexcrichton:rustflags-orderd, r=matklad
Ensure `[target]` rustflags are deterministically passed
The usage of `HashMap` in the `Config` tables introduced some nondeterminism, so
reverse that with a sort right before we pass it down to rustc. One day we'll
probably want to sort by the position where these keys were defined, but for now
a blanket sort should do the trick.
Closes #4935
bors [Wed, 17 Jan 2018 15:39:58 +0000 (15:39 +0000)]
Auto merge of #4949 - alexcrichton:fix-patch-network, r=matklad
Fix `[patch]` sections depending on one another
This commit fixes a bug in `[patch]` where the original source is updated too
often (for example `Updating ...` being printed too much). This bug occurred
when patches depended on each other (for example the dependencies of a resolved
`[patch]` would actually resolve to a `[patch]` that hadn't been resolved yet).
The ordering of resolution/locking wasn't happening correctly and wasn't ready
to break these cycles!
The process of adding `[patch]` sections to a registry has been updated to
account for this bug. Instead of add-and-lock all in one go this commit instead
splits the addition of `[patch]` into two phases. In the first we collect a
bunch of unlocked patch summaries but record all the `PackageId` instances for
each url we've scraped. After all `[patch]` sections have been processed in this
manner we go back and lock all the summaries that were previously unlocked. The
`lock` function was updated to *only* need the map of patches from URL to
`PackageId` as it doesn't actually have access to the full `Summary` of patches
during the `lock_patches` method.
All in all this should correctly resolve dependencies here which means that
processing of patches should proceed as usual, avoiding updating the registry
too much!
Closes #4941
bors [Wed, 17 Jan 2018 15:04:54 +0000 (15:04 +0000)]
Auto merge of #4952 - rust-lang:matklad-patch-1, r=alexcrichton
Fix link in a doc comment
Aleksey Kladov [Wed, 17 Jan 2018 07:27:37 +0000 (10:27 +0300)]
Fix link in a doc comment
Alex Crichton [Tue, 16 Jan 2018 19:22:40 +0000 (11:22 -0800)]
Ensure `[target]` rustflags are deterministically passed
The usage of `HashMap` in the `Config` tables introduced some nondeterminism, so
reverse that with a sort right before we pass it down to rustc. One day we'll
probably want to sort by the position where these keys were defined, but for now
a blanket sort should do the trick.
Closes #4935
Alex Crichton [Tue, 16 Jan 2018 15:33:59 +0000 (07:33 -0800)]
Fix `[patch]` sections depending on one another
This commit fixes a bug in `[patch]` where the original source is updated too
often (for example `Updating ...` being printed too much). This bug occurred
when patches depended on each other (for example the dependencies of a resolved
`[patch]` would actually resolve to a `[patch]` that hadn't been resolved yet).
The ordering of resolution/locking wasn't happening correctly and wasn't ready
to break these cycles!
The process of adding `[patch]` sections to a registry has been updated to
account for this bug. Instead of add-and-lock all in one go this commit instead
splits the addition of `[patch]` into two phases. In the first we collect a
bunch of unlocked patch summaries but record all the `PackageId` instances for
each url we've scraped. After all `[patch]` sections have been processed in this
manner we go back and lock all the summaries that were previously unlocked. The
`lock` function was updated to *only* need the map of patches from URL to
`PackageId` as it doesn't actually have access to the full `Summary` of patches
during the `lock_patches` method.
All in all this should correctly resolve dependencies here which means that
processing of patches should proceed as usual, avoiding updating the registry
too much!
Closes #4941
bors [Tue, 16 Jan 2018 06:11:46 +0000 (06:11 +0000)]
Auto merge of #4944 - mathstuf:better-gitignore-template, r=alexcrichton
cargo_new: drop the trailing slash for target exclusion in Git
When `target` is a symlink (e.g., to keep build outputs on a separate
partition), Git will not match the `/target/` ignore to the symlink
since it is not a directory. Drop the trailing slash to support ignoring
`target` as a symlink.
bors [Tue, 16 Jan 2018 05:37:39 +0000 (05:37 +0000)]
Auto merge of #4945 - mathstuf:avoid-unused-import, r=alexcrichton
tests/git: avoid an unused import
bors [Tue, 16 Jan 2018 00:18:10 +0000 (00:18 +0000)]
Auto merge of #4946 - segevfiner:patch-1, r=Mark-Simulacrum
Remove a stray character from the Zsh completion script
That's not a command that people normally use, found it by accident...
Segev Finer [Mon, 15 Jan 2018 23:47:40 +0000 (01:47 +0200)]
Remove a stray character from the Zsh completion script
That's not a command that people normally use, found it by accident...
Ben Boeckel [Mon, 15 Jan 2018 22:06:38 +0000 (17:06 -0500)]
tests/git: avoid an unused import
Ben Boeckel [Mon, 15 Jan 2018 22:07:56 +0000 (17:07 -0500)]
cargo_new: drop the trailing slash for target exclusion in Git
When `target` is a symlink (e.g., to keep build outputs on a separate
partition), Git will not match the `/target/` ignore to the symlink
since it is not a directory. Drop the trailing slash to support ignoring
`target` as a symlink.
bors [Sat, 13 Jan 2018 23:59:50 +0000 (23:59 +0000)]
Auto merge of #4938 - ehuss:ws-meta, r=alexcrichton
Add workspace root to metadata command.
Fixes #4933
@alexcrichton, you mentioned using `"workspace_manifest"`, but the `Workspace.root` function already strips off `Cargo.toml`. It would be easy to append it back, though I'm uncertain if that's really necessary since I think for most use cases it will just need to be stripped off again. Also, I feel like it might be confusing for non-workspace packages since `workspace_manifest` would be the same as the package `manifest_path` (and in that case it isn't really a workspace manifest). I can easily change it, just let me know.
bors [Sat, 13 Jan 2018 23:31:57 +0000 (23:31 +0000)]
Auto merge of #4939 - ignatenkobrain:license, r=alexcrichton
crates-io: include LICENSE-*
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Igor Gnatenko [Sat, 13 Jan 2018 21:07:44 +0000 (22:07 +0100)]
crates-io: include LICENSE-*
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Eric Huss [Sat, 13 Jan 2018 19:51:36 +0000 (11:51 -0800)]
Add workspace root to metadata command.
Fixes #4933
bors [Thu, 11 Jan 2018 09:18:22 +0000 (09:18 +0000)]
Auto merge of #4931 - Manishearth:testname, r=matklad
Explicitly mention testname argument for cargo test/bench
The fact that `cargo test foo` works is totally non obvious. I suspect that 99% of the time
folks running `cargo help test` are looking for a way to only run a specific test, and
the current help message makes it seem like the way to do that is `cargo test --test foo`,
which is incorrect (it runs a specific test target).
This PR mentions it explicitly in the help message, first and foremost.
Manish Goregaokar [Thu, 11 Jan 2018 07:26:43 +0000 (12:56 +0530)]
Explicitly mention testname argument for cargo test/bench
bors [Tue, 9 Jan 2018 17:01:30 +0000 (17:01 +0000)]
Auto merge of #4926 - alexcrichton:fix-links, r=alexcrichton
Fix links in the guide
Add a link to a missing page so it's rendered
bors [Tue, 9 Jan 2018 15:39:47 +0000 (15:39 +0000)]
Auto merge of #4770 - chabapok:master, r=alexcrichton
Add an "-Z offline" flag to Cargo, altering it's dependency resolution behavior
This PR is implementation of the #4686 (without "Populating the global cache" feature)
Alex Crichton [Tue, 9 Jan 2018 15:11:52 +0000 (07:11 -0800)]
Fix links in the guide
Add a link to a missing page so it's rendered
bors [Tue, 9 Jan 2018 15:08:32 +0000 (15:08 +0000)]
Auto merge of #4924 - daschl:name-help, r=alexcrichton
Do not suggest --name as a fix if its already used.
This changeset partially fixes #4903 in that it doesn't suggest
using --name if its already being used (but the name is still
wrong).
Michael Nitschinger [Tue, 9 Jan 2018 13:50:45 +0000 (14:50 +0100)]
Do not suggest --name as a fix if its already used.
This changeset partially fixes #4903 in that it doesn't suggest
using --name if its already being used (but the name is still
wrong).
bors [Tue, 9 Jan 2018 03:27:46 +0000 (03:27 +0000)]
Auto merge of #4923 - wking:console-markup, r=alexcrichton
doc: Replace 'shell' language labels (generally with 'console')
#GitHub [uses Linguist][1] for syntax highlighting. Linguist's [`shell` language][2] is for the *language* (e.g. the contents of a `.sh` file). The proper language for a shell session is [`ShellSession`][3], although in this commit I've used the [alias `console`][4].
The Cargo book [uses mdBook][4.5], mdBook [uses Highlight.js][5], and Highlight.js [also supports `console` as an alias for shell sessions][6].
A handful of places where we had been using `shell` were just command output, not shell sessions (e.g. they lacked a prompt and command). In this commit, I've left those without a language label.
[1]: https://help.github.com/articles/creating-and-highlighting-code-blocks/#syntax-highlighting
[2]: https://github.com/github/linguist/blob/v5.3.3/lib/linguist/languages.yml#L4208
[3]: https://github.com/github/linguist/blob/v5.3.3/lib/linguist/languages.yml#L4249
[4]: https://github.com/github/linguist/blob/v5.3.3/lib/linguist/languages.yml#L4255
[4.5]: https://github.com/rust-lang/cargo/tree/
f60ece98c10aa3716d037524da4ee989e212fe19/src/doc#requirements
[5]: https://rust-lang-nursery.github.io/mdBook/format/theme/syntax-highlighting.html#syntax-highlighting
[6]: https://github.com/isagalaev/highlight.js/blob/9.12.0/src/languages/shell.js#L10
bors [Tue, 9 Jan 2018 02:27:48 +0000 (02:27 +0000)]
Auto merge of #4921 - wking:doc/guide-rust, r=alexcrichton
doc/guide/dependencies: Add a 'rust' language marker
This had been added to the non-book docs in
2ad45a56 (#4455), despite the fact that the book didn't actually have that marker:
$ git cat-file -p
2ad45a56:src/doc/book/src/guide/dependencies.md | grep -A2 'You can now use the'
You can now use the `regex` library using `extern crate` in `main.rs`.
```
This is (along with the already-landed #4916), part of recovering from #4904.
bors [Tue, 9 Jan 2018 01:26:46 +0000 (01:26 +0000)]
Auto merge of #4839 - sfackler:consistent-config, r=withoutboats
Make .cargo/credentials a subset of .cargo/config
Previously, .cargo/credentials looked like
```toml
token = "..."
[my-registry]
token = "..."
```
And was simply merged into the `registry` block of .cargo/config. This
meant that custom registry tokens were under
`registry.my-registry.token` rather than `registries.my-registry.token`
which is where the index was located, and that you couldn't have a
custom registry named `token` or it'd conflict with the token for the
default registry.
This commit changes things such that .cargo/credentials has the same
layout as .cargo/config, but only contains token values. For backwards
compatibility, we move `token` to `registry.token` when parsing.
bors [Mon, 8 Jan 2018 23:41:12 +0000 (23:41 +0000)]
Auto merge of #4798 - GuillaumeGomez:patch-1, r=alexcrichton
Fix issues
Fixes #4786.
Steven Fackler [Wed, 20 Dec 2017 03:37:14 +0000 (19:37 -0800)]
Make .cargo/credentials a subset of .cargo/config
Previously, .cargo/credentials looked like
```toml
token = "..."
[my-registry]
token = "..."
```
And was simply merged into the `registry` block of .cargo/config. This
meant that custom registry tokens were under
`registry.my-registry.token` rather than `registries.my-registry.token`
which is where the index was located, and that you couldn't have a
custom registry named `token` or it'd conflict with the token for the
default registry.
This commit changes things such that .cargo/credentials has the same
layout as .cargo/config, but only contains token values. For backwards
compatibility, we move `token` to `registry.token` when parsing.
W. Trevor King [Mon, 8 Jan 2018 22:42:48 +0000 (14:42 -0800)]
doc: Replace 'shell' language labels (generally with 'console')
GitHub uses Linguist for syntax highlighting [1]. Linguist's 'shell'
language is for the *language* [2] (e.g. the contents of a `.sh`
file). The proper language for a shell session is ShellSession [3],
although in this commit I've used the alias 'console' [4].
The Cargo book uses mdBook (src/doc/README.md), mdBook uses
Highlight.js [5], and Highlight.js also supports 'console' as an alias
for shell sessions [6].
A handful of places where we had been using 'shell' were just command
output, not shell sessions (e.g. they lacked a prompt and command).
In this commit, I've left those without a language label.
[1]: https://help.github.com/articles/creating-and-highlighting-code-blocks/#syntax-highlighting
[2]: https://github.com/github/linguist/blob/v5.3.3/lib/linguist/languages.yml#L4208
[3]: https://github.com/github/linguist/blob/v5.3.3/lib/linguist/languages.yml#L4249
[4]: https://github.com/github/linguist/blob/v5.3.3/lib/linguist/languages.yml#L4255
[5]: https://rust-lang-nursery.github.io/mdBook/format/theme/syntax-highlighting.html#syntax-highlighting
[6]: https://github.com/isagalaev/highlight.js/blob/9.12.0/src/languages/shell.js#L10
bors [Mon, 8 Jan 2018 22:31:25 +0000 (22:31 +0000)]
Auto merge of #4922 - wking:reference-wording-from-guide-trailer, r=alexcrichton
doc/reference/index: Remove "Now that you have an overview" paragraph
This wording was originally from
58a1804f (#2688), which added it to the end of the guide (where telling readers what they know makes some sense). It was moved to a "Cargo in Depth" section with
01aa9e3c (#4453), where it makes a bit less sense. When that section became the reference index in
3f2d93e3 (#4455) the context assumed by the paragraph was completely missing.
This commit removes the paragraph, which doesn't reduce the usefulness of the reference index. And the removal avoids confusing readers who start with the reference docs and may now have the assumed overview.
W. Trevor King [Mon, 8 Jan 2018 22:06:55 +0000 (14:06 -0800)]
doc/reference/index: Remove "Now that you have an overview" paragraph
This wording was originally from
58a1804f (At the end, point to docs
that might be interesting next, 2016-05-17, #2688), which added it to
the end of the guide (where telling readers what they know makes some
sense). It was moved to a "Cargo in Depth" section with
01aa9e3c
([src/doc/book] Move a paragraph to cargo-in-depth.md, 2017-08-31,
#4453), where it makes a bit less sense. When that section became the
reference index in
3f2d93e3 ([doc/book] Create dir for book sections,
2017-08-31, #4455) the context assumed by the paragraph was completely
missing.
This commit removes the paragraph, which doesn't reduce the usefulness
of the reference index. And the removal avoids confusing readers who
start with the reference docs and may now have the assumed overview.
W. Trevor King [Mon, 8 Jan 2018 21:56:54 +0000 (13:56 -0800)]
doc/guide/dependencies: Add a 'rust' language marker
This had been added to the non-book docs in
2ad45a56 ([doc] Sync back
doc/book changes into old docs, 2017-08-31, #4455), despite the fact
that the book didn't actually have that marker:
$ git cat-file -p
2ad45a56:src/doc/book/src/guide/dependencies.md | grep -A2 'You can now use the'
You can now use the `regex` library using `extern crate` in `main.rs`.
```
Pelepeichenko Alexander [Mon, 8 Jan 2018 18:22:12 +0000 (20:22 +0200)]
Updating based on code review
Guillaume Gomez [Sat, 9 Dec 2017 15:34:48 +0000 (16:34 +0100)]
Fix incoherence
Pelepeichenko Alexander [Sun, 24 Dec 2017 23:32:29 +0000 (01:32 +0200)]
add offline mode (-Z offline) with tests
bors [Mon, 8 Jan 2018 19:11:39 +0000 (19:11 +0000)]
Auto merge of #4920 - wking:license-expression, r=matklad
Cargo.toml: Replace '/' with 'OR' in 'license'
Catch up with our recommendations from
7dee65fe (#4898), which deprecated `/` in favor of vanilla SPDX license expressions.
I've gone with the disjunctive `OR`, because the README has:
> Cargo is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0).
W. Trevor King [Mon, 8 Jan 2018 18:39:13 +0000 (10:39 -0800)]
Cargo.toml: Replace '/' with 'OR' in 'license'
Catch up with our recommendations from
7dee65fe (src/doc/manifest: Pin
'license' to SPDX 2.1 expressions and the 2.4 list, 2018-01-04,
#4898), which deprecated '/' in favor of vanilla SPDX license
expressions.
I've gone with the disjunctive OR, because the README has:
> Cargo is primarily distributed under the terms of both the MIT
> license and the Apache License (Version 2.0).
bors [Mon, 8 Jan 2018 18:04:53 +0000 (18:04 +0000)]
Auto merge of #4919 - alexcrichton:faster-git-clone, r=matklad
Leverage local links on git checkouts
This commit updates the handling of git checkouts from the database to use
hardlinks if possible, speeding up this operation for large repositories
significantly.
As a refresher, Cargo caches git repositories in a few locations to speed up
local usage of git repositories. Cargo has a "database" folder which is a bare
checkout of any git repository Cargo has cached historically. This database
folder contains effectively a bunch of databases for remote repos that are
updated periodically.
When actually building a crate Cargo will clone this database into a different
location, the checkouts folder. Each rev we build (ever) is cached in the
checkouts folder. This means that once a checkout directory is created it's
frozen for all of time.
This latter step is what this commit is optimizing. When checking out the
database onto the local filesystem at a particular revision. Previously we were
instructing libgit2 to fall back to a "git aware" transport which was
exceedingly slow on some systems for filesystem-to-filesystem transfers. This
optimization (we just forgot to turn it on in libgit2) is a longstanding one and
should speed this up significantly!
Closes #4604
Alex Crichton [Mon, 8 Jan 2018 17:38:40 +0000 (09:38 -0800)]
Leverage local links on git checkouts
This commit updates the handling of git checkouts from the database to use
hardlinks if possible, speeding up this operation for large repositories
significantly.
As a refresher, Cargo caches git repositories in a few locations to speed up
local usage of git repositories. Cargo has a "database" folder which is a bare
checkout of any git repository Cargo has cached historically. This database
folder contains effectively a bunch of databases for remote repos that are
updated periodically.
When actually building a crate Cargo will clone this database into a different
location, the checkouts folder. Each rev we build (ever) is cached in the
checkouts folder. This means that once a checkout directory is created it's
frozen for all of time.
This latter step is what this commit is optimizing. When checking out the
database onto the local filesystem at a particular revision. Previously we were
instructing libgit2 to fall back to a "git aware" transport which was
exceedingly slow on some systems for filesystem-to-filesystem transfers. This
optimization (we just forgot to turn it on in libgit2) is a longstanding one and
should speed this up significantly!
Closes #4604
bors [Mon, 8 Jan 2018 16:37:05 +0000 (16:37 +0000)]
Auto merge of #4916 - tari:doc-recovery, r=alexcrichton
Recover doc changes lost in #4904
Fixes #4906.
bors [Mon, 8 Jan 2018 15:49:18 +0000 (15:49 +0000)]
Auto merge of #4914 - xftroxgpx:doc_profile_section_in_workspace_only, r=alexcrichton
doc: [profile.*] sections are for root crate only
ie.
warning: profiles for the non root package will be ignored, specify profiles at the workspace root
rendered:

bors [Mon, 8 Jan 2018 15:08:56 +0000 (15:08 +0000)]
Auto merge of #4915 - xftroxgpx:typo2, r=alexcrichton
doc: typo "worksapce" -> "workspace"
occurs twice
Peter Marheine [Mon, 8 Jan 2018 05:31:45 +0000 (16:31 +1100)]
Recover caveat about -vv and cleaning
First added in
72c924230c3df67261642f74ba415cb34086935f which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:29:07 +0000 (16:29 +1100)]
Recover non-virtual default-members doc
First changed in
f9a27fc1f7ef0e4360c878a0209370a86b310b5e which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:26:19 +0000 (16:26 +1100)]
Recover docs for workspace.default-members
First added in
82d563b71bf697f3d989cc1fdc2455c59679c309 which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:24:23 +0000 (16:24 +1100)]
Recover implied --all for virtual workspace docs
First changed in
1240f42c899fbba8bf85e493c3beb9f82227a09a which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:22:15 +0000 (16:22 +1100)]
Recover 'Add missing spaces around = sign'
First changed in
e8a1ba6f63a93430b1de6fc772e3f950d5bd63f2 which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:21:09 +0000 (16:21 +1100)]
Recover [patch] doc clarifications
First added in
1700346a9e9fe36b6e5b6858fc9a03d63f4fa37e which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:17:15 +0000 (16:17 +1100)]
Recover gcc -> cc in build docs
First changed in
209513d8991e05049c1e78c6cdf14c0865f2dd16 which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:14:54 +0000 (16:14 +1100)]
Recover spelling correction for 'otherwsie'
First fixed in
7b65667d5912e46ab2a39a7914a0ade869acc258 which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:13:34 +0000 (16:13 +1100)]
Recover discussion of -vv for build output
First added in
723945cb0eae7d642caa88812c6ecee3ed5895a1 which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:11:26 +0000 (16:11 +1100)]
Re-fix spelling of 'workspace'
First fixed in
4848c30414c6ed6b7afbe6067703ccfe0510d0ec which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:10:09 +0000 (16:10 +1100)]
Recover doc for appveyor project_name
First added in
53012bd4df83a0d43ce7dfd0175d78b084823477 which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 05:07:25 +0000 (16:07 +1100)]
Peter Marheine [Mon, 8 Jan 2018 05:02:46 +0000 (16:02 +1100)]
Peter Marheine [Mon, 8 Jan 2018 04:59:59 +0000 (15:59 +1100)]
Recover workspace member clarification from
8139a5d830d2c59b76abd9865ae7aeffdaaa107f
The original failed to update the book and was lost in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 04:57:56 +0000 (15:57 +1100)]
Recover doc for appveyor project ID
Cherry-picked from
f59eb30bbb9f1c30dcbfebe54aed72e1f51ba7cc which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 04:54:18 +0000 (15:54 +1100)]
Recover doc mention of sccache
Cherry-picked from
13bb7bd95b457f7383487cf8dcf476009939cfac which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 04:46:55 +0000 (15:46 +1100)]
Recover docs for git vendoring
Cherry-picked from
5b08b8fe1019147fe489db17a9a8ae7ebe97f9e9 which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
Peter Marheine [Mon, 8 Jan 2018 04:35:28 +0000 (15:35 +1100)]
Recover docs for incremental compilation
Cherry-picked from
45cc30bc7379ae13b079157b660de9d084de7a9e which failed
to update the book and was replaced in
1271bb4de0c0e0a085be239c2418af9c673ffc87.
xftroxgpx [Mon, 8 Jan 2018 03:03:16 +0000 (04:03 +0100)]
doc: typo "worksapce" -> "workspace"
occurs twice
xftroxgpx [Sun, 7 Jan 2018 22:48:52 +0000 (23:48 +0100)]
doc: [profile.*] sections are for root crate only
ie.
warning: profiles for the non root package will be ignored, specify profiles at the workspace root:
bors [Sat, 6 Jan 2018 18:10:30 +0000 (18:10 +0000)]
Auto merge of #4909 - zackmdavis:tidy_paren, r=matklad
unblock rust-lang/rust#46980 by cleaning up an unused pair of parentheses
While this might seem like too trivial of a stylistic nitpick to deserve
its own commit, this [is needed to unblock](https://github.com/rust-lang/rust/pull/46980#issuecomment-
355565906) the PR rust-lang/rust#46980 (which makes
the unused-parens lint look at function arguments, which it previously didn't).
Zack M. Davis [Sat, 6 Jan 2018 17:58:05 +0000 (09:58 -0800)]
clean up an unused pair of parentheses
While this might seem like too trivial of a stylistic nitpick to deserve
its own commit, this is needed to unblock rust-lang/rust#46980 (which makes
the unused-parens lint look at function arguments).
Guillaume Gomez [Sat, 9 Dec 2017 15:30:25 +0000 (16:30 +0100)]
Add precision on overriding a repository [patch]
bors [Fri, 5 Jan 2018 19:11:56 +0000 (19:11 +0000)]
Auto merge of #4904 - alexcrichton:clean-docs, r=alexcrichton
Delete the old docs, lift up the new
This commit deletes the old documentation now that the "official source" is the
main book. The book is now lifted up directly into `src/doc` instead of
`src/doc/book`.
The CI no longer builds documentation and has been updated to just run mdbook to
make sure there's no errors. The documentation will actually get published in
the rust-lang/rust repo
Alex Crichton [Fri, 5 Jan 2018 19:08:58 +0000 (11:08 -0800)]
Delete the old docs, lift up the new
This commit deletes the old documentation now that the "official source" is the
main book. The book is now lifted up directly into `src/doc` instead of
`src/doc/book`.
The CI no longer builds documentation and has been updated to just run mdbook to
make sure there's no errors. The documentation will actually get published in
the rust-lang/rust repo
bors [Thu, 4 Jan 2018 21:16:36 +0000 (21:16 +0000)]
Auto merge of #4898 - wking:license-pin-spdx, r=alexcrichton
src/doc/manifest: Pin 'license' to SPDX 2.1 expressions and the 2.4 list
Before this commit, the license-list URL was floating, which lead to issues when manifest authors used IDs from the list that had not yet made it into crate.io's whitelist (#4888). This commit pins both the SPDX-spec version (to avoid floating the license-expresion syntax) and the license-list version (to avoid floating the license/exception identifiers).
I've also deprecated the `/` syntax, since it was not clear whether that was conjunctive (like `AND`) or disjunctive (like `OR`). crates.io is [using license-exprs 1.3^][2], and [that version supports `WITH`, `AND`, `OR`, and the `+` suffix][3], so as far as crates.io-validation is concerned, the value can use vanilla license expressions.
It's unfortunate that there's not an easily-browsable version of the 2.4 license list up anywhere canonical (as far as I know). Starting with the 3.0 license list, there's [a Markdown page in the authoritative list-data repository][4]. I can also see about getting [earlier versions of the HTML][5] up on spdx.org somewhere.
I'm expecting the version-bump procedure will look something like:
1. SPDX cuts a new spec and/or license list release.
2. license-exprs updates to cover the change.
3. crates.io updates to depend on the new license-exprs version.
4. cargo updates the documentation to allow the new version.
5. authors read the new cargo docs and start using the new expression syntax and/or identifiers.
There's a window there where crates.io will be validating to a different version than the cargo docs recommend, so it would be good to have 4 follow 3 as closely as possible. But the SPDX maintainers have been good about providing long deprecation windows, so a bit of a gap is acceptable.
It's possible that crates.io will want to warn authors about their use of deprecated identifiers or syntax (e.g. the `/` I've deprecated here) so they can upgrade before the deprecated element is dropped (probably years after the initial deprecation). That would help limit the gap between 3 and 5 (although warnings sent before 4 might be confusing).
The parallel edits to the two manifest files are based on @carols10cents' recommendation. She [points out on IRC][6] that the goal is to drop the `src/doc/manifest.md` reference soon with the book up on `doc.rust-lang.org/cargo` today.
Fixes #4888, although it would be good to start the upgrade cycle to pull in the [newly-released SPDX license list 3.0][7] so folks can start using the new identifiers.
[2]: https://github.com/rust-lang/crates.io/pull/385
[3]: https://github.com/withoutboats/license-exprs/blob/
5bdb5355540792234e10011b9bbe4766cd08ff26/src/lib.rs#L53-L56
[4]: https://github.com/spdx/license-list-data/blob/v3.0/licenses.md
[5]: https://github.com/spdx/license-list-data/tree/v2.4/website
[6]: https://botbot.me/mozilla/cargo/2018-01-04/?msg=
95358280&page=2
[7]: https://lists.spdx.org/pipermail/spdx/2017-December/001159.html
W. Trevor King [Thu, 4 Jan 2018 19:29:10 +0000 (11:29 -0800)]
src/doc/manifest: Parenthesis not supported in 'license'
Document [1] where authors can find it.
[1]: https://github.com/withoutboats/license-exprs/issues/3
W. Trevor King [Thu, 4 Jan 2018 18:47:16 +0000 (10:47 -0800)]
src/doc/manifest: Pin 'license' to SPDX 2.1 expressions and the 2.4 list
Before this commit, the license-list URL was floating, which lead to
issues when manifest authors used IDs from the list that had not yet
made it into crate.io's whitelist [1]. This commit pins both the
SPDX-spec version (to avoid floating the license-expresion syntax) and
the license-list version (to avoid floating the license/exception
identifiers).
I've also deprecated the / syntax, since it was not clear whether that
was conjunctive (like AND) or disjunctive (like OR). crates.io is
using license-exprs 1.3^ [2], and that version supports WITH, AND, OR,
and the + suffix [3], so as far as crates.io-validation is concerned,
the value can use vanilla license expressions.
It's unfortunate that there's not an easily-browsable version of the
2.4 license list up anywhere canonical (as far as I know). Starting
with the 3.0 license list, there's a Markdown page in the
authoritative list-data repository [4]. I can also see about getting
earlier versions of the HTML (e.g. [5]) up on spdx.org somewhere.
I'm expecting the version-bump procedure will look something like:
1. SPDX cuts a new spec and/or license list release.
2. license-exprs updates to cover the change.
3. crates.io updates to depend on the new license-exprs version.
4. cargo updates the documentation to allow the new version.
5. authors read the new cargo docs and start using the new expression
syntax and/or identifiers.
There's a window there where crates.io will be validating to a
different version than the cargo docs recommend, so it would be good
to have 4 follow 3 as closely as possible. But the SPDX maintainers
have been good about providing long deprecation windows, so a bit of a
gap is acceptable.
It's possible that crates.io will want to warn authors about their use
of deprecated identifiers or syntax (e.g. the '/' I've deprecated
here) so they can upgrade before the deprecated element is dropped
(probably years after the initial deprecation). That would help limit
the gap between 3 and 5 (although warnings sent before 4 might be
confusing).
The parallel edits to the two manifest files are based on Carol
Nichols' recommendation. She points out on IRC that the goal is to
drop the src/doc/manifest.md reference soon with the book up on
doc.rust-lang.org/cargo today [6].
[1]: https://github.com/rust-lang/cargo/issues/4888
[2]: https://github.com/rust-lang/crates.io/pull/385
[3]: https://github.com/withoutboats/license-exprs/blob/
5bdb5355540792234e10011b9bbe4766cd08ff26/src/lib.rs#L53-L56
[4]: https://github.com/spdx/license-list-data/blob/v3.0/licenses.md
[5]: https://github.com/spdx/license-list-data/tree/v2.4/website
[6]: https://botbot.me/mozilla/cargo/2018-01-04/?msg=
95358280&page=2
bors [Thu, 4 Jan 2018 16:00:48 +0000 (16:00 +0000)]
Auto merge of #4896 - alexcrichton:bump, r=alexcrichton
Bump to 0.26.0
Alex Crichton [Thu, 4 Jan 2018 16:00:08 +0000 (08:00 -0800)]
Bump to 0.26.0
bors [Thu, 4 Jan 2018 01:52:41 +0000 (01:52 +0000)]
Auto merge of #4893 - xftroxgpx:smalltypo1, r=alexcrichton
doc typo: "does contains" -> "does contain"
xftroxgpx [Thu, 4 Jan 2018 01:30:24 +0000 (02:30 +0100)]
doc typo: "does contains" -> "does contain"
bors [Wed, 3 Jan 2018 22:38:53 +0000 (22:38 +0000)]
Auto merge of #4884 - tromey:help-to-stdout, r=alexcrichton
Send --help output to stdout
Fixes #4878
Tom Tromey [Mon, 1 Jan 2018 22:33:01 +0000 (15:33 -0700)]
Send --help output to stdout
Fixes #4878
bors [Wed, 3 Jan 2018 20:43:03 +0000 (20:43 +0000)]
Auto merge of #4891 - MaloJaffre:compiler-docs-regression, r=alexcrichton
Try to fix a perf regression by updating log
Upgrade `log` to `0.4` in `cargo` and `cargotest`.
Cc: rust-lang/rust#47154.
Malo Jaffré [Wed, 3 Jan 2018 20:16:16 +0000 (21:16 +0100)]
Try to fix a perf regression by updating log
Upgrade `log` to `0.4` in `cargo` and `cargotest`.
bors [Wed, 3 Jan 2018 19:47:09 +0000 (19:47 +0000)]
Auto merge of #4877 - steffengy:master, r=alexcrichton
migrate to winapi 0.3
Alex Crichton [Wed, 3 Jan 2018 19:25:28 +0000 (11:25 -0800)]
Touch up style of Windows imports
bors [Tue, 2 Jan 2018 20:27:56 +0000 (20:27 +0000)]
Auto merge of #4889 - Eijebong:bump, r=alexcrichton
Bump hex to 0.3
Bastien Orivel [Tue, 2 Jan 2018 19:35:32 +0000 (20:35 +0100)]
Bump hex to 0.3
bors [Tue, 2 Jan 2018 18:07:56 +0000 (18:07 +0000)]
Auto merge of #4885 - Eijebong:bump, r=alexcrichton
Bump dependencies
Those dependencies didn't need any code change
Bastien Orivel [Tue, 2 Jan 2018 11:08:44 +0000 (12:08 +0100)]
Bump dependencies
Those dependencies didn't need any code change
Steffen Butzer [Fri, 29 Dec 2017 22:32:39 +0000 (23:32 +0100)]
migrate to winapi 0.3
bors [Fri, 29 Dec 2017 22:13:32 +0000 (22:13 +0000)]
Auto merge of #4876 - MaloJaffre:flate2, r=alexcrichton
Upgrade flate2 crate to 1.0 in cargotest
I've missed this part in my previous PR, sorry.
Unblocks rust#46278.
Malo Jaffré [Fri, 29 Dec 2017 22:01:27 +0000 (23:01 +0100)]
Upgrade flate2 crate to 1.0 in cargotest
I've missed this part in my previous PR, sorry.
Unblocks rust#46278.
bors [Fri, 29 Dec 2017 16:18:31 +0000 (16:18 +0000)]
Auto merge of #4872 - MaloJaffre:flate-1.0, r=alexcrichton
Upgrade flate2 crate to 1.0
Unblocks rust-lang/rust#46278.
Malo Jaffré [Fri, 29 Dec 2017 14:37:22 +0000 (15:37 +0100)]
Upgrade flate2 crate to 1.0
Unblocks rust#46278.
bors [Fri, 29 Dec 2017 12:19:53 +0000 (12:19 +0000)]
Auto merge of #4871 - fschutt:master, r=matklad
Update cargo tests for https://github.com/rust-lang/rust/pull/47052
This test message currently breaks the build. The old error message was:
```
error: could not exec the linker `cc`: No such file or directory (os error 2)
|
= note: "cc" "-Wl,--as-needed" "-Wl,-z,noexecstack" "-m64" "-L" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "hello.hello0.rcgu.o" "hello.hello1.rcgu.o" "-o" "hello" "hello.crate.allocator.rcgu.o" "-Wl,--gc-sections" "-pie" "-Wl,-z,relro,-z,now" "-nodefaultlibs" "-L" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-Wl,-Bstatic" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-
d3700976135c3f09.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc_jemalloc-
8a207564cfc9f224.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libpanic_unwind-
4712d699ce2d50e5.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libunwind-
7224935811a361fe.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc_system-
3343c92f30e63266.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liblibc-
6e8aafa8bd1a67de.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc-
a8b7c0565b6366c3.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd_unicode-
512049fc390dec2e.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-
ba1f12eb6cef9a1a.rlib" "/home/felix/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcompiler_builtins-
53aab67ab6317c59.rlib" "-Wl,-Bdynamic" "-l" "dl" "-l" "rt" "-l" "pthread" "-l" "pthread" "-l" "gcc_s" "-l" "c" "-l" "m" "-l" "rt" "-l" "pthread" "-l" "util" "-l" "util"
error: aborting due to previous error
```
The new error message is:
```
error: linker `cc` not found
|
= note: No such file or directory (os error 2)
error: aborting due to previous error
```
This currently breaks https://github.com/rust-lang/rust/pull/47052.
**NOTE:** I don't know if I handled the "ticks" around the linker name correctly (if cargo test is smart enough to see that the ticks are part of the omitted part). My reasoning was that in the rustc code the ticks are in the source and not part of the linkers name - so if rustc changes, this will probably break again.
EDIT: fixed error message
Felix Schütt [Fri, 29 Dec 2017 10:46:07 +0000 (11:46 +0100)]
Update cargo tests for https://github.com/rust-lang/rust/pull/47052
bors [Sun, 24 Dec 2017 03:46:44 +0000 (03:46 +0000)]
Auto merge of #4859 - alexcrichton:better-test-fail, r=alexcrichton
Write invalid data when cloning to force an abort
Otherwise it seems libgit2 isn't ready to handle premature eof? Unclear...
Alex Crichton [Sun, 24 Dec 2017 03:45:37 +0000 (19:45 -0800)]
Write invalid data when cloning to force an abort
Otherwise it seems libgit2 isn't ready to handle premature eof? Unclear...
bors [Sat, 23 Dec 2017 15:43:50 +0000 (15:43 +0000)]
Auto merge of #4857 - alexcrichton:better-test-fail, r=alexcrichton
Make the `failed_submodule_checkout` test more robust
Hopefully should help diagnose deadlocks in rust-lang/rust
Alex Crichton [Sat, 23 Dec 2017 15:43:08 +0000 (07:43 -0800)]
Make the `failed_submodule_checkout` test more robust
Hopefully should help diagnose deadlocks in rust-lang/rust
bors [Fri, 22 Dec 2017 16:55:35 +0000 (16:55 +0000)]
Auto merge of #4852 - jtgeibel:cargo-install-target-dir, r=alexcrichton
Always respect `CARGO_TARGET_DIR` during `cargo install`
This aligns the behavior of crates.io and `--git` sources with that of `--path`
regarding the `CARGO_TARGET_DIR` and `CARGO_BUILD_TARGET_DIR` environment
variables. If neither environment variable is set, then a temporary directory
is still used when installing from crates.io or `--git`.
As discussed in #4725, this can be used to enable caching of artifacts between
continuous integration builds.
/cc @alexcrichton, @ishanjain28