Skip to content

Commit

Permalink
Remove all instances of baseurl
Browse files Browse the repository at this point in the history
rocksdb hit the problem that nuclide had.

facebookarchive/nuclide#789
facebookarchive/nuclide#793
  • Loading branch information
JoelMarcey committed Nov 3, 2016
1 parent 437942e commit 557034f
Show file tree
Hide file tree
Showing 13 changed files with 39 additions and 42 deletions.
1 change: 0 additions & 1 deletion docs/_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ gacode: "UA-49459723-1"
# organisation.github.io/reponame/ basic site URL, then baseurl would be set
# as "/reponame/" but leave blank if you have a top-level domain URL
# https://byparker.com/blog/2014/clearing-up-confusion-around-baseurl/
baseurl: ""
url: "http://rocksdb.org" # the base hostname & protocol for your site
ghrepo: "facebook/rocksdb"

Expand Down
5 changes: 2 additions & 3 deletions docs/_config_local_dev.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# Local development config settings to over-ride base.
# `jekyll serve` will by default generate a webserver at localhost:4000, so
# only change `url` if you're using a non-default location.
# only change `url` if you're using a non-default location.

baseurl: ""
url: "http://127.0.0.1:4000"
url: "http://127.0.0.1:4000"
9 changes: 4 additions & 5 deletions docs/_includes/blog_pagination.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<br />
<div class="pagination">
{% if paginator.previous_page %}
<a href="{{ paginator.previous_page_path | prepend: site.baseurl | replace: '//', '/' }}">&laquo; Prev</a>
<a href="{{ paginator.previous_page_path | replace: '//', '/' }}">&laquo; Prev</a>
{% else %}
<span>&laquo; Prev</span>
{% endif %}
Expand All @@ -12,18 +12,17 @@
{% if page == paginator.page %}
<em>{{ page }}</em>
{% elsif page == 1 %}
<a href="{{ '/blog' | prepend: site.baseurl }}">{{ page }}</a>
<a href="/blog">{{ page }}</a>
{% else %}
<a href="{{ site.paginate_path | prepend: site.baseurl | replace: '//', '/' | replace: ':num', page }}">{{ page }}</a>
<a href="{{ site.paginate_path | replace: '//', '/' | replace: ':num', page }}">{{ page }}</a>
{% endif %}
{% endfor %}

{% if paginator.next_page %}
<a href="{{ paginator.next_page_path | prepend: site.baseurl | replace: '//', '/' }}">Next &raquo;</a>
<a href="{{ paginator.next_page_path | replace: '//', '/' }}">Next &raquo;</a>
{% else %}
<span>Next &raquo;</span>
{% endif %}
</div>
<br />
{% endif %}

4 changes: 2 additions & 2 deletions docs/_includes/doc.html
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<div class="post">
<header class="post-header">
<h1 class="post-title">{% if include.truncate %}<a href="{{ site.url }}{{ site.baseurl }}{{ page.url }}">{{ page.title }}</a>{% else %}{{ page.title }}{% endif %}</h1>
<h1 class="post-title">{% if include.truncate %}<a href="{{ page.url }}">{{ page.title }}</a>{% else %}{{ page.title }}{% endif %}</h1>
</header>

<article class="post-content">
{% if include.truncate %}
{% if page.content contains '<!--truncate-->' %}
{{ page.content | split:'<!--truncate-->' | first }}
<div class="read-more">
<a href="{{ site.url }}{{ site.baseurl }}{{ page.url }}" >
<a href="{{ page.url }}" >
...Read More
</a>
</div>
Expand Down
14 changes: 7 additions & 7 deletions docs/_includes/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,23 +3,23 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">

<meta property="og:url" content="{{ page.url | replace:'index.html','' | prepend: site.baseurl | prepend: site.url }}" />
<meta property="og:url" content="{{ page.url | replace:'index.html','' | prepend: site.url }}" />
<meta property="og:site_name" content="{{ site.title }}"/>
<meta property="og:title" content="{% if page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}" />
<meta property="og:image" content="{{ site.url }}{{ site.baseurl }}/static/og_image.png" />
<meta property="og:image" content="{{ site.url }}/static/og_image.png" />
<meta property="og:description" content="{% if page.excerpt %}{{ page.excerpt | strip_html | strip_newlines | truncate: 160 }}{% else %}{{ site.description }}{% endif %}" />

