Skip to content

Instantly share code, notes, and snippets.

View hungdoansy's full-sized avatar
📺

Hung Doan hungdoansy

📺
View GitHub Profile
@hungdoansy
hungdoansy / renew-gpgkey.md
Created August 16, 2022 08:11 — forked from krisleech/renew-gpgkey.md
Renew Expired GPG key

Renew GPG key

Given that your key has expired.

$ gpg --list-keys
$ gpg --edit-key KEYID

Use the expire command to set a new expire date:

@hungdoansy
hungdoansy / normalize_string.go
Created June 29, 2022 08:43 — forked from nvtuan305/normalize_string.go
golang: normalize string (include Vietnamese)
package main
import (
"fmt"
"golang.org/x/text/runes"
"golang.org/x/text/transform"
"golang.org/x/text/unicode/norm"
"strings"
"unicode"
)
@hungdoansy
hungdoansy / GPG and git on macOS.md
Created August 16, 2021 08:49 — forked from danieleggert/GPG and git on macOS.md
How to set up git to use the GPG Suite

GPG and git on macOS

Setup

No need for homebrew or anything like that. Works with https://www.git-tower.com and the command line.

  1. Install https://gpgtools.org -- I'd suggest to do a customized install and deselect GPGMail.
  2. Create or import a key -- see below for https://keybase.io
  3. Run gpg --list-secret-keys and look for sec, use the key ID for the next step
  4. Configure git to use GPG -- replace the key with the one from gpg --list-secret-keys