]> git.proxmox.com Git - cargo.git/blame - CHANGELOG.md
Auto merge of #6892 - Goirad:doctest-xcompile, r=alexcrichton
[cargo.git] / CHANGELOG.md
CommitLineData
2cbb701b
EH
1# Changelog
2
5c7875d2
EH
3## Cargo 1.39 (2019-11-07)
4[e853aa97...HEAD](https://github.com/rust-lang/cargo/compare/e853aa97...HEAD)
5
6### Added
7
8### Changed
9- Display more information if parsing the output from `rustc` fails.
10 [#7236](https://github.com/rust-lang/cargo/pull/7236)
11- TOML errors now show the column number.
12 [#7248](https://github.com/rust-lang/cargo/pull/7248)
13- `cargo vendor` no longer deletes files in the `vendor` directory that starts
14 with a `.`.
15 [#7242](https://github.com/rust-lang/cargo/pull/7242)
16- `cargo fetch` will now show manifest warnings.
17 [#7243](https://github.com/rust-lang/cargo/pull/7243)
18- `cargo publish` will now check git submodules if they contain any
19 uncommitted changes.
20 [#7245](https://github.com/rust-lang/cargo/pull/7245)
21- In a build script, `cargo:rustc-flags` now allows `-l` and `-L` flags
22 without spaces.
23 [#7257](https://github.com/rust-lang/cargo/pull/7257)
24- When `cargo install` replaces an older version of a package it will now
25 delete any installed binaries that are no longer present in the newly
26 installed version.
27 [#7246](https://github.com/rust-lang/cargo/pull/7246)
28- A git dependency may now also specify a `version` key when published. The
29 `git` value will be stripped from the uploaded crate, matching the behavior
30 of `path` dependencies.
31 [#7237](https://github.com/rust-lang/cargo/pull/7237)
32
33### Fixed
34- Git dependencies with submodules with shorthand SSH URLs (like
35 `git@github.com/user/repo.git`) should now work.
36 [#7238](https://github.com/rust-lang/cargo/pull/7238)
37
1707d37f 38## Cargo 1.38 (2019-09-26)
5c7875d2 39[4c1fa54d...e853aa97](https://github.com/rust-lang/cargo/compare/4c1fa54d...e853aa97)
9e9c5868
EH
40
41### Added
42
5c7875d2 43- 🔥 Cargo build pipelining has been enabled by default to leverage more idle CPU
45699e9f
AC
44 parallelism during builds.
45 [#7143](https://github.com/rust-lang/cargo/pull/7143)
46- The `--message-format` option to Cargo can now be specified multiple times and
47 accepts a comma-separated list of values. In addition to the previous values
48 it also now accepts `json-diagnostic-short` and
49 `json-diagnostic-rendered-ansi` which configures the output coming from rustc
50 in `json` message mode.
51 [#7214](https://github.com/rust-lang/cargo/pull/7214)
5c7875d2
EH
52- Cirrus CI badges are now supported on crates.io.
53 [#7119](https://github.com/rust-lang/cargo/pull/7119)
54- (Nightly only): Added `cargo fix --clippy` which will apply
55 machine-applicable fixes from Clippy.
56 [#7069](https://github.com/rust-lang/cargo/pull/7069)
57- A new format for `Cargo.lock` has been introduced. This new format is
58 intended to avoid source-control merge conflicts more often, and to
59 generally make it safer to merge changes. This new format is *not* enabled
60 at this time, though Cargo will use it if it sees it. At some point in the
61 future, it is intended that this will become the default.
62 [#7070](https://github.com/rust-lang/cargo/pull/7070)
63- Progress bar support added for FreeBSD.
64 [#7222](https://github.com/rust-lang/cargo/pull/7222)
65- (Nightly only): Added `-Z binary-dep-depinfo` flag to add change tracking
66 for binary dependencies like the standard library.
67 [#7137](https://github.com/rust-lang/cargo/pull/7137)
68 [#7219](https://github.com/rust-lang/cargo/pull/7219)
45699e9f 69
9e9c5868 70### Changed
5c7875d2
EH
71- The `-q` flag will no longer suppress the root error message for an error
72 from Cargo itself.
73 [#7116](https://github.com/rust-lang/cargo/pull/7116)
74- The Cargo Book is now published with mdbook 0.3 providing a number of
75 formatting fixes and improvements.
76 [#7140](https://github.com/rust-lang/cargo/pull/7140)
77- The `--features` command-line flag can now be specified multiple times.
78 The list of features from all the flags are joined together.
79 [#7084](https://github.com/rust-lang/cargo/pull/7084)
80- (Nightly only): `cargo clippy-preview` will always run, even if no changes
81 have been made.
82 [#7157](https://github.com/rust-lang/cargo/pull/7157)
83- Package include/exclude glob-vs-gitignore warnings have been removed.
84 Packages may now use gitignore-style matching without producing any
85 warnings.
86 [#7170](https://github.com/rust-lang/cargo/pull/7170)
87- Cargo now shows the command and output when parsing `rustc` output fails
88 when querying `rustc` for information like `cfg` values.
89 [#7185](https://github.com/rust-lang/cargo/pull/7185)
90- `cargo package`/`cargo publish` now allows a symbolic link to a git
91 submodule to include that submodule.
92 [#6817](https://github.com/rust-lang/cargo/pull/6817)
93- Improved the error message when a version requirement does not
94 match any versions, but there are pre-release versions available.
95 [#7191](https://github.com/rust-lang/cargo/pull/7191)
9e9c5868
EH
96
97### Fixed
45699e9f 98- (Nightly only): Fixed exponential blowup when using `CARGO_BUILD_PIPELINING`.
9e9c5868
EH
99 [#7062](https://github.com/rust-lang/cargo/pull/7062)
100- Fixed using the wrong directory when updating git repositories when using
101 the `git-fetch-with-cli` config option, and the `GIT_DIR` environment
102 variable is set. This may happen when running cargo from git callbacks.
103 [#7082](https://github.com/rust-lang/cargo/pull/7082)
5c7875d2
EH
104- Fixed dep-info files being overwritten for targets that have separate debug
105 outputs. For example, binaries on `-apple-` targets with `.dSYM` directories
106 would overwrite the `.d` file.
107 [#7057](https://github.com/rust-lang/cargo/pull/7057)
108- Fix `[patch]` table not preserving "one major version per source" rule.
109 [#7118](https://github.com/rust-lang/cargo/pull/7118)
110- Ignore `--remap-path-prefix` flags for the metadata hash in the `cargo
111 rustc` command. This was causing the remap settings to inadvertently affect
112 symbol names.
113 [#7134](https://github.com/rust-lang/cargo/pull/7134)
114- Fixed cycle detection in `[patch]` dependencies.
115 [#7174](https://github.com/rust-lang/cargo/pull/7174)
116- Fixed `cargo new` leaving behind a symlink on Windows when `core.symlinks`
117 git config is true. Also adds a number of fixes and updates from upstream
118 libgit2.
119 [#7176](https://github.com/rust-lang/cargo/pull/7176)
120- macOS: Fixed setting the flag to mark the `target` directory to be excluded
121 from backups.
122 [#7192](https://github.com/rust-lang/cargo/pull/7192)
123- Fixed `cargo fix` panicking under some situations involving multi-byte
124 characters.
125 [#7221](https://github.com/rust-lang/cargo/pull/7221)
126- (Nightly only): Fixed passing args to clippy in `cargo clippy-preview`.
127 [#7162](https://github.com/rust-lang/cargo/pull/7162)
9e9c5868 128
114e20b3 129## Cargo 1.37 (2019-08-15)
9e9c5868 130[c4fcfb72...4c1fa54d](https://github.com/rust-lang/cargo/compare/c4fcfb72...4c1fa54d)
114e20b3
EH
131
132### Added
9e9c5868
EH
133- Added `doctest` field to `cargo metadata` to determine if a target's
134 documentation is tested.
114e20b3
EH
135 [#6953](https://github.com/rust-lang/cargo/pull/6953)
136 [#6965](https://github.com/rust-lang/cargo/pull/6965)
137- (Nightly only): Added [compiler message
138 caching](https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#cache-messages).
139 The `-Z cache-messages` flag makes cargo cache the compiler output so that
140 future runs can redisplay previous warnings.
141 [#6933](https://github.com/rust-lang/cargo/pull/6933)
9e9c5868
EH
142- 🔥 The [`cargo
143 vendor`](https://doc.rust-lang.org/nightly/cargo/commands/cargo-vendor.html)
144 command is now built-in to Cargo. This command may be used to create a local
145 copy of the sources of all dependencies.
146 [#6869](https://github.com/rust-lang/cargo/pull/6869)
147- 🔥 The "publish lockfile" feature is now stable. This feature will
148 automatically include the `Cargo.lock` file when a package is published if
149 it contains a binary executable target. By default, Cargo will ignore
150 `Cargo.lock` when installing a package. To force Cargo to use the
151 `Cargo.lock` file included in the published package, use `cargo install
152 --locked`. This may be useful to ensure that `cargo install` consistently
153 reproduces the same result. It may also be useful when a semver-incompatible
154 change is accidentally published to a dependency, providing a way to fall
155 back to a version that is known to work.
156 [#7026](https://github.com/rust-lang/cargo/pull/7026)
157- 🔥 The `default-run` feature has been stabilized. This feature allows you to
158 specify which binary executable to run by default with `cargo run` when a
159 package includes multiple binaries. Set the `default-run` key in the
160 `[package]` table in `Cargo.toml` to the name of the binary to use by
161 default.
162 [#7056](https://github.com/rust-lang/cargo/pull/7056)
114e20b3
EH
163
164### Changed
165- `cargo package` now verifies that build scripts do not create empty
166 directories.
167 [#6973](https://github.com/rust-lang/cargo/pull/6973)
9e9c5868
EH
168- A warning is now issued if `cargo doc` generates duplicate outputs, which
169 causes files to be randomly stomped on. This may happen for a variety of
170 reasons (renamed dependencies, multiple versions of the same package,
171 packages with renamed libraries, etc.). This is a known bug, which needs
172 more work to handle correctly.
173 [#6998](https://github.com/rust-lang/cargo/pull/6998)
174- Enabling a dependency's feature with `--features foo/bar` will no longer
175 compile the current crate with the `foo` feature if `foo` is not an optional
176 dependency.
177 [#7010](https://github.com/rust-lang/cargo/pull/7010)
178- If `--remap-path-prefix` is passed via RUSTFLAGS, it will no longer affect
179 the filename metadata hash.
180 [#6966](https://github.com/rust-lang/cargo/pull/6966)
181- libgit2 has been updated to 0.28.2, which Cargo uses to access git
182 repositories. This brings in hundreds of changes and fixes since it was last
183 updated in November.
184 [#7018](https://github.com/rust-lang/cargo/pull/7018)
185- Cargo now supports absolute paths in the dep-info files generated by rustc.
186 This is laying the groundwork for [tracking
187 binaries](https://github.com/rust-lang/rust/pull/61727), such as libstd, for
188 rebuild detection. (Note: this contains a known bug.)
189 [#7030](https://github.com/rust-lang/cargo/pull/7030)
190- (Nightly only): `-Z mtime-on-use` no longer touches intermediate artifacts.
191 [#7050](https://github.com/rust-lang/cargo/pull/7050)
114e20b3
EH
192
193### Fixed
194- Fixed how zsh completions fetch the list of commands.
195 [#6956](https://github.com/rust-lang/cargo/pull/6956)
196- "+ debuginfo" is no longer printed in the build summary when `debug` is set
197 to 0.
198 [#6971](https://github.com/rust-lang/cargo/pull/6971)
9e9c5868
EH
199- Fixed `cargo doc` with an example configured with `doc = true` to document
200 correctly.
201 [#7023](https://github.com/rust-lang/cargo/pull/7023)
5c7875d2
EH
202- Don't fail if a read-only lock cannot be acquired in CARGO_HOME. This helps
203 when CARGO_HOME doesn't exist, but `--locked` is used which means CARGO_HOME
204 is not needed.
205 [#7149](https://github.com/rust-lang/cargo/pull/7149)
206- Reverted a change in 1.35 which released jobserver tokens when Cargo blocked
207 on a lock file. It caused a deadlock in some situations.
208 [#7204](https://github.com/rust-lang/cargo/pull/7204)
114e20b3 209
2cbb701b 210## Cargo 1.36 (2019-07-04)
114e20b3 211[6f3e9c36...c4fcfb72](https://github.com/rust-lang/cargo/compare/6f3e9c36...c4fcfb72)
2cbb701b
EH
212
213### Added
214- (Nightly only): Added [`-Z install-upgrade`
114e20b3
EH
215 feature](https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#install-upgrade)
216 to track details about installed crates and to update them if they are
217 out-of-date. [#6798](https://github.com/rust-lang/cargo/pull/6798)
2cbb701b 218- (Nightly only): Added the [`public-dependency`
114e20b3 219 feature](https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#public-dependency)
2cbb701b
EH
220 which allows tracking public versus private dependencies.
221 [#6772](https://github.com/rust-lang/cargo/pull/6772)
114e20b3
EH
222- Added more detailed documentation on target auto-discovery.
223 [#6898](https://github.com/rust-lang/cargo/pull/6898)
224- (Nightly only): Added build pipelining via the `build.pipelining` config
225 option (`CARGO_BUILD_PIPELINING` env var).
226 [#6883](https://github.com/rust-lang/cargo/pull/6883)
227- 🔥 Stabilize the `--offline` flag which allows using cargo without a network
228 connection.
229 [#6934](https://github.com/rust-lang/cargo/pull/6934)
230 [#6871](https://github.com/rust-lang/cargo/pull/6871)
2cbb701b
EH
231
232### Changed
233- `publish = ["crates-io"]` may be added to the manifest to restrict
234 publishing to crates.io only.
235 [#6838](https://github.com/rust-lang/cargo/pull/6838)
236- macOS: Only include the default paths if `DYLD_FALLBACK_LIBRARY_PATH` is not
237 set. Also, remove `/lib` from the default set.
238 [#6856](https://github.com/rust-lang/cargo/pull/6856)
239- `cargo publish` will now exit early if the login token is not available.
240 [#6854](https://github.com/rust-lang/cargo/pull/6854)
241- HTTP/2 stream errors are now considered "spurious" and will cause a retry.
242 [#6861](https://github.com/rust-lang/cargo/pull/6861)
243- (Nightly only): The `publish-lockfile` feature has had some significant
244 changes. The default is now `true`, the `Cargo.lock` will always be
245 published for binary crates. The `Cargo.lock` is now regenerated during
246 publishing. `cargo install` now ignores the `Cargo.lock` file by default,
247 and requires `--locked` to use the lock file. Warnings have been added if
248 yanked dependencies are detected.
249 [#6840](https://github.com/rust-lang/cargo/pull/6840)
250- Setting a feature on a dependency where that feature points to a *required*
251 dependency is now an error. Previously it was a warning.
252 [#6860](https://github.com/rust-lang/cargo/pull/6860)
114e20b3
EH
253- The `registry.index` config value now supports relative `file:` URLs.
254 [#6873](https://github.com/rust-lang/cargo/pull/6873)
255- macOS: The `.dSYM` directory is now symbolically linked next to example
256 binaries without the metadata hash so that debuggers can find it.
257 [#6891](https://github.com/rust-lang/cargo/pull/6891)
258- The default `Cargo.toml` template for now projects now includes a comment
259 providing a link to the documentation.
260 [#6881](https://github.com/rust-lang/cargo/pull/6881)
261- Some improvements to the wording of the crate download summary.
262 [#6916](https://github.com/rust-lang/cargo/pull/6916)
263 [#6920](https://github.com/rust-lang/cargo/pull/6920)
264- ✨ Changed `RUST_LOG` environment variable to `CARGO_LOG` so that user code
265 that uses the `log` crate will not display cargo's debug output.
266 [#6918](https://github.com/rust-lang/cargo/pull/6918)
267- `Cargo.toml` is now always included when packaging, even if it is not listed
268 in `package.include`.
269 [#6925](https://github.com/rust-lang/cargo/pull/6925)
270- Package include/exclude values now use gitignore patterns instead of glob
271 patterns. [#6924](https://github.com/rust-lang/cargo/pull/6924)
272- Provide a better error message when crates.io times out. Also improve error
273 messages with other HTTP response codes.
274 [#6936](https://github.com/rust-lang/cargo/pull/6936)
275
276### Performance
2cbb701b
EH
277- Resolver performance improvements for some cases.
278 [#6853](https://github.com/rust-lang/cargo/pull/6853)
114e20b3
EH
279- Optimized how cargo reads the index JSON files by caching the results.
280 [#6880](https://github.com/rust-lang/cargo/pull/6880)
281 [#6912](https://github.com/rust-lang/cargo/pull/6912)
282 [#6940](https://github.com/rust-lang/cargo/pull/6940)
283- Various performance improvements.
284 [#6867](https://github.com/rust-lang/cargo/pull/6867)
2cbb701b
EH
285
286### Fixed
287- More carefully track the on-disk fingerprint information for dependencies.
288 This can help in some rare cases where the build is interrupted and
289 restarted. [#6832](https://github.com/rust-lang/cargo/pull/6832)
290- `cargo run` now correctly passes non-UTF8 arguments to the child process.
291 [#6849](https://github.com/rust-lang/cargo/pull/6849)
114e20b3
EH
292- Fixed bash completion to run on bash 3.2, the stock version in macOS.
293 [#6905](https://github.com/rust-lang/cargo/pull/6905)
294- Various fixes and improvements to zsh completion.
295 [#6926](https://github.com/rust-lang/cargo/pull/6926)
296 [#6929](https://github.com/rust-lang/cargo/pull/6929)
297- Fix `cargo update` ignoring `-p` arguments if the `Cargo.lock` file was
298 missing.
299 [#6904](https://github.com/rust-lang/cargo/pull/6904)
2cbb701b
EH
300
301## Cargo 1.35 (2019-05-23)
302[6789d8a0...6f3e9c36](https://github.com/rust-lang/cargo/compare/6789d8a0...6f3e9c36)
303
304### Added
305- Added the `rustc-cdylib-link-arg` key for build scripts to specify linker
306 arguments for cdylib crates.
307 [#6298](https://github.com/rust-lang/cargo/pull/6298)
dc935f5f 308- (Nightly only): `cargo clippy-preview` is now a built-in cargo command.
2cbb701b
EH
309 [#6759](https://github.com/rust-lang/cargo/pull/6759)
310
311### Changed
312- When passing a test filter, such as `cargo test foo`, don't build examples
313 (unless they set `test = true`).
314 [#6683](https://github.com/rust-lang/cargo/pull/6683)
315- Forward the `--quiet` flag from `cargo test` to the libtest harness so that
316 tests are actually quiet.
317 [#6358](https://github.com/rust-lang/cargo/pull/6358)
318- The verification step in `cargo package` that checks if any files are
319 modified is now stricter. It uses a hash of the contents instead of checking
320 filesystem mtimes. It also checks *all* files in the package.
321 [#6740](https://github.com/rust-lang/cargo/pull/6740)
322- Jobserver tokens are now released whenever Cargo blocks on a file lock.
323 [#6748](https://github.com/rust-lang/cargo/pull/6748)
324- Issue a warning for a previous bug in the TOML parser that allowed multiple
325 table headers with the same name.
326 [#6761](https://github.com/rust-lang/cargo/pull/6761)
327- Removed the `CARGO_PKG_*` environment variables from the metadata hash and
328 added them to the fingerprint instead. This means that when these values
329 change, stale artifacts are not left behind. Also added the "repository"
330 value to the fingerprint.
331 [#6785](https://github.com/rust-lang/cargo/pull/6785)
332- `cargo metadata` no longer shows a `null` field for a dependency without a
333 library in `resolve.nodes.deps`. The dependency is no longer shown.
334 [#6534](https://github.com/rust-lang/cargo/pull/6534)
335- `cargo new` will no longer include an email address in the `authors` field
336 if it is set to the empty string.
337 [#6802](https://github.com/rust-lang/cargo/pull/6802)
338- `cargo doc --open` now works when documenting multiple packages.
339 [#6803](https://github.com/rust-lang/cargo/pull/6803)
340- `cargo install --path P` now loads the `.cargo/config` file from the
341 directory P. [#6805](https://github.com/rust-lang/cargo/pull/6805)
342- Using semver metadata in a version requirement (such as `1.0.0+1234`) now
343 issues a warning that it is ignored.
344 [#6806](https://github.com/rust-lang/cargo/pull/6806)
345- `cargo install` now rejects certain combinations of flags where some flags
346 would have been ignored.
347 [#6801](https://github.com/rust-lang/cargo/pull/6801)
348- (Nightly only): The `build-override` profile setting now includes
349 proc-macros and their dependencies.
350 [#6811](https://github.com/rust-lang/cargo/pull/6811)
351- Resolver performance improvements for some cases.
352 [#6776](https://github.com/rust-lang/cargo/pull/6776)
353- (Nightly only): Optional and target dependencies now work better with `-Z
354 offline`. [#6814](https://github.com/rust-lang/cargo/pull/6814)
355
356### Fixed
357- Fixed running separate commands (such as `cargo build` then `cargo test`)
358 where the second command could use stale results from a build script.
359 [#6720](https://github.com/rust-lang/cargo/pull/6720)
360- Fixed `cargo fix` not working properly if a `.gitignore` file that matched
361 the root package directory.
362 [#6767](https://github.com/rust-lang/cargo/pull/6767)
363- Fixed accidentally compiling a lib multiple times if `panic=unwind` was set
364 in a profile. [#6781](https://github.com/rust-lang/cargo/pull/6781)
365- Paths to JSON files in `build.target` config value are now canonicalized to
366 fix building dependencies.
367 [#6778](https://github.com/rust-lang/cargo/pull/6778)
368- Fixed re-running a build script if its compilation was interrupted (such as
369 if it is killed). [#6782](https://github.com/rust-lang/cargo/pull/6782)
370- Fixed `cargo new` initializing a fossil repo.
371 [#6792](https://github.com/rust-lang/cargo/pull/6792)
372- Fixed supporting updating a git repo that has a force push when using the
373 `git-fetch-with-cli` feature. `git-fetch-with-cli` also shows more error
374 information now when it fails.
375 [#6800](https://github.com/rust-lang/cargo/pull/6800)
376- `--example` binaries built for the WASM target are fixed to no longer
377 include a metadata hash in the filename, and are correctly emitted in the
378 `compiler-artifact` JSON message.
379 [#6812](https://github.com/rust-lang/cargo/pull/6812)
380
381## Cargo 1.34 (2019-04-11)
382[f099fe94...6789d8a0](https://github.com/rust-lang/cargo/compare/f099fe94...6789d8a0)
383
384### Added
385- 🔥 Stabilized support for [alternate
386 registries](https://doc.rust-lang.org/1.34.0/cargo/reference/registries.html).
387 [#6654](https://github.com/rust-lang/cargo/pull/6654)
388- (Nightly only): Added `-Z mtime-on-use` flag to cause the mtime to be
389 updated on the filesystem when a crate is used. This is intended to be able
390 to track stale artifacts in the future for cleaning up unused files.
391 [#6477](https://github.com/rust-lang/cargo/pull/6477)
392 [#6573](https://github.com/rust-lang/cargo/pull/6573)
393- Added documentation on using builds.sr.ht Continuous Integration with Cargo.
394 [#6565](https://github.com/rust-lang/cargo/pull/6565)
395- `Cargo.lock` now includes a comment at the top that it is `@generated`.
396 [#6548](https://github.com/rust-lang/cargo/pull/6548)
397- Azure DevOps badges are now supported.
398 [#6264](https://github.com/rust-lang/cargo/pull/6264)
399- (Nightly only): Added experimental `-Z dual-proc-macros` to build proc
400 macros for both the host and the target.
401 [#6547](https://github.com/rust-lang/cargo/pull/6547)
402- Added a warning if `--exclude` flag specifies an unknown package.
403 [#6679](https://github.com/rust-lang/cargo/pull/6679)
404
405### Changed
406- `cargo test --doc --no-run` doesn't do anything, so it now displays an error
407 to that effect. [#6628](https://github.com/rust-lang/cargo/pull/6628)
408- Various updates to bash completion: add missing options and commands,
409 support libtest completions, use rustup for `--target` completion, fallback
410 to filename completion, fix editing the command line.
411 [#6644](https://github.com/rust-lang/cargo/pull/6644)
412- Publishing a crate with a `[patch]` section no longer generates an error.
413 The `[patch]` section is removed from the manifest before publishing.
414 [#6535](https://github.com/rust-lang/cargo/pull/6535)
415- `build.incremental = true` config value is now treated the same as
416 `CARGO_INCREMENTAL=1`, previously it was ignored.
417 [#6688](https://github.com/rust-lang/cargo/pull/6688)
418- Errors from a registry are now always displayed regardless of the HTTP
419 response code. [#6771](https://github.com/rust-lang/cargo/pull/6771)
420
421### Fixed
422- Fixed bash completion for `cargo run --example`.
423 [#6578](https://github.com/rust-lang/cargo/pull/6578)
424- Fixed a race condition when using a *local* registry and running multiple
425 cargo commands at the same time that build the same crate.
426 [#6591](https://github.com/rust-lang/cargo/pull/6591)
427- Fixed some flickering and excessive updates of the progress bar.
428 [#6615](https://github.com/rust-lang/cargo/pull/6615)
429- Fixed a hang when using a git credential helper that returns incorrect
430 credentials. [#6681](https://github.com/rust-lang/cargo/pull/6681)
431- Fixed resolving yanked crates with a local registry.
432 [#6750](https://github.com/rust-lang/cargo/pull/6750)
433
434## Cargo 1.33 (2019-02-28)
435[8610973a...f099fe94](https://github.com/rust-lang/cargo/compare/8610973a...f099fe94)
436
437### Added
438- `compiler-artifact` JSON messages now include an `"executable"` key which
439 includes the path to the executable that was built.
440 [#6363](https://github.com/rust-lang/cargo/pull/6363)
441- The man pages have been rewritten, and are now published with the web
442 documentation. [#6405](https://github.com/rust-lang/cargo/pull/6405)
443- (Nightly only): Allow using registry *names* in `[patch]` tables instead of
444 just URLs. [#6456](https://github.com/rust-lang/cargo/pull/6456)
445- `cargo login` now displays a confirmation after saving the token.
446 [#6466](https://github.com/rust-lang/cargo/pull/6466)
447- A warning is now emitted if a `[patch]` entry does not match any package.
448 [#6470](https://github.com/rust-lang/cargo/pull/6470)
449- `cargo metadata` now includes the `links` key for a package.
450 [#6480](https://github.com/rust-lang/cargo/pull/6480)
451- (Nightly only): `cargo metadata` added the `registry` key for dependencies.
452 [#6500](https://github.com/rust-lang/cargo/pull/6500)
453- "Very verbose" output with `-vv` now displays the environment variables that
454 cargo sets when it runs a process.
455 [#6492](https://github.com/rust-lang/cargo/pull/6492)
456- `--example`, `--bin`, `--bench`, or `--test` without an argument now lists
457 the available targets for those options.
458 [#6505](https://github.com/rust-lang/cargo/pull/6505)
459- Windows: If a process fails with an extended status exit code, a
460 human-readable name for the code is now displayed.
461 [#6532](https://github.com/rust-lang/cargo/pull/6532)
462- Added `--features`, `--no-default-features`, and `--all-features` flags to
463 the `cargo package` and `cargo publish` commands to use the given features
464 when verifying the package.
465 [#6453](https://github.com/rust-lang/cargo/pull/6453)
466
467### Changed
468- If `cargo fix` fails to compile the fixed code, the rustc errors are now
469 displayed on the console.
470 [#6419](https://github.com/rust-lang/cargo/pull/6419)
471- (Nightly only): Registry names are now restricted to the same style as
472 package names (alphanumeric, `-` and `_` characters).
473 [#6469](https://github.com/rust-lang/cargo/pull/6469)
474- (Nightly only): `cargo login` now displays the `/me` URL from the registry
475 config. [#6466](https://github.com/rust-lang/cargo/pull/6466)
476- Hide the `--host` flag from `cargo login`, it is unused.
477 [#6466](https://github.com/rust-lang/cargo/pull/6466)
478- (Nightly only): `cargo login --registry=NAME` now supports interactive input
479 for the token. [#6466](https://github.com/rust-lang/cargo/pull/6466)
480- (Nightly only): Registries may now elide the `api` key from `config.json` to
481 indicate they do not support API access.
482 [#6466](https://github.com/rust-lang/cargo/pull/6466)
483- Build script fingerprints now include the rustc version.
484 [#6473](https://github.com/rust-lang/cargo/pull/6473)
485- macOS: Switched to setting `DYLD_FALLBACK_LIBRARY_PATH` instead of
486 `DYLD_LIBRARY_PATH`. [#6355](https://github.com/rust-lang/cargo/pull/6355)
487- `RUSTFLAGS` is now included in the metadata hash, meaning that changing
488 the flags will not overwrite previously built files.
489 [#6503](https://github.com/rust-lang/cargo/pull/6503)
490- When updating the crate graph, unrelated yanked crates were erroneously
491 removed. They are now kept at their original version if possible. This was
492 causing unrelated packages to be downgraded during `cargo update -p
493 somecrate`. [#5702](https://github.com/rust-lang/cargo/issues/5702)
494- TOML files now support the [0.5 TOML
495 syntax](https://github.com/toml-lang/toml/blob/master/CHANGELOG.md#050--2018-07-11).
496
497### Fixed
498- `cargo fix` will now ignore suggestions that modify multiple files.
499 [#6402](https://github.com/rust-lang/cargo/pull/6402)
500- `cargo fix` will now only fix one target at a time, to deal with targets
501 which share the same source files.
502 [#6434](https://github.com/rust-lang/cargo/pull/6434)
503- (Nightly only): Fixed panic when using `--message-format=json` with metabuild.
504 [#6432](https://github.com/rust-lang/cargo/pull/6432)
505- Fixed bash completion showing the list of cargo commands.
506 [#6461](https://github.com/rust-lang/cargo/issues/6461)
507- `cargo init` will now avoid creating duplicate entries in `.gitignore`
508 files. [#6521](https://github.com/rust-lang/cargo/pull/6521)
509- (Nightly only): Fixed detection of publishing to crates.io when using
510 alternate registries. [#6525](https://github.com/rust-lang/cargo/pull/6525)
511- Builds now attempt to detect if a file is modified in the middle of a
512 compilation, allowing you to build again and pick up the new changes. This
513 is done by keeping track of when the compilation *starts* not when it
514 finishes. Also, [#5919](https://github.com/rust-lang/cargo/pull/5919) was
515 reverted, meaning that cargo does *not* treat equal filesystem mtimes as
516 requiring a rebuild. [#6484](https://github.com/rust-lang/cargo/pull/6484)
517
518## Cargo 1.32 (2019-01-17)
519[339d9f9c...8610973a](https://github.com/rust-lang/cargo/compare/339d9f9c...8610973a)
520
521### Added
522- (Nightly only): Allow usernames in registry URLs.
523 [#6242](https://github.com/rust-lang/cargo/pull/6242)
524- Registries may now display warnings after a successful publish.
525 [#6303](https://github.com/rust-lang/cargo/pull/6303)
526- Added a [glossary](https://doc.rust-lang.org/cargo/appendix/glossary.html)
527 to the documentation. [#6321](https://github.com/rust-lang/cargo/pull/6321)
528- Added the alias `c` for `cargo check`.
529 [#6218](https://github.com/rust-lang/cargo/pull/6218)
530- (Nightly only): Added `"compile_mode"` key to the build-plan JSON structure
531 to be able to distinguish running a custom build script versus compiling the
532 build script. [#6331](https://github.com/rust-lang/cargo/pull/6331)
533
534### Changed
535- 🔥 HTTP/2 multiplexing is now enabled by default. The `http.multiplexing`
536 config value may be used to disable it.
537 [#6271](https://github.com/rust-lang/cargo/pull/6271)
538- Use ANSI escape sequences to clear lines instead of spaces.
539 [#6233](https://github.com/rust-lang/cargo/pull/6233)
540- Disable git templates when checking out git dependencies, which can cause
541 problems. [#6252](https://github.com/rust-lang/cargo/pull/6252)
542- Include the `--update-head-ok` git flag when using the
543 `net.git-fetch-with-cli` option. This can help prevent failures when
544 fetching some repositories.
545 [#6250](https://github.com/rust-lang/cargo/pull/6250)
546- When extracting a crate during the verification step of `cargo package`, the
547 filesystem mtimes are no longer set, which was failing on some rare
548 filesystems. [#6257](https://github.com/rust-lang/cargo/pull/6257)
549- `crate-type = ["proc-macro"]` is now treated the same as `proc-macro = true`
550 in `Cargo.toml`. [#6256](https://github.com/rust-lang/cargo/pull/6256)
551- An error is raised if `dependencies`, `features`, `target`, or `badges` is
552 set in a virtual workspace. Warnings are displayed if `replace` or `patch`
553 is used in a workspace member.
554 [#6276](https://github.com/rust-lang/cargo/pull/6276)
555- Improved performance of the resolver in some cases.
556 [#6283](https://github.com/rust-lang/cargo/pull/6283)
557 [#6366](https://github.com/rust-lang/cargo/pull/6366)
558- `.rmeta` files are no longer hard-linked into the base target directory
559 (`target/debug`). [#6292](https://github.com/rust-lang/cargo/pull/6292)
560- A warning is issued if multiple targets are built with the same output
561 filenames. [#6308](https://github.com/rust-lang/cargo/pull/6308)
562- When using `cargo build` (without `--release`) benchmarks are now built
563 using the "test" profile instead of "bench". This makes it easier to debug
564 benchmarks, and avoids confusing behavior.
565 [#6309](https://github.com/rust-lang/cargo/pull/6309)
566- User aliases may now override built-in aliases (`b`, `r`, `t`, and `c`).
567 [#6259](https://github.com/rust-lang/cargo/pull/6259)
568- Setting `autobins=false` now disables auto-discovery of inferred targets.
569 [#6329](https://github.com/rust-lang/cargo/pull/6329)
570- `cargo verify-project` will now fail on stable if the project uses unstable
571 features. [#6326](https://github.com/rust-lang/cargo/pull/6326)
572- Platform targets with an internal `.` within the name are now allowed.
573 [#6255](https://github.com/rust-lang/cargo/pull/6255)
574- `cargo clean --release` now only deletes the release directory.
575 [#6349](https://github.com/rust-lang/cargo/pull/6349)
576
577### Fixed
578- Avoid adding extra angle brackets in email address for `cargo new`.
579 [#6243](https://github.com/rust-lang/cargo/pull/6243)
580- The progress bar is disabled if the CI environment variable is set.
581 [#6281](https://github.com/rust-lang/cargo/pull/6281)
582- Avoid retaining all rustc output in memory.
583 [#6289](https://github.com/rust-lang/cargo/pull/6289)
584- If JSON parsing fails, and rustc exits nonzero, don't lose the parse failure
585 message. [#6290](https://github.com/rust-lang/cargo/pull/6290)
586- (Nightly only): `--out-dir` no longer copies over build scripts.
587 [#6300](https://github.com/rust-lang/cargo/pull/6300)
588- Fixed renaming a project directory with build scripts.
589 [#6328](https://github.com/rust-lang/cargo/pull/6328)
590- Fixed `cargo run --example NAME` to work correctly if the example sets
591 `crate_type = ["bin"]`.
592 [#6330](https://github.com/rust-lang/cargo/pull/6330)
593- Fixed issue with `cargo package` git discovery being too aggressive. The
594 `--allow-dirty` now completely disables the git repo checks.
595 [#6280](https://github.com/rust-lang/cargo/pull/6280)
596- Fixed build change tracking for `[patch]` deps which resulted in `cargo
597 build` rebuilding when it shouldn't.
598 [#6493](https://github.com/rust-lang/cargo/pull/6493)
599
30125600 600## Cargo 1.31 (2018-12-06)
2cbb701b
EH
601[36d96825...339d9f9c](https://github.com/rust-lang/cargo/compare/36d96825...339d9f9c)
602
603### Added
604- 🔥 Stabilized support for the 2018 edition.
605 [#5984](https://github.com/rust-lang/cargo/pull/5984)
606 [#5989](https://github.com/rust-lang/cargo/pull/5989)
607- 🔥 Added the ability to [rename
608 dependencies](https://doc.rust-lang.org/1.31.0/cargo/reference/specifying-dependencies.html#renaming-dependencies-in-cargotoml)
609 in Cargo.toml. [#6319](https://github.com/rust-lang/cargo/pull/6319)
610- 🔥 Added support for HTTP/2 pipelining and multiplexing. Set the
611 `http.multiplexing` config value to enable.
612 [#6005](https://github.com/rust-lang/cargo/pull/6005)
613- (Nightly only): Added `--registry` flag to `cargo install`.
614 [#6128](https://github.com/rust-lang/cargo/pull/6128)
615- (Nightly only): Added `registry.default` configuration value to specify the
616 default registry to use if `--registry` flag is not passed.
617 [#6135](https://github.com/rust-lang/cargo/pull/6135)
618- (Nightly only): Added `--registry` flag to `cargo new` and `cargo init`.
619 [#6135](https://github.com/rust-lang/cargo/pull/6135)
620- Added `http.debug` configuration value to debug HTTP connections. Use
621 `CARGO_HTTP_DEBUG=true RUST_LOG=cargo::ops::registry cargo build` to display
622 the debug information. [#6166](https://github.com/rust-lang/cargo/pull/6166)
623- `CARGO_PKG_REPOSITORY` environment variable is set with the repository value
624 from `Cargo.toml` when building .
625 [#6096](https://github.com/rust-lang/cargo/pull/6096)
626
627### Changed
628- `cargo test --doc` now rejects other flags instead of ignoring them.
629 [#6037](https://github.com/rust-lang/cargo/pull/6037)
630- `cargo install` ignores `~/.cargo/config`.
631 [#6026](https://github.com/rust-lang/cargo/pull/6026)
632- `cargo version --verbose` is now the same as `cargo -vV`.
633 [#6076](https://github.com/rust-lang/cargo/pull/6076)
634- Comments at the top of `Cargo.lock` are now preserved.
635 [#6181](https://github.com/rust-lang/cargo/pull/6181)
636- When building in "very verbose" mode (`cargo build -vv`), build script
637 output is prefixed with the package name and version, such as `[foo 0.0.1]`.
638 [#6164](https://github.com/rust-lang/cargo/pull/6164)
639- If `cargo fix --broken-code` fails to compile after fixes have been applied,
640 the files are no longer reverted and are left in their broken state.
641 [#6316](https://github.com/rust-lang/cargo/pull/6316)
642
643### Fixed
644- Windows: Pass Ctrl-C to the process with `cargo run`.
645 [#6004](https://github.com/rust-lang/cargo/pull/6004)
646- macOS: Fix bash completion.
647 [#6038](https://github.com/rust-lang/cargo/pull/6038)
648- Support arbitrary toolchain names when completing `+toolchain` in bash
649 completion. [#6038](https://github.com/rust-lang/cargo/pull/6038)
650- Fixed edge cases in the resolver, when backtracking on failed dependencies.
651 [#5988](https://github.com/rust-lang/cargo/pull/5988)
652- Fixed `cargo test --all-targets` running lib tests three times.
653 [#6039](https://github.com/rust-lang/cargo/pull/6039)
654- Fixed publishing renamed dependencies to crates.io.
655 [#5993](https://github.com/rust-lang/cargo/pull/5993)
656- Fixed `cargo install` on a git repo with multiple binaries.
657 [#6060](https://github.com/rust-lang/cargo/pull/6060)
658- Fixed deeply nested JSON emitted by rustc being lost.
659 [#6081](https://github.com/rust-lang/cargo/pull/6081)
660- Windows: Fix locking msys terminals to 60 characters.
661 [#6122](https://github.com/rust-lang/cargo/pull/6122)
662- Fixed renamed dependencies with dashes.
663 [#6140](https://github.com/rust-lang/cargo/pull/6140)
664- Fixed linking against the wrong dylib when the dylib existed in both
665 `target/debug` and `target/debug/deps`.
666 [#6167](https://github.com/rust-lang/cargo/pull/6167)
667- Fixed some unnecessary recompiles when `panic=abort` is used.
668 [#6170](https://github.com/rust-lang/cargo/pull/6170)
669
30125600 670## Cargo 1.30 (2018-10-25)
2cbb701b
EH
671[524a578d...36d96825](https://github.com/rust-lang/cargo/compare/524a578d...36d96825)
672
673### Added
674- 🔥 Added an animated progress bar shows progress during building.
675 [#5995](https://github.com/rust-lang/cargo/pull/5995/)
676- Added `resolve.nodes.deps` key to `cargo metadata`, which includes more
677 information about resolved dependencies, and properly handles renamed
678 dependencies. [#5871](https://github.com/rust-lang/cargo/pull/5871)
679- When creating a package, provide more detail with `-v` when failing to
680 discover if files are dirty in a git repository. Also fix a problem with
681 discovery on Windows. [#5858](https://github.com/rust-lang/cargo/pull/5858)
682- Filters like `--bin`, `--test`, `--example`, `--bench`, or `--lib` can be
683 used in a workspace without selecting a specific package.
684 [#5873](https://github.com/rust-lang/cargo/pull/5873)
685- `cargo run` can be used in a workspace without selecting a specific package.
686 [#5877](https://github.com/rust-lang/cargo/pull/5877)
687- `cargo doc --message-format=json` now outputs JSON messages from rustdoc.
688 [#5878](https://github.com/rust-lang/cargo/pull/5878)
689- Added `--message-format=short` to show one-line messages.
690 [#5879](https://github.com/rust-lang/cargo/pull/5879)
691- Added `.cargo_vcs_info.json` file to `.crate` packages that captures the
692 current git hash. [#5886](https://github.com/rust-lang/cargo/pull/5886)
693- Added `net.git-fetch-with-cli` configuration option to use the `git`
694 executable to fetch repositories instead of using the built-in libgit2
695 library. [#5914](https://github.com/rust-lang/cargo/pull/5914)
696- Added `required-features` to `cargo metadata`.
697 [#5902](https://github.com/rust-lang/cargo/pull/5902)
698- `cargo uninstall` within a package will now uninstall that package.
699 [#5927](https://github.com/rust-lang/cargo/pull/5927)
700- (Nightly only): Added
701 [metabuild](https://doc.rust-lang.org/1.30.0/cargo/reference/unstable.html#metabuild).
702 [#5628](https://github.com/rust-lang/cargo/pull/5628)
703- Added `--allow-staged` flag to `cargo fix` to allow it to run if files are
704 staged in git. [#5943](https://github.com/rust-lang/cargo/pull/5943)
705- Added `net.low-speed-limit` config value, and also honor `net.timeout` for
706 http operations. [#5957](https://github.com/rust-lang/cargo/pull/5957)
707- Added `--edition` flag to `cargo new`.
708 [#5984](https://github.com/rust-lang/cargo/pull/5984)
709- Temporarily stabilized 2018 edition support for the duration of the beta.
710 [#5984](https://github.com/rust-lang/cargo/pull/5984)
711 [#5989](https://github.com/rust-lang/cargo/pull/5989)
712- Added support for `target.'cfg(…)'.runner` config value to specify the
713 run/test/bench runner for config-expressioned targets.
714 [#5959](https://github.com/rust-lang/cargo/pull/5959)
715
716### Changed
717- Windows: `cargo run` will not kill child processes when the main process
718 exits. [#5887](https://github.com/rust-lang/cargo/pull/5887)
719- Switched to the `opener` crate to open a web browser with `cargo doc
720 --open`. This should more reliably select the system-preferred browser on
721 all platforms. [#5888](https://github.com/rust-lang/cargo/pull/5888)
722- Equal file mtimes now cause a target to be rebuilt. Previously only if files
723 were strictly *newer* than the last build would it cause a rebuild.
724 [#5919](https://github.com/rust-lang/cargo/pull/5919)
725- Ignore `build.target` config value when running `cargo install`.
726 [#5874](https://github.com/rust-lang/cargo/pull/5874)
727- Ignore `RUSTC_WRAPPER` for `cargo fix`.
728 [#5983](https://github.com/rust-lang/cargo/pull/5983)
729- Ignore empty `RUSTC_WRAPPER`.
730 [#5985](https://github.com/rust-lang/cargo/pull/5985)
731
732### Fixed
733- Fixed error when creating a package with an edition field in `Cargo.toml`.
734 [#5908](https://github.com/rust-lang/cargo/pull/5908)
735- More consistently use relative paths for path dependencies in a workspace.
736 [#5935](https://github.com/rust-lang/cargo/pull/5935)
737- `cargo fix` now always runs, even if it was run previously.
738 [#5944](https://github.com/rust-lang/cargo/pull/5944)
739- Windows: Attempt to more reliably detect terminal width. msys-based
740 terminals are forced to 60 characters wide.
741 [#6010](https://github.com/rust-lang/cargo/pull/6010)
742- Allow multiple target flags with `cargo doc --document-private-items`.
743 [6022](https://github.com/rust-lang/cargo/pull/6022)