-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add hex logo and add to README
- Loading branch information
Showing
7 changed files
with
186 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,36 @@ | ||
# GMH Leasing Package - `gmhleasr` <img src="man/figures/hex_logo.svg" width="120" height="auto" alight="right"/> | ||
|
||
# gmhleasr | ||
> [!NOTE] | ||
> This is an R oackage for GMH Leasing. It is a work in progress. | ||
<!-- badges: start --> | ||
|
||
<!-- badges: end --> | ||
|
||
## Contents {#contents} | ||
|
||
- [Contents](#contents) | ||
- [Overview](#overview) | ||
- [Installation](#installation) | ||
- [Example](#example) | ||
|
||
## Overview {#overview} | ||
|
||
The goal of gmhleasr is to ... | ||
|
||
## Installation | ||
## Installation {#installation} | ||
|
||
You can install the development version of gmhleasr like so: | ||
|
||
``` r | ||
# FILL THIS IN! HOW CAN PEOPLE INSTALL YOUR DEV PACKAGE? | ||
``` | ||
|
||
## Example | ||
## Example {#example} | ||
|
||
This is a basic example which shows you how to solve a common problem: | ||
|
||
``` r | ||
library(gmhleasr) | ||
## basic example code | ||
``` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
|
||
# ------------------------------------------------------------------------ | ||
# | ||
# Title : Package Hex Logo | ||
# By : Jimmy Briggs | ||
# Date : 2024-08-18 | ||
# | ||
# ------------------------------------------------------------------------ | ||
|
||
# hexmake::run_app(with_mongo = FALSE) | ||
|
||
library(magick) | ||
library(hexSticker) | ||
|
||
logo_url <- "https://cdn.brandfetch.io/gmhcommunities.com/logo" | ||
icon_url <- "https://cdn.brandfetch.io/gmhcommunities.com/icon" | ||
|
||
output_file_png <- "man/figures/hex_logo.png" | ||
output_file_svg <- "man/figures/hex_logo.svg" | ||
|
||
assets_dir <- "inst/assets/images" | ||
fs::dir_create(assets_dir, recurse = TRUE) | ||
|
||
gmh_color <- "#0e2b4c" | ||
|
||
# png --------------------------------------------------------------------- | ||
|
||
hexSticker::sticker( | ||
package = "gmhleasr", | ||
subplot = logo_url, | ||
url = "github.com/noclocks/gmhleasr", | ||
filename = output_file_png, | ||
p_x = 1, | ||
p_y = 1.4, | ||
p_family = "sans", | ||
p_color = gmh_color, | ||
p_size = 7, | ||
s_width = 0.6, | ||
s_height = 1, | ||
s_x = 1, | ||
s_y = 0.9, | ||
asp = 1, | ||
u_x = 1, | ||
u_y = 0.08, | ||
u_color = gmh_color, | ||
u_family = "mono", | ||
u_size = 1.3, | ||
u_angle = 30, | ||
h_fill = "white", | ||
h_color = gmh_color | ||
) | ||
|
||
fs::file_copy(output_file_png, assets_dir) | ||
|
||
|
||
# svg --------------------------------------------------------------------- | ||
|
||
hexSticker::sticker( | ||
package = "gmhleasr", | ||
subplot = logo_url, | ||
url = "github.com/noclocks/gmhleasr", | ||
filename = output_file_svg, | ||
p_x = 1, | ||
p_y = 1.4, | ||
p_family = "sans", | ||
p_color = gmh_color, | ||
p_size = 7, | ||
s_width = 0.6, | ||
s_height = 1, | ||
s_x = 1, | ||
s_y = 0.9, | ||
asp = 1, | ||
u_x = 1, | ||
u_y = 0.08, | ||
u_color = gmh_color, | ||
u_family = "mono", | ||
u_size = 1.3, | ||
u_angle = 30, | ||
h_fill = "white", | ||
h_color = gmh_color | ||
) | ||
|
||
fs::file_copy(output_file_svg, assets_dir) | ||
|
||
browseURL(output_file_svg) |
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.