Skip to content

Commit

Permalink
setup separate site & repository markdown profiles | fix for gfm site…
Browse files Browse the repository at this point in the history
… output quarto issue
  • Loading branch information
prncevince committed Sep 6, 2023
1 parent b386d1b commit 407d263
Show file tree
Hide file tree
Showing 39 changed files with 6,975 additions and 42 deletions.
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ __pycache__/
*.nb.html
*_cache
# Quarto
#/_freeze/
/_freeze/
/.quarto-cli/
.quarto/
# User RStudio & R Markdown to preview markdown files before on remote repo
Expand Down
15 changes: 12 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,9 +1,18 @@
.PHONY: docs docs-dev docs-preview docs-preview-python conda-env-export conda-env-create
.PHONY: docs docs-dev docs-site docs-md docs-preview docs-preview-python conda-env-export conda-env-create

CONDA_ENV = environment.yml

docs:
quarto render
docs: docs-site docs-md

#docs:
# quarto render --profile site
# quarto render --profile md --to gfm

docs-site:
quarto render --profile site

docs-md:
quarto render --profile md --to gfm

docs-dev:
quarto preview
Expand Down
17 changes: 10 additions & 7 deletions SETUP.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
# Quarto Site Environment Setup

Here's all the setup.
# Quarto Site Environment Setup

Here’s all the setup.

## Quarto

Setup [quarto-shims](https://github.com/prncevince/quarto-shims).

Then, run below to install & setup quarto. `wget` is required in your shell environment, can be installed on Mac via homebrew.
Then, run below to install & setup quarto. `wget` is required in your
shell environment, can be installed on Mac via homebrew.

```sh
``` sh
./utils/download-quarto.sh
```

Expand All @@ -18,13 +20,14 @@ Setup [r-shims](https://github.com/prncevince/r-shims).

Create RStudio project within RStudio.

```r
``` r
rstudioapi::initializeProject()
```

Initialize the `{renv}` environment. Important packages can be discovered in [utils/deps.R](utils/deps.R)
Initialize the `{renv}` environment. Important packages can be
discovered in [utils/deps.R](utils/deps.R).

```r
``` r
renv::init()
```

Expand Down
43 changes: 43 additions & 0 deletions SETUP.qmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
---
format:
html:
code-fold: false
---

# Quarto Site Environment Setup

Here's all the setup.

## Quarto

Setup [quarto-shims](https://github.com/prncevince/quarto-shims).

Then, run below to install & setup quarto. `wget` is required in your shell environment, can be installed on Mac via homebrew.

```sh
./utils/download-quarto.sh
```

## R

Setup [r-shims](https://github.com/prncevince/r-shims).

Create RStudio project within RStudio.

```{r}
#| eval: false
rstudioapi::initializeProject()
```

Initialize the `{renv}` environment. Important packages can be discovered in [utils/deps.R](utils/deps.R).

```{r}
#| eval: false
renv::init()
```

## Start

Explode on paper.

## Fin
6 changes: 6 additions & 0 deletions _quarto-md.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
project:
render:
- SETUP.qmd
format:
gfm:
preview-mode: raw
37 changes: 37 additions & 0 deletions _quarto-site.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
project:
type: website
output-dir: _site
execute-dir: project
post-render:
- touch _site/.nojekyll
website:
title: prncevince
site-url: https://prncevince.github.io/
description: ''
repo-branch: main
repo-url: https://github.com/prncevince/prncevince.github.io
page-navigation: true
navbar:
right:
- text: About
href: about/index.qmd
- icon: github
href: https://github.com/prncevince
- icon: twitter
href: https://twitter.com/prncevincecares
format:
html:
code-fold: true
code-link: true
css: assets/css/style.css
grid:
body-width: 1100px
sidebar-width: 300px
margin-width: 300px
gutter-width: 1.5rem
theme:
light: [flatly]
dark: [darkly]
toc: true
toc-depth: 6

32 changes: 1 addition & 31 deletions _quarto.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,2 @@
project:
type: website
output-dir: _site
execute-dir: project
post-render:
- touch _site/.nojekyll
execute:
freeze: auto
website:
title: prncevince
author: Vincent Clemson
repo-url: https://github.com/prncevince/prncevince.github.io
navbar:
right:
- about.qmd
- icon: github
href: https://github.com/prncevince
- icon: twitter
href: https://twitter.com/prncevincecares
format:
html:
code-fold: true
code-link: true
css: assets/css/style.css
grid:
body-width: 1100px
sidebar-width: 300px
margin-width: 300px
gutter-width: 1.5rem
toc: true
toc-depth: 6

freeze: auto
Empty file added _site/.nojekyll
Empty file.
Loading

0 comments on commit 407d263

Please sign in to comment.