Skip to content

Instantly share code, notes, and snippets.

View a2902793's full-sized avatar
🚀
Seven years per hour here. Let's make it count.

Johnny Yeng a2902793

🚀
Seven years per hour here. Let's make it count.
View GitHub Profile

Conventional Commit Messages

See how a minor change to your commit message style can make a difference. Examples

Have a look at CLI util git-conventional-commits to ensure this conventions and generate changelogs

Commit Formats

Default

@a2902793
a2902793 / Documentation.md
Created November 10, 2021 12:56 — forked from KartikTalwar/Documentation.md
Rsync over SSH - (40MB/s over 1GB NICs)

The fastest remote directory rsync over ssh archival I can muster (40MB/s over 1gb NICs)

This creates an archive that does the following:

rsync (Everyone seems to like -z, but it is much slower for me)

  • a: archive mode - rescursive, preserves owner, preserves permissions, preserves modification times, preserves group, copies symlinks as symlinks, preserves device files.
  • H: preserves hard-links
  • A: preserves ACLs
@a2902793
a2902793 / ckad-bookmarks.html
Created August 26, 2021 13:32 — forked from runlevl4/ckad-bookmarks.html
CKAD Bookmarks (** indicates example source) [originally sourced from https://github.com/nikhilagrawal577/ckad-notes]
<!DOCTYPE NETSCAPE-Bookmark-file-1>
<!-- This is an automatically generated file.
It will be read and overwritten.
DO NOT EDIT! -->
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8">
<TITLE>Bookmarks</TITLE>
<H1>Bookmarks</H1>
<DL><p>
<DT><H3 ADD_DATE="1576816453" LAST_MODIFIED="1578776782">CKAD</H3>
<DL><p>
@a2902793
a2902793 / WSL2GUIXvnc-en.md
Last active March 9, 2021 06:56 — forked from tdcosta100/WSL2GUIXvnc-en.md
A tutorial to use GUI in WSL2 replacing original XServer by Xvnc, allowing WSL to work like native Linux, including login screen

WSL2 with GUI using Xvnc

In this tutorial, we will setup GUI in WSL2, and access it using VNC. No additional software outside WSL (like VcXsrv) is required, except, of course, a VNC Viewer (RealVNC, TightVNC, TigerVNC, UVNC, etc, all of them might work flawlessly).

The key components we need to install are tigervnc-standalone-server and systemd-genie.

For this setup, I will use Ubuntu 20.04 LTS (Focal Fossa), and install GNOME Desktop. Since the key components aren't bound to Ubuntu or GNOME, you can use your favorite distro and GUI. Check the Sample screenshots section for examples.

So let's go. First, we need a working [WSL2](https://docs.microsoft.com/pt-br/windows/wsl/w

@a2902793
a2902793 / practice2.s
Last active December 23, 2020 15:40
上課練習2
AREA PROG1, CODE ;This code is written by: 406500578 YENG, LI-CHUNG
ENTRY
;1. To put even parity for bits 6, 8, 10 of r0 into bit 1 of r1(with the other bits of r1 unchanged)
;2. To compare bit 10 of r1 with bit 9 of r0; if different, put 1 in r6; otherwise, put 0 in r6
LDR R0, =0xABCD
LDR r1, =0xBBFF
LDR r2, =0xBBAA
LDR r3, =0xFFDD
;---------------------------------------------------------------------
;Generate parity bit for bits 6, 8, 10
@a2902793
a2902793 / hamming.s
Last active December 30, 2020 16:55
AREA HAMMING, CODE ; This homework is written by:
ENTRY ; 406500578 YENG, LI-CHUNG
; 407507010 LIN,YEN-HSUAN
; 406210061 YEN,TSAI-TING
; 8bit -> 12bit
; 0xC6 -> 0xC38
;
; 1 checksum bit wrong: C0 = 0xA3F
; C1 = 0xA3C
@a2902793
a2902793 / GitCommitEmoji.md
Created October 16, 2020 14:18 — forked from parmentf/GitCommitEmoji.md
Git Commit message Emoji
@a2902793
a2902793 / wsl2-network.ps1
Created October 16, 2020 10:48 — forked from daehahn/wsl2-network.ps1
WSL 2 TCP NETWORK FORWARDING
# WSL2 network port forwarding script v1
# for enable script, 'Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope CurrentUser' in Powershell,
# for delete exist rules and ports use 'delete' as parameter, for show ports use 'list' as parameter.
# written by Daehyuk Ahn, Aug-1-2020
# Display all portproxy information
If ($Args[0] -eq "list") {
netsh interface portproxy show v4tov4;
exit;
}
@a2902793
a2902793 / wt.reg
Created August 13, 2020 14:43
Windows Terminal Here
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Directory\Background\shell\wt]
@="Windows Terminal here"
"Icon"="%USERPROFILE%\\AppData\\Local\\terminal\\wt_32.ico"
[HKEY_CLASSES_ROOT\Directory\Background\shell\wt\command]
@="C:\\Users\\a2902\\AppData\\Local\\Microsoft\\WindowsApps\\wt.exe -d ."
[HKEY_CLASSES_ROOT\Directory\shell\wt]
@a2902793
a2902793 / Unlock Cadence
Last active July 14, 2020 15:10
Cadence locks files so that files are not edited by two independent copies of Cadence. However, sometimes lock files are not correctly removed. In this case you may get a message like “Couldn’t get a write lock for…”.
#!/bin/sh
find ~/ -name “*.cdslck” -exec rm {} \;
# Source: https://www.cade.utah.edu/faqs/can-you-explain-how-to-remove-cadence-lock-files/