summaryrefslogtreecommitdiff
path: root/maint/downgrade_dependencies
blob: 272786d2ab7e02833a1241991077518665edc810 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/usr/bin/env bash
#
# Downgrades every one of our dependencies in Cargo.lock to the
# earliest version listed in our Cargo.toml files.  (And then
# re-upgrades a few second-order dependencies that aren't actually
# supported by our first-order dependencies in their oldest versions.)
#
# The purpose of this script is to make sure that we are actually
# compatible with the versions listed in our Cargo.toml files.
# Without testing this, we could wind up with code that built
# successfully with the versions listed in Cargo.lock, while declaring
# support for versions of our dependencies that won't actually work.

set -euo pipefail

: "${CARGO:=cargo}"

$CARGO +nightly update -Z minimal-versions
$CARGO update \
      -p log:0.4.17 \
      -p crc32fast \
      -p zeroize_derive:1.3.2 \
      -p filetime \
      -p tap:1.0.0 \
      -p event-listener:3.0.0 \
      -p paste:1.0.0 \
      -p ring:0.16.15 \
      -p yoke:0.6.0