<link rel="stylesheet" href="{{ site.url }}{{ site.baseurl }}/css/main.css" media="screen">
<link rel="icon" href="{{ site.url }}{{ site.baseurl }}/static/favicon.png" type="image/x-icon">
<link rel="stylesheet" href="{{ site.url }}/css/main.css" media="screen">
<link rel="icon" href="{{ site.url }}/static/favicon.png" type="image/x-icon">
{% if site.searchconfig %}
<link rel="stylesheet" href="https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.css" />
{% endif %}

<title>{% if page.title %}{{ page.title }} | {{ site.title }}{% else %}{{ site.title }}{% endif %}</title>
<meta name="description" content="{% if page.excerpt %}{{ page.excerpt | strip_html | strip_newlines | truncate: 160 }}{% else %}{{ site.description }}{% endif %}">

<base href="{{ site.url }}{{ site.baseurl }}/" />
<base href="{{ site.url }}/" />

<link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.baseurl | prepend: site.url }}">
<link rel="alternate" type="application/rss+xml" title="{{ site.title }}" href="{{ "/feed.xml" | prepend: site.baseurl | prepend: site.url }}" />
<link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.url }}">
<link rel="alternate" type="application/rss+xml" title="{{ site.title }}" href="{{ "/feed.xml" | prepend: site.url }}" />
</head>
4 changes: 2 additions & 2 deletions docs/_includes/header.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div class="headerContainer">
<div id="header_wrap" class="wrapper headerWrapper">
<div class="inner">
<img class="projectLogo" height="200px" src="{{ site.baseurl }}/static/logo.svg" alt="{{ site.title }}" title="{{ site.title }}" />
<img class="projectLogo" height="200px" src="/static/logo.svg" alt="{{ site.title }}" title="{{ site.title }}" />
<h1 id="project_title">{{ site.title }}</h1>
<h2 id="project_tagline" class="fbossFontLight">{{ site.tagline }}</h2>

Expand All @@ -16,4 +16,4 @@ <h2 id="project_tagline" class="fbossFontLight">{{ site.tagline }}</h2>
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion docs/_includes/home_header.html
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ <h2 id="project_tagline">{{ site.tagline }}</h2>
</div>
</div>
<div class="projectLogo">
<img src="{{ site.baseurl }}/static/logo.svg" alt="{{ site.title }}">
<img src="/static/logo.svg" alt="{{ site.title }}">
</div>
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions docs/_includes/nav.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<div id="fixed_header" class="fixedHeaderContainer{% if include.alwayson %} visible{% endif %}">
<div class="headerWrapper wrapper">
<header>
<a href="{{ site.url }}{{ site.baseurl }}/">
<img src="{{ site.baseurl }}/static/logo.svg">
<a href="{{ site.url }}/">
<img src="/static/logo.svg">
<h2>{{ site.title }}</h2>
</a>

Expand Down
4 changes: 2 additions & 2 deletions docs/_includes/plugins/post_social_plugins.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@
<a
href="https://twitter.com/share"
class="twitter-share-button"
data-url="{{ page.url | replace:'index.html','' | prepend: site.baseurl | prepend: site.url }}"
data-url="{{ page.url | replace:'index.html','' | prepend: site.url }}"
data-text="{% if page.title %}{{ page.title }}{% else %}{{ site.title }}{% endif %}"
data-hashtags="flowtype">Tweet</a>
<div
class="fb-like"
data-href="{{ page.url | replace:'index.html','' | prepend: site.baseurl | prepend: site.url }}"
data-href="{{ page.url | replace:'index.html','' | prepend: site.url }}"
data-layout="button_count"
data-action="like"
data-show-faces="false"
Expand Down
4 changes: 2 additions & 2 deletions docs/_includes/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
{% if author.full_name %}
<p class="post-authorName">{{ author.full_name }}</p>
{% endif %}
<h1 class="post-title">{% if include.truncate %}<a href="{{ site.url }}{{ site.baseurl }}{{ page.url }}">{{ page.title }}</a>{% else %}{{ page.title }}{% endif %}</h1>
<h1 class="post-title">{% if include.truncate %}<a href="{{ site.url }}{{ page.url }}">{{ page.title }}</a>{% else %}{{ page.title }}{% endif %}</h1>
<p class="post-meta">Posted {{ page.date | date: '%B %d, %Y' }}{% if page.meta %} • {{ page.meta }}{% endif %}</p>
</header>

