diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..820631c --- /dev/null +++ b/Makefile @@ -0,0 +1,6 @@ +.PHONY: all gen + +all: gen + +gen: + go run . diff --git a/README.md b/README.md index ea2db3c..19837ae 100644 --- a/README.md +++ b/README.md @@ -12,3 +12,9 @@ Steps: # Genrate HTML go run ./main.go ``` + +## Thanks + +- https://motherfuckingwebsite.com/ +- http://bettermotherfuckingwebsite.com/ +- https://evenbettermotherfucking.website/ diff --git a/docs/2022-06-08-backup.html b/docs/2022-06-08-backup.html index 3ba6cee..1b1796f 100644 --- a/docs/2022-06-08-backup.html +++ b/docs/2022-06-08-backup.html @@ -1,4 +1,4 @@ -

Backup my way

First thing first, I want to list my own devices, which I have through the years:

App/Service I use daily:

The purpose is that I want my data to be safe, secure, and can be easily recovered if I lost some devices;
or in the worst situation, I lost all.
Because you know, it is hard to guess what is waiting for us in the future.

There are 2 sections which I want to share, the first is How to backup, the second is Recover strategy.

How to backup

Before I talk about backup, I want to talk about data.
In specifically, which data should I backup?

I use Arch Linux and macOS, primarily work in the terminal so I have too many dotfiles, for example, ~/.config/nvim/init.lua.
Each time I reinstall Arch Linux (I like it a lot), I need to reconfigure all the settings, and it is time-consuming.

So for the DE and UI settings, I keep it as default as possible, unless it's getting in my way, I leave the default setting there and forget about it.
The others are dotfiles, which I write my own dotfiles tool to backup and reconfigure easily and quickly.
Also, I know that installing Arch Linux is not easy, despite I install it too many times (Like thousand times since I was in high school).
Not because it is hard, but as life goes on, the official install guide keeps getting new update and covering too many cases for my own personal use, so I write my own guide to quickly capture what I need to do.
I back up all my dotfiles inside my dotfiles tool in GitHub and GitLab as I trust them both.
Also as I travel the Internet, I discover Codeberg and Treehouse and use them as another backup for git repo.

So that is my dotfiles, for my regular data, like Wallpaper or Books, Images, I use Google Drive (Actually I pay for it).
But the step: open the webpage, click the upload button and choose files seems boring and time-consuming.
So I use Rclone, it supports Google Drive, One Drive and many providers but I only use Google Drive for now.
The commands are simple:

# Sync from local to remote
+

Backup my way

First thing first, I want to list my own devices, which I have through the years:

App/Service I use daily:

The purpose is that I want my data to be safe, secure, and can be easily recovered if I lost some devices;
or in the worst situation, I lost all.
Because you know, it is hard to guess what is waiting for us in the future.

There are 2 sections which I want to share, the first is How to backup, the second is Recover strategy.

How to backup

Before I talk about backup, I want to talk about data.
In specifically, which data should I backup?

I use Arch Linux and macOS, primarily work in the terminal so I have too many dotfiles, for example, ~/.config/nvim/init.lua.
Each time I reinstall Arch Linux (I like it a lot), I need to reconfigure all the settings, and it is time-consuming.

So for the DE and UI settings, I keep it as default as possible, unless it's getting in my way, I leave the default setting there and forget about it.
The others are dotfiles, which I write my own dotfiles tool to backup and reconfigure easily and quickly.
Also, I know that installing Arch Linux is not easy, despite I install it too many times (Like thousand times since I was in high school).
Not because it is hard, but as life goes on, the official install guide keeps getting new update and covering too many cases for my own personal use, so I write my own guide to quickly capture what I need to do.
I back up all my dotfiles inside my dotfiles tool in GitHub and GitLab as I trust them both.
Also as I travel the Internet, I discover Codeberg and Treehouse and use them as another backup for git repo.

So that is my dotfiles, for my regular data, like Wallpaper or Books, Images, I use Google Drive (Actually I pay for it).
But the step: open the webpage, click the upload button and choose files seems boring and time-consuming.
So I use Rclone, it supports Google Drive, One Drive and many providers but I only use Google Drive for now.
The commands are simple:

# Sync from local to remote
 rclone sync MyBooks remote:MyBooks -P --exclude .DS_Store
 
 # Sync from remote to local
diff --git a/docs/2022-06-08-dockerfile-go.html b/docs/2022-06-08-dockerfile-go.html
index 4ff7b30..9386ef2 100644
--- a/docs/2022-06-08-dockerfile-go.html
+++ b/docs/2022-06-08-dockerfile-go.html
@@ -1,4 +1,4 @@
-

Dockerfile for Go

Each time I start a new Go project, I repeat many steps.
Like set up .gitignore, CI configs, Dockerfile, ...

So I decide to have a baseline Dockerfile like this:

FROM golang:1.18-bullseye as builder
+

Dockerfile for Go

Each time I start a new Go project, I repeat many steps.
Like set up .gitignore, CI configs, Dockerfile, ...

So I decide to have a baseline Dockerfile like this:

FROM golang:1.18-bullseye as builder
 
 RUN go install golang.org/dl/go1.18@latest \
     && go1.18 download
diff --git a/docs/2022-07-10-bootstrap-go.html b/docs/2022-07-10-bootstrap-go.html
index 2d951bb..c8a17e5 100644
--- a/docs/2022-07-10-bootstrap-go.html
+++ b/docs/2022-07-10-bootstrap-go.html
@@ -1,4 +1,4 @@
-

Bootstrap Go

It is hard to write bootstrap tool to quickly create Go service.
So I write this guide instead.
This is a quick checklist for me every damn time I need to write a Go service from scratch.
Also, this is my personal opinion, so feel free to comment.

Structure

main.go
+

Bootstrap Go

It is hard to write bootstrap tool to quickly create Go service.
So I write this guide instead.
This is a quick checklist for me every damn time I need to write a Go service from scratch.
Also, this is my personal opinion, so feel free to comment.

Structure

main.go
 internal
 | business_1
 | | http
diff --git a/docs/index.html b/docs/index.html
index ea4ff3e..e1ad559 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -1 +1 @@
-

Index

This is where I dump my thoughts.

\ No newline at end of file +

Index

This is where I dump my thoughts.

\ No newline at end of file diff --git a/docs/styles.css b/docs/styles.css index bae6287..09080f7 100644 --- a/docs/styles.css +++ b/docs/styles.css @@ -1 +1 @@ -body{font-family:recursive,sans-serif;font-variation-settings:"MONO" 0,"CASL" 1}code{font-family:recursive,monospace;font-variation-settings:"MONO" 1,"CASL" 1} \ No newline at end of file +body{font-family:recursive,sans-serif;font-variation-settings:"MONO" 0,"CASL" 1;margin:5% auto;max-width:75%;line-height:1.8}code{font-family:recursive,monospace;font-variation-settings:"MONO" 1,"CASL" 1} \ No newline at end of file diff --git a/templates/post.html b/templates/post.html index cb5a86c..a570380 100644 --- a/templates/post.html +++ b/templates/post.html @@ -2,6 +2,7 @@ +