Skip to content

Commit

Permalink
Merge branch 'master' into woo/mobile_css
Browse files Browse the repository at this point in the history
  • Loading branch information
wookay authored May 6, 2017
2 parents bbd8c69 + e983ac3 commit 53a4db0
Show file tree
Hide file tree
Showing 5 changed files with 27 additions and 13 deletions.
7 changes: 6 additions & 1 deletion assets/html/documenter.css
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,12 @@ body, input {
}

pre, code {
font-family: 'Ubuntu Mono', Monaco, courier, monospace;
font-family: 'Roboto Mono', Monaco, courier, monospace;
font-size: 0.90em;
}

pre code {
font-size: 1em;
}

a {
Expand Down
2 changes: 1 addition & 1 deletion assets/latex/documenter.sty
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
\usepackage{fontspec, newunicodechar, polyglossia}

\setsansfont{Lato}[Scale=MatchLowercase, Ligatures=TeX]
\setmonofont{Fantasque Sans Mono}[Scale=MatchLowercase]
\setmonofont{Roboto Mono}[Scale=MatchLowercase]
\renewcommand{\familydefault}{\sfdefault}
%

Expand Down
14 changes: 8 additions & 6 deletions docs/src/man/hosting.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ Follow the instructions that are printed out, namely:

2. Next add the long private key to the Travis settings page using the provided link. Again
note that you should include **no whitespace** when copying the key. In the **`Environment
Variables`** section add a key with the name `DOCUMENTER_KEY` and the value that was printed
Variables`** section add a key with the name `DOCUMENTER_KEY` and the value that was printed
out. **Do not** set the variable to be displayed in the build log. Then click **`Add`**.

!!! warning "Security warning"
Expand Down Expand Up @@ -122,7 +122,7 @@ deploydocs(
```

where `USER_NAME` and `PACKAGE_NAME` must be set to the appropriate names. Note that `repo`
should not specify any protocol, i.e. it should not begin with `https://` or `git@`.
should not specify any protocol, i.e. it should not begin with `https://` or `git@`.

By default `deploydocs` will deploy the documentation from the `nightly` Julia build for
Linux. This can be changed using the `julia` and `osname` keywords as follows:
Expand Down Expand Up @@ -200,11 +200,13 @@ These are needed to avoid committing generated content to your repository.
## `gh-pages` Branch
Create a new branch called `gh-pages` and push it to GitHub. Note that a new and empty
`gh-pages` branch can be created following [these instructions](https://coderwall.com/p/0n3soa/create-a-disconnected-git-branch).
By default, Documenter pushes documentation to the `gh-pages` branch. If the branch does not
exist it will be created automatically by [`deploydocs`](@ref). If does exist then
Documenter simply adds an additional commit with the built documentation. You should be
aware that Documenter may overwrite existing content without warning.
If the `gh-pages` branch already exists then you can skip this step, but do note that the
generated content is automatically pushed to this branch from Travis.
If you wish to create the `gh-pages` branch manually the that can be done following
[these instructions](https://coderwall.com/p/0n3soa/create-a-disconnected-git-branch).
## Documentation Versions
Expand Down
15 changes: 11 additions & 4 deletions src/Documenter.jl
Original file line number Diff line number Diff line change
Expand Up @@ -295,8 +295,8 @@ following `repo` value:
repo = "github.com/JuliaDocs/Documenter.jl.git"
```
**`branch`** is the branch where the generated documentation is pushed. By default this
value is set to `"gh-pages"`.
**`branch`** is the branch where the generated documentation is pushed. If the branch does
not exist, a new orphaned branch is created automatically. It defaults to `"gh-pages"`.
**`latest`** is the branch that "tracks" the latest generated documentation. By default this
value is set to `"master"`.
Expand Down Expand Up @@ -467,8 +467,15 @@ function deploydocs(;
success(`git fetch upstream`) ||
error("could not fetch from remote.")

success(`git checkout -b $branch upstream/$branch`) ||
error("could not checkout remote branch.")
branch_exists = success(`git checkout -b $branch upstream/$branch`)

if !branch_exists
Utilities.log("assuming $branch doesn't exist yet; creating a new one.")
success(`git checkout --orphan $branch`) ||
error("could not create new empty branch.")
success(`git commit --allow-empty -m "Initial empty commit for docs"`) ||
error("could not commit to new branch $branch")
end

# Copy docs to `latest`, or `stable`, `<release>`, and `<version>` directories.
if isempty(travis_tag)
Expand Down
2 changes: 1 addition & 1 deletion src/Writers/HTMLWriter.jl
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ using ...Utilities.MDFlatten
const requirejs_cdn = "https://cdnjs.cloudflare.com/ajax/libs/require.js/2.2.0/require.min.js"
const normalize_css = "https://cdnjs.cloudflare.com/ajax/libs/normalize/4.2.0/normalize.min.css"
const highlightjs_css = "https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.5.0/styles/default.min.css"
const google_fonts = "https://fonts.googleapis.com/css?family=Lato|Ubuntu+Mono"
const google_fonts = "https://fonts.googleapis.com/css?family=Lato|Roboto+Mono"
const fontawesome_css = "https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.6.3/css/font-awesome.min.css"

"""
Expand Down

0 comments on commit 53a4db0

Please sign in to comment.