Skip to content

Commit 8b56c60

Browse files
committed
Merge remote-tracking branch 'upstream/master' into allow-multiple-keywords-in-search
2 parents e65635e + 7119b08 commit 8b56c60

File tree

105 files changed

+2389
-1682
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

105 files changed

+2389
-1682
lines changed

.buildpacks

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
https://github.com/Starkast/heroku-buildpack-cmake#a243c67
21
https://github.com/emk/heroku-buildpack-rust#578d630
32
https://codon-buildpacks.s3.amazonaws.com/buildpacks/heroku/emberjs.tgz
43
https://github.com/heroku/heroku-buildpack-nginx.git#fbc49cd

.travis.yml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
language: rust
22
sudo: required
3-
dist: trusty
3+
dist: xenial
44

55
# Ignore this branch per bors-ng documentation
66
branches:
@@ -24,8 +24,11 @@ env:
2424
# on community-submitted PRs
2525
- PERCY_TOKEN=0d8707a02b19aebbec79bb0bf302b8d2fa95edb33169cfe41b084289596670b1
2626
- PERCY_PROJECT=crates-io/crates.io
27+
- PGPORT=5433
2728

2829
install:
30+
- sudo cp /etc/postgresql/10/main/pg_hba.conf /etc/postgresql/11/main/pg_hba.conf
31+
- sudo systemctl restart postgresql@11-main
2932
- script/ci/cargo-clean-on-new-rustc-version.sh
3033
- cargo install --force diesel_cli --vers `cat .diesel_version` --no-default-features --features postgres && export PATH=$HOME/.cargo/bin:$PATH
3134

@@ -34,15 +37,11 @@ before_script:
3437

3538
addons:
3639
chrome: stable
37-
postgresql: "9.5"
40+
postgresql: "11"
3841
apt:
39-
sources:
40-
- kalakris-cmake
4142
packages:
42-
- cmake
43-
- libcurl4-openssl-dev
44-
- libelf-dev
45-
- libdw-dev
43+
- postgresql-11
44+
- postgresql-client-11
4645

4746
matrix:
4847
fast_finish: true

Cargo.lock

