Skip to content

Commit c23ab4b

Browse files
authored
Move cargo.png into assets folder (rust-lang#5591)
There is no obvious need for this file to exist outside of the `assets` folder and need special handling in nginx
1 parent 3cec6dc commit c23ab4b

File tree

6 files changed

+4
-11
lines changed

6 files changed

+4
-11
lines changed

app/components/header.hbs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<header local-class="header {{if @hero "hero"}}">
22
<div local-class="header-inner">
33
<LinkTo @route="index" local-class="index-link">
4-
<img src="/cargo.png" role="presentation" alt="" local-class="logo">
4+
<img src="/assets/cargo.png" role="presentation" alt="" local-class="logo">
55
<h1>crates.io</h1>
66
</LinkTo>
77

app/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919
{{content-for 'head-footer'}}
2020
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon">
21-
<link rel="icon" href="/cargo.png" type="image/png">
21+
<link rel="icon" href="/assets/cargo.png" type="image/png">
2222
<link rel="search" href="/opensearch.xml" type="application/opensearchdescription+xml" title="Cargo">
2323

2424
<meta name="google" content="notranslate" />

config/manifest.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ module.exports = function (/* environment, appConfig */) {
1111
theme_color: '#f9f7ec',
1212
icons: [
1313
{
14-
src: '/cargo.png',
14+
src: '/assets/cargo.png',
1515
sizes: '227x227',
1616
type: 'image/png',
1717
},

config/nginx.conf.erb

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -203,13 +203,6 @@ http {
203203
expires max;
204204
}
205205

206-
location ~ ^/cargo-[0-9a-f]*\.png$ {
207-
add_header X-Content-Type-Options nosniff;
208-
add_header Cache-Control public;
209-
root dist;
210-
expires max;
211-
}
212-
213206
location ~ /(favicon\.ico|robots\.txt|opensearch\.xml) {
214207
add_header X-Content-Type-Options nosniff;
215208
add_header Cache-Control public;
File renamed without changes.

public/opensearch.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22
<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/">
33
<ShortName>Cargo</ShortName>
44
<Description>Search for crates on crates.io</Description>
5-
<Image type="image/png">https://crates.io/cargo.png</Image>
5+
<Image type="image/png">https://crates.io/assets/cargo.png</Image>
66
<Url type="text/html" method="get" template="https://crates.io/search?q={searchTerms}"/>
77
</OpenSearchDescription>

0 commit comments

Comments
 (0)