Skip to content

Commit

Permalink
update document
Browse files Browse the repository at this point in the history
  • Loading branch information
tamada committed Jul 15, 2023
1 parent 2b24865 commit f5059a4
Show file tree
Hide file tree
Showing 17 changed files with 99 additions and 966 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@
[submodule "docs/themes/loveit"]
path = docs/themes/loveit
url = https://github.com/dillonzq/LoveIt.git
[submodule "docs/themes/congo"]
path = docs/themes/congo
url = https://github.com/jpanther/congo.git
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ coverage.out: cmd/urleap/main_test.go
go test -covermode=count \
-coverprofile=coverage.out $(PACKAGE_LIST)

site:
make -C docs build_with_hugo

docker: urleap
# docker build -t ghcr.io/tamada/urleap:$(VERSION) -t ghcr.io/tamada/urleap:latest .
docker buildx build -t ghcr.io/tamada/urleap:$(VERSION) \
Expand Down
5 changes: 5 additions & 0 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
build_with_hugo:
hugo

start:
hugo server -D
10 changes: 10 additions & 0 deletions docs/config/_default/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
baseURL = "https://tamada.github.io/urleap"
defaultContentLanguage = "en"
theme = "congo"
title = "urleap"

enableRobotTXT = "true"
paginate = 15

[outputs]
home = ["HTML", "RSS", "JSON"]
9 changes: 9 additions & 0 deletions docs/config/_default/languages.en.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
languageName = "English"
copyright = "(C) 2023 Haruaki TAMADA"

[params]
dateFormat = "2006-01-02"

[author]
name = "Haruaki Tamada"
image = "harry.png"
13 changes: 13 additions & 0 deletions docs/config/_default/markup.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# -- Markup --
# These settings are required for the theme to function.

[goldmark]
[goldmark.renderer]
unsafe = true

[highlight]
noClasses = false

[tableOfContents]
startLevel = 2
endLevel = 3
40 changes: 40 additions & 0 deletions docs/config/_default/menus.en.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
# -- Main Menu --
# The main menu is displayed in the header at the top of the page.
# Acceptable parameters are name, pageRef, page, url, title, weight.
#
# The simplest menu configuration is to provide:
# name = The name to be displayed for this menu link
# pageRef = The identifier of the page or section to link to
#
# By default the menu is ordered alphabetically. This can be
# overridden by providing a weight value. The menu will then be
# ordered by weight from lowest to highest.

# [[main]]
# name = "Users"
# pageRef = "users"
# weight = 10

[[main]]
name = "GitHub"
url = "https://github.com/tamada/urleap"
weight = 40
[main.params]
icon = "github"
showName = false
target = "_blank"

[[main]]
identifier = "search"
weight = 99
[main.params]
action = "search"

# -- Footer Menu --
# The footer menu is displayed at the bottom of the page, just before
# the copyright notice. Configure as per the main menu above.

# [[footer]]
# name = "Tags"
# pageRef = "tags"
# weight = 10
2 changes: 2 additions & 0 deletions docs/config/_default/module.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[[imports]]
path = "github.com/jpanther/congo/v2"
5 changes: 5 additions & 0 deletions docs/config/_default/params.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
enableSearch = true
enableCodeCopy = true

[header]
logo = "urleap.png"
4 changes: 1 addition & 3 deletions docs/content/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
title: "urleap"
---

# urleap

URL shortener via bit.ly, etc.

[![build](https://github.com/tamada/urleap/actions/workflows/build.yml/badge.svg)](https://github.com/tamada/urleap/actions/workflows/build.yml)
Expand Down Expand Up @@ -111,4 +109,4 @@ docker run -it --rm tamada/urleap:latest -t <token> <url...>
### :jack_o_lantern: Icon
![Icon](docs/static/images/urleap.svg)
![Icon](assets/urleap.svg)
5 changes: 5 additions & 0 deletions docs/go.mod
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module github.com/tamada/urleap/docs

go 1.20

require github.com/jpanther/congo/v2 v2.6.1 // indirect
2 changes: 2 additions & 0 deletions docs/go.sum
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
github.com/jpanther/congo/v2 v2.6.1 h1:iA8uosVsiMl3JbBSBwMvrxEibzBcDp+RIj18f/cmlDs=
github.com/jpanther/congo/v2 v2.6.1/go.mod h1:1S7DRoO1ZYS4YUdFd1LjTkdyjQwsjFWd8TqSfz3Jd+M=

0 comments on commit f5059a4

Please sign in to comment.