Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

readme & docs update #201

Merged
merged 8 commits into from
Apr 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 12 additions & 11 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,15 @@ jobs:
working-directory: docs
run: make deploy

- name: Create and push CNAME file to gh-pages
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Actions"
git checkout gh-pages

echo "go-blueprint.net" > CNAME

git add CNAME
git commit -m "Add CNAME file"
git push origin gh-pages
# config for custom domain on gh-pages
# - name: Create and push CNAME file to gh-pages
# run: |
# git config --local user.email "[email protected]"
# git config --local user.name "GitHub Actions"
# git checkout gh-pages

# echo "<domain>" > CNAME

# git add CNAME
# git commit -m "Add CNAME file"
# git push origin gh-pages
15 changes: 13 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ gives the option to integrate with one of the more popular Go frameworks (and th
- Integrate with a popular frameworks
- Focus on the actual code of your application

Check the official Go-blueprint [docs](https://go-blueprint.net).

## Table of Contents

- [Install](#install)
- [Frameworks Supported](#frameworks-supported)
- [Database Support](#database-support)
- [Advanced Features](#advanced-features)
- [Blueprint UI](#blueprint-ui)
- [Usage Example](#usage-example)
- [GitHub Stats](#github-stats)
- [License](#license)
Expand Down Expand Up @@ -112,6 +112,17 @@ You can now use the `--advanced` flag when running the `create` command to get a
- CI/CD workflow setup using [Github Actions](https://docs.github.com/en/actions)
- [Websocket](https://pkg.go.dev/nhooyr.io/websocket) sets up a websocket endpoint

<a id="blueprint-ui"></a>

<h2>
<picture>
<img src="./public/ui.gif?raw=true" width="100px" style="margin-right: 1px;">
</picture>
Blueprint UI
</h2>

Blueprint UI is a web application that allows you to create commands for the CLI and preview the structure of your project. You will be able to see directories and files that will be created upon command execution. Check it out at [go-blueprint.dev](https://go-blueprint.dev)

<a id="usage-example"></a>

<h2>
Expand Down Expand Up @@ -163,7 +174,7 @@ go-blueprint create --name my-project --framework chi --driver mysql --advanced
<img src="./public/blueprint_advanced.png" alt="Advanced Options" width="800"/>
</p>

**Visit [documentation](https://go-blueprint.net) to learn more about blueprint and its features.**
**Visit [documentation](https://docs.go-blueprint.dev) to learn more about blueprint and its features.**

<a id="github-stats"></a>

Expand Down
1 change: 0 additions & 1 deletion docs/CNAME

This file was deleted.

6 changes: 6 additions & 0 deletions docs/custom_theme/main.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{% extends "base.html" %}

{% block libs %}
{{ super() }}
<script defer data-domain="docs.go-blueprint.dev" src="https://analytics.go-blueprint.dev/js/script.js"></script>
{% endblock %}
4 changes: 1 addition & 3 deletions docs/docs/advanced-flag/goreleaser.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
## GoReleaser - Automating Releases with GoReleaser

Release process for Go projects, providing extensive customization options through its configuration file, `.goreleaser.yml`. By default, it ensures dependency cleanliness, builds binaries for various platforms and architectures, facilitates pre-release creation, and organizes binary packaging into archives with naming schemes.

For comprehensive insights into customization possibilities, refer to the [GoReleaser documentation](https://goreleaser.com/customization/).
Expand All @@ -26,7 +24,7 @@ Following these steps ensures proper tagging of your project, prompting GoReleas

The `go-test.yml` file defines a GitHub Actions workflow for continuous integration (CI) of Go projects within a GitHub repository.

### Workflow Steps
## Workflow Steps

The job outlined in this workflow includes the following steps:

Expand Down
2 changes: 0 additions & 2 deletions docs/docs/advanced-flag/htmx-tmpl.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
## HTMX and Templ Setup

The WEB directory contains the web-related components and assets for the project. It leverages htmx and tmpl in Go for dynamic web content generation.

## Structure
Expand Down
2 changes: 0 additions & 2 deletions docs/docs/advanced-flag/websocket.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
## Websocket

A `/websocket` endpoint is added in `routes.go` to facilitate websocket connections. Upon accessing this endpoint, the server establishes a websocket connection and begins transmitting timestamp messages at 2-second intervals. WS is utilized across all Go-blueprint supported frameworks. This simple implementation showcases how flexible project is.

## Testing with WebSocat
Expand Down
2 changes: 0 additions & 2 deletions docs/docs/blueprint-core/db-drivers.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
## Database Drivers

To extend the project with database functionality, users can choose from a variety of Go database drivers. Each driver is tailored to work with specific database systems, providing flexibility based on project requirements:

1. [Mongo](https://go.mongodb.org/mongo-driver): Provides necessary tools for connecting and interacting with MongoDB databases.
Expand Down
3 changes: 0 additions & 3 deletions docs/docs/blueprint-core/frameworks.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
## Frameworks


Created project can utilizes several Go web frameworks to handle HTTP routing and server functionality. The chosen frameworks are:

1. [**Chi**](https://github.com/go-chi/chi): Lightweight and flexible router for building Go HTTP services.
Expand Down
7 changes: 7 additions & 0 deletions docs/docs/blueprint-ui.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
The Blueprint UI is a crucial component of the Go Blueprint ecosystem, providing a user-friendly interface for creating CLI commands and visualizing project structures.

By visiting the Blueprint UI website at [go-blueprint.dev](https://go-blueprint.dev), users can interact with a visual representation of their project setup before executing commands.

![BlueprintUI](public/blueprint_ui.png)

This enhances the overall experience of using Go Blueprint by providing a visual representation of project setups and simplifying the command generation process.
4 changes: 4 additions & 0 deletions docs/docs/index.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
---
hide:
- toc
---
## Go Blueprint - Ultimate Golang Blueprint Library

![logo](./public/logo.png)
Expand Down
7 changes: 4 additions & 3 deletions docs/docs/installation.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## Installation


---
hide:
- toc
---
Go-Blueprint provides a convenient CLI tool to effortlessly set up your Go projects. Follow the steps below to install the tool on your system.

## Binary Installation
Expand Down
Binary file added docs/docs/public/blueprint_ui.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
43 changes: 37 additions & 6 deletions docs/mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,36 @@

site_name: Go-Blueprint Docs
site_description: Official documentation for Go-Blueprint project
site_url: https://go-blueprint.net/
site_url: https://docs.go-blueprint.dev/

repo_url: https://github.com/Melkeydev/go-blueprint
edit_uri: edit/main/docs/docs

### Build settings ###

theme: readthedocs
theme:
name: material
custom_dir: custom_theme/
theme:
features:
- navigation.instant
- navigation.sections
- navigation.footer
- toc.flow
palette:
- scheme: default
toggle:
icon: material/brightness-7
name: Switch to dark mode
- scheme: slate
toggle:
icon: material/brightness-4
name: Switch to light mode

nav:
- Home: index.md
- Installation: installation.md
- Blueprint UI: blueprint-ui.md
- Project creation & default config:
- Project init: creating-project/project-init.md
- Makefile: creating-project/makefile.md
Expand All @@ -22,7 +41,19 @@ nav:
- Frameworks: blueprint-core/frameworks.md
- DB Drivers: blueprint-core/db-drivers.md
- Advanced Flag:
- 'AF Usage': advanced-flag/advanced-flag.md
- 'HTMX and Templ': advanced-flag/htmx-tmpl.md
- 'GoReleaser & GoTest CI': advanced-flag/goreleaser.md
- 'Websocket': advanced-flag/websocket.md
- AF Usage: advanced-flag/advanced-flag.md
- HTMX and Templ: advanced-flag/htmx-tmpl.md
- GoReleaser & GoTest CI: advanced-flag/goreleaser.md
- Websocket: advanced-flag/websocket.md

extra:
social:
- icon: fontawesome/brands/twitch
link: https://www.twitch.tv/melkey
name: Twitch
- icon: fontawesome/brands/discord
link: https://discord.com/invite/HHZMSCu
name: Discord
generator: false

copyright: Copyright &copy; 2024 Melkey
1 change: 1 addition & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
mkdocs==1.5.3
mkdocs-material==9.5.15
Binary file added public/ui.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading