Skip to content

Commit

Permalink
build site
Browse files Browse the repository at this point in the history
  • Loading branch information
luisDVA committed Oct 7, 2024
1 parent 0671fdf commit 94fe804
Show file tree
Hide file tree
Showing 19 changed files with 104 additions and 3,766 deletions.
4 changes: 4 additions & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,7 @@
^LICENSE\.md$
^README\.Rmd$
^cran-comments\.md$
^_pkgdown\.yml$
^docs$
^pkgdown$
^\.github$
1 change: 1 addition & 0 deletions .github/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*.html
50 changes: 50 additions & 0 deletions .github/workflows/pkgdown.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
push:
branches: [main, master]
pull_request:
branches: [main, master]
release:
types: [published]
workflow_dispatch:

name: pkgdown.yaml

permissions: read-all

jobs:
pkgdown:
runs-on: ubuntu-latest
# Only restrict concurrency for non-PR jobs
concurrency:
group: pkgdown-${{ github.event_name != 'pull_request' || github.run_id }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
permissions:
contents: write
steps:
- uses: actions/checkout@v4

- uses: r-lib/actions/setup-pandoc@v2

- uses: r-lib/actions/setup-r@v2
with:
use-public-rspm: true

- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::pkgdown, local::.
needs: website

- name: Build site
run: pkgdown::build_site_github_pages(new_process = FALSE, install = FALSE)
shell: Rscript {0}

- name: Deploy to GitHub pages 🚀
if: github.event_name != 'pull_request'
uses: JamesIves/[email protected]
with:
clean: false
branch: gh-pages
folder: docs
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@
.httr-oauth
.DS_Store
.quarto
docs
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,5 @@ Config/testthat/edition: 3
Encoding: UTF-8
Roxygen: list(markdown = TRUE)
RoxygenNote: 7.3.2.9000
URL: https://github.com/luisDVA/hexsession
URL: https://github.com/luisDVA/hexsession, https://luisdva.github.io/hexsession/
BugReports: https://github.com/luisDVA/hexsession/issues
10 changes: 7 additions & 3 deletions README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ knitr::opts_chunk$set(
[![CRAN status](https://www.r-pkg.org/badges/version/hexsession)](https://CRAN.R-project.org/package=hexsession)
<!-- badges: end -->

The goal of hexsession is to create tile of hexagonal logos for each loaded package in a session (all packages attached to the search path except for base packages).
The goal of hexsession is to create a tile of hexagonal logos for each loaded package in a session (all packages attached to the search path except for base packages).

## Installation

Expand Down Expand Up @@ -65,12 +65,16 @@ hexsession::make_tile()
```

The output would look like this:
![](man/figures/exampletile.png)
![](man/figures/hsdemo.gif)
_I don't know how to show the rendered interactive file on the GitHub readme, if anyone does please let me know 😅._

Once downloaded, the [hexout_example.html](inst/extdata/hexout_example.html) shows the interactive, responsive HTML version that adapts to the size of the browser window and includes hyperlinks to each package website.
Once downloaded to your machine and opened in a browser, the [hexout_example.html](inst/extdata/hexout_example.html) shows the interactive, responsive HTML version with cool hover effects that adapts to the size of the browser window and includes hyperlinks to each package website.

To save a static version of the hex tile, we call `snap_tile()` with a path to the output image and optionally, height and width values to change the viewport size.

The result:

![](man/figures/exampletile.png)

## Notes

Expand Down
17 changes: 12 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](h
status](https://www.r-pkg.org/badges/version/hexsession)](https://CRAN.R-project.org/package=hexsession)
<!-- badges: end -->

The goal of hexsession is to create tile of hexagonal logos for each
The goal of hexsession is to create a tile of hexagonal logos for each
loaded package in a session (all packages attached to the search path
except for base packages).

Expand Down Expand Up @@ -62,17 +62,24 @@ library(patchwork)
hexsession::make_tile()
```

The output would look like this: ![](man/figures/exampletile.png)
The output would look like this: ![](man/figures/hsdemo.gif) *I don’t
know how to show the rendered interactive file on the GitHub readme, if
anyone does please let me know 😅.*

Once downloaded, the
Once downloaded to your machine and opened in a browser, the
[hexout_example.html](inst/extdata/hexout_example.html) shows the
interactive, responsive HTML version that adapts to the size of the
browser window and includes hyperlinks to each package website.
interactive, responsive HTML version with cool hover effects that adapts
to the size of the browser window and includes hyperlinks to each
package website.

To save a static version of the hex tile, we call `snap_tile()` with a
path to the output image and optionally, height and width values to
change the viewport size.

The result:

![](man/figures/exampletile.png)

## Notes

This packages depends on working installations of magick, Quarto, and
Expand Down
4 changes: 4 additions & 0 deletions _pkgdown.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
url: https://luisdva.github.io/hexsession/
template:
bootstrap: 5

Binary file added man/figures/hsdemo.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added pkgdown/favicon/apple-touch-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added pkgdown/favicon/favicon-48x48.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added pkgdown/favicon/favicon.ico
Binary file not shown.
3 changes: 3 additions & 0 deletions pkgdown/favicon/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
21 changes: 21 additions & 0 deletions pkgdown/favicon/site.webmanifest
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"name": "MyWebSite",
"short_name": "MySite",
"icons": [
{
"src": "/web-app-manifest-192x192.png",
"sizes": "192x192",
"type": "image/png",
"purpose": "maskable"
},
{
"src": "/web-app-manifest-512x512.png",
"sizes": "512x512",
"type": "image/png",
"purpose": "maskable"
}
],
"theme_color": "#ffffff",
"background_color": "#ffffff",
"display": "standalone"
}
Binary file added pkgdown/favicon/web-app-manifest-192x192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added pkgdown/favicon/web-app-manifest-512x512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 94fe804

Please sign in to comment.