Lines changed: 825 additions & 669 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,12 @@ rustdoc-args = [
2929

3030
[dependencies]
3131
cargo-registry-s3 = { path = "src/s3", version = "0.2.0" }
32-
old_semver = { path = "src/old_semver", version = "0.1.0" }
33-
rand = "0.3"
34-
git2 = "0.6.4"
32+
rand = "0.6"
33+
git2 = "0.8.0"
3534
flate2 = "1.0"
3635
semver = { version = "0.9", git = "https://github.com/steveklabnik/semver.git", features = ["diesel", "serde"] }
3736
url = "1.2.1"
38-
tar = "0.4.13"
37+
tar = "0.4.16"
3938
base64 = "0.9"
4039

4140
openssl = "0.10.13"
@@ -49,26 +48,24 @@ dotenv = "0.11.0"
4948
toml = "0.4"
5049
diesel = { version = "1.4.0", features = ["postgres", "serde_json", "chrono", "r2d2"] }
5150
diesel_full_text_search = "1.0.0"
52-
diesel_ltree = "0.1.3"
51+
swirl = { git = "https://github.com/sgrif/swirl.git", rev = "de5d8bb" }
5352
serde_json = "1.0.0"
54-
serde_derive = "1.0.0"
55-
serde = "1.0.0"
53+
serde = { version = "1.0.0", features = ["derive"] }
5654
chrono = { version = "0.4.0", features = ["serde"] }
57-
comrak = { version = "0.2.3", default-features = false }
58-
ammonia = "1.0.0"
55+
comrak = { version = "0.4.0", default-features = false }
56+
ammonia = "2.0.0"
5957
docopt = "0.8.1"
60-
itertools = "0.7.0"
6158
scheduled-thread-pool = "0.2.0"
6259
derive_deref = "1.0.0"
6360
reqwest = "0.9.1"
6461
tempdir = "0.3.7"
6562
collecting-hashmap = "0.2"
6663
parking_lot = "0.7.1"
67-
jemallocator = { version = "0.1.8", features = ['unprefixed_malloc_on_supported_platforms'] }
64+
jemallocator = { version = "0.1.8", features = ['unprefixed_malloc_on_supported_platforms', 'profiling'] }
6865
jemalloc-ctl = "0.2.0"
6966

70-
lettre = {git = "https://github.com/lettre/lettre", version = "0.9"}
71-
lettre_email = {git = "https://github.com/lettre/lettre", version = "0.9"}
67+
lettre = "0.9"
68+
lettre_email = "0.9"
7269

7370
conduit = "0.8"
7471
conduit-conditional-get = "0.8"
@@ -79,6 +76,7 @@ conduit-router = "0.8"
7976
conduit-static = "0.8"
8077
conduit-git-http-backend = "0.8"
8178
civet = "0.9"
79+
conduit-hyper = "0.1.3"
8280

8381
[dev-dependencies]
8482
conduit-test = "0.8"
@@ -87,7 +85,6 @@ hyper-tls = "0.3"
8785
futures = "0.1"
8886
lazy_static = "1.0"
8987
tokio-core = "0.1"
90-
tokio-service = "0.1"
9188

9289
[build-dependencies]
9390
dotenv = "0.11"

Procfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
web: bin/diesel migration run && bin/start-nginx ./target/release/server
2-
worker: ./target/release/update-downloads daemon 300
2+
background_worker: ./target/release/background-worker

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# crates.io
22

33
[![Build Status](https://travis-ci.org/rust-lang/crates.io.svg?branch=master)](https://travis-ci.org/rust-lang/crates.io)
4+
[![What's Deployed](https://img.shields.io/badge/whatsdeployed-prod-green.svg)](https://whatsdeployed.io/s-9IG)
45

56
Source code for the default [Cargo](http://doc.crates.io) registry. Viewable
67
online at [crates.io](https://crates.io).
@@ -15,7 +16,7 @@ of the following ways:
1516

1617
- [File a new issue](https://github.com/rust-lang/crates.io/issues/new)
1718
18-
- Chat on irc.mozilla.org in the [#rust-infra](https://kiwiirc.com/client/irc.mozilla.org:+6667/#rust-infra) channel
19+
- Chat on ops > #crates-io channel on https://discord.gg/rust-lang
1920

2021
A volunteer will get back to you as soon as possible.
2122

RustConfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
VERSION=1.32.0

app/components/download-graph.js

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,20 @@ export default Component.extend({
7878

7979
let myData = window.google.visualization.arrayToDataTable(data);
8080

81-
let fmt = new window.google.visualization.DateFormat({
81+
let dateFmt = new window.google.visualization.DateFormat({
8282
pattern: 'LLL d, yyyy',
8383
});
84-
fmt.format(myData, 0);
84+
dateFmt.format(myData, 0);
85+
86+
// Create a formatter to use for daily download numbers
87+
let numberFormatWhole = new window.google.visualization.NumberFormat({
88+
pattern: '#,##0',
89+
});
90+
91+
// Create a formatter to use for 7-day average numbers
92+
let numberFormatDecimal = new window.google.visualization.NumberFormat({
93+
pattern: '#,##0.0',
94+
});
8595

8696
// use a DataView to calculate an x-day moving average
8797
let days = 7;
@@ -101,7 +111,7 @@ export default Component.extend({
101111
let avg = total / days;
102112
return {
103113
v: avg,
104-
f: avg.toFixed(2),
114+
f: numberFormatDecimal.formatValue(avg),
105115
};
106116
};
107117
};
@@ -113,6 +123,8 @@ export default Component.extend({
113123
// is at the end, but in the UI we want it at the top of the chart legend.
114124

115125
range(headers.length - 1, 0, -1).forEach((dataCol, i) => {
126+
// Set the number format for the colum in the data table.
127+
numberFormatWhole.format(myData, dataCol);
116128
columns.push(dataCol); // add the column itself
117129
columns.push({
118130
// add a 'calculated' column, the moving average

app/routes/crate/version.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ export default Route.extend({
6262
.get('versions')
6363
.then(versions => {
6464
const latestStableVersion = versions.find(version => {
65-
if (!isUnstableVersion(version.get('num'))) {
65+
if (!isUnstableVersion(version.get('num')) && !version.get('yanked')) {
6666
return version;
6767
}
6868
});

app/routes/github-authorize.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import Route from '@ember/routing/route';
2-
import ajax from 'ember-fetch/ajax';
2+
import fetch from 'fetch';
33
import { serializeQueryParams } from 'ember-fetch/mixins/adapter-fetch';
44

55
/**
@@ -19,8 +19,9 @@ export default Route.extend({
1919
async beforeModel(transition) {
2020
try {
2121
let queryParams = serializeQueryParams(transition.queryParams);
22-
let d = await ajax(`/authorize?${queryParams}`);
23-
let item = JSON.stringify({ ok: true, data: d });
22+
let resp = await fetch(`/authorize?${queryParams}`);
23+
let json = await resp.json();
24+
let item = JSON.stringify({ ok: resp.ok, data: json });
2425
if (window.opener) {
2526
window.opener.github_response = item;
2627
}

0 commit comments

Comments
 (0)