Expand All @@ -18,7 +18,7 @@ <h1 class="post-title">{% if include.truncate %}<a href="{{ site.url }}{{ site.b
{% if page.content contains '<!--truncate-->' %}
{{ page.content | split:'<!--truncate-->' | first | markdownify }}
<div class="read-more">
<a href="{{ site.url }}{{ site.baseurl }}{{ page.url }}" >
<a href="{{ site.url }}{{ page.url }}" >
Read More
</a>
</div>
Expand Down
2 changes: 1 addition & 1 deletion docs/blog/all.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ <h1>All Posts</h1>
{% assign author = site.data.authors[post.author] %}
<p>
<strong>
<a href="{{ site.baseurl }}{{ post.url }}">{{ post.title }}</a>
<a href="{{ post.url }}">{{ post.title }}</a>
</strong>
on {{ post.date | date: "%B %e, %Y" }} by {{ author.display_name }}
</p>
Expand Down
20 changes: 10 additions & 10 deletions docs/css/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,40 +5,40 @@

@font-face {
font-family: 'Lato';
src: url('{{ site.baseurl }}/static/fonts/LatoLatin-Italic.woff2') format('woff2'),
url('{{ site.baseurl }}/static/fonts/LatoLatin-Italic.woff') format('woff');
src: url('/static/fonts/LatoLatin-Italic.woff2') format('woff2'),
url('/static/fonts/LatoLatin-Italic.woff') format('woff');
font-weight: normal;
font-style: italic;
}

@font-face {
font-family: 'Lato';
src: url('{{ site.baseurl }}/static/fonts/LatoLatin-Black.woff2') format('woff2'),
url('{{ site.baseurl }}/static/fonts/LatoLatin-Black.woff') format('woff');
src: url('/static/fonts/LatoLatin-Black.woff2') format('woff2'),
url('/static/fonts/LatoLatin-Black.woff') format('woff');
font-weight: 900;
font-style: normal;
}

@font-face {
font-family: 'Lato';
src: url('{{ site.baseurl }}/static/fonts/LatoLatin-BlackItalic.woff2') format('woff2'),
url('{{ site.baseurl }}/static/fonts/LatoLatin-BlackItalic.woff') format('woff');
src: url('/static/fonts/LatoLatin-BlackItalic.woff2') format('woff2'),
url('/static/fonts/LatoLatin-BlackItalic.woff') format('woff');
font-weight: 900;
font-style: italic;
}

@font-face {
font-family: 'Lato';
src: url('{{ site.baseurl }}/static/fonts/LatoLatin-Light.woff2') format('woff2'),
url('{{ site.baseurl }}/static/fonts/LatoLatin-Light.woff') format('woff');
src: url('/static/fonts/LatoLatin-Light.woff2') format('woff2'),
url('/static/fonts/LatoLatin-Light.woff') format('woff');
font-weight: 300;
font-style: normal;
}

@font-face {
font-family: 'Lato';
src: url('{{ site.baseurl }}/static/fonts/LatoLatin-Regular.woff2') format('woff2'),
url('{{ site.baseurl }}/static/fonts/LatoLatin-Regular.woff') format('woff');
src: url('/static/fonts/LatoLatin-Regular.woff2') format('woff2'),
url('/static/fonts/LatoLatin-Regular.woff') format('woff');
font-weight: normal;
font-style: normal;
}
Expand Down
8 changes: 4 additions & 4 deletions docs/feed.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ layout: null
<channel>
<title>{{ site.title | xml_escape }}</title>
<description>{{ site.description | xml_escape }}</description>
<link>{{ site.url }}{{ site.baseurl }}/</link>
<atom:link href="{{ "/feed.xml" | prepend: site.baseurl | prepend: site.url }}" rel="self" type="application/rss+xml"/>
<link>{{ site.url }}/</link>
<atom:link href="{{ "/feed.xml" | prepend: site.url }}" rel="self" type="application/rss+xml"/>
<pubDate>{{ site.time | date_to_rfc822 }}</pubDate>
<lastBuildDate>{{ site.time | date_to_rfc822 }}</lastBuildDate>
<generator>Jekyll v{{ jekyll.version }}</generator>
Expand All @@ -16,8 +16,8 @@ layout: null
<title>{{ post.title | xml_escape }}</title>
<description>{{ post.content | xml_escape }}</description>
<pubDate>{{ post.date | date_to_rfc822 }}</pubDate>
<link>{{ post.url | prepend: site.baseurl | prepend: site.url }}</link>
<guid isPermaLink="true">{{ post.url | prepend: site.baseurl | prepend: site.url }}</guid>
<link>{{ post.url | prepend: site.url }}</link>
<guid isPermaLink="true">{{ post.url | prepend: site.url }}</guid>
{% for tag in post.tags %}
<category>{{ tag | xml_escape }}</category>
{% endfor %}
Expand Down

0 comments on commit 557034f

Please sign in to comment.