Skip to content

Instantly share code, notes, and snippets.

View fuweid's full-sized avatar
🎯
Focusing

Fu Wei fuweid

🎯
Focusing
View GitHub Profile
package main
import (
"bufio"
"fmt"
"io"
"os"
"reflect"
"sort"
"strconv"
Release Status Start End of Life
1.5 End of Life May 3, 2021 February 28, 2023
1.6 LTS February 15, 2022 max(February 15, 2025 or next LTS + 6 months)
1.7 Active March 10, 2023 active(release of 2.0 + 6 months), extended(EOL of 1.6)
2.0 Next TBD TBD
package main
import (
"context"
"flag"
"fmt"
"strings"
"sync"
corev1 "k8s.io/api/core/v1"
From aa157746c01806af89f645ed2c5df8be45c1790d Mon Sep 17 00:00:00 2001
From: Wei Fu <fuweid89@gmail.com>
Date: Thu, 24 Aug 2023 07:39:25 +0000
Subject: [PATCH] delete v1.16.0 deps
Signed-off-by: Wei Fu <fuweid89@gmail.com>
---
api/etcdserverpb/gw/rpc.pb.gw.go | 170 ++++-----
pkg/go.mod | 11 +-
pkg/go.sum | 15 +-
From c4fc29e2b59863572b62a539e03e545bc7caaac7 Mon Sep 17 00:00:00 2001
From: Wei Fu <fuweid89@gmail.com>
Date: Wed, 23 Aug 2023 04:09:03 +0000
Subject: [PATCH] add legacygwjsonpb
Signed-off-by: Wei Fu <fuweid89@gmail.com>
---
pkg/legacygwjsonpb/marshal.go | 292 ++++++++++++++++++++++++++++++++++
scripts/test.sh | 4 +-
server/embed/serve.go | 8 +-
@fuweid
fuweid / 2019-https-localhost.md
Created April 3, 2023 06:42 — forked from cecilemuller/2019-https-localhost.md
How to create an HTTPS certificate for localhost domains

How to create an HTTPS certificate for localhost domains

This focuses on generating the certificates for loading local virtual hosts hosted on your computer, for development only.

Do not use self-signed certificates in production ! For online certificates, use Let's Encrypt instead (tutorial).

#!/usr/bin/env bash
set -euo pipefail
target_snapshot_id=$1
parent_id=""
snapshot_ids=""
# ensure that it is valid input
ctr -n k8s.io snapshot usage $target_snapshot_id > /dev/null
@fuweid
fuweid / gist:36dc32d4bb9eebfe51c7404fa21eaec0
Last active January 30, 2023 15:15
Linearizability Run Durations
go run main.go --owner etcd-io --repo etcd run list --workflow-id 36262010 --created 2022-12-01..2023-01-30 --jobs "test / test" --jobs "test" --event push --status success
ID NAME EVENT HEAD(MESSAGE) STATUS JOB(test / test) JOB(test) CREATED
4044118009 Linearizability push Merge pull request #15191 from serathius/linearizability-failpoints-timeout success 13m42s N/A Mon Jan 30 13:05:34 UTC 2023
4041995481 Linearizability push tools: fix the CSV format error and add build target 'tools' in Makefile success 14m26s N/A Mon Jan 30 08:35:48 UTC 2023
4041504776 Linearizability push fix(client):getToken automatically when the token has expired success 13m32s N/A Mon Jan 30 07:20:05 UTC 2023
4040377539 Linearizability push CHANGELOG: add item about improvement for concurrent read success 14m58
@fuweid
fuweid / gist:de5e21012f7eba2b7b2d694f1a8ea20a
Created September 17, 2022 10:26 — forked from simonheb/gist:b54b91358c3d7e2960a4f6e13e95ac54
Patching the 5.12 Linux kernel to support new Intel hardware (e.g., Intel Iris Xe for Thinkpad X1 Titanium Yoga) on Ubuntu/Debian/Pop!_OS

Get a 5.12 Linux kernel with support for newer Intel hardware (e.g., Intel Iris Xe for Thinkpad X1 Titanium Yoga) on Ubuntu/Debian/Pop!_OS

Prologue: Do I need this?

I recently got a Thinkpad sporting an Intel® Core™ i5-1140G7 Processor 11. gen (1,80 GHz, Turbo Boost, 4 Cores, 8 Threads, 8 MB Cache with an Integrated Intel® Iris® Xe. Sadly graphics drivers did not work out-of-the-box and also not with the latets 5.12 kernel from xenmod. You can tell it's not working when graphics are slow, backlight adjustment buttons don't work and this is the output of inxi -G (you might need to sudo apt install inxi):

simon@pop-os:~$ inxi -G
Graphics:
  Device-1: Intel driver: N/A 
  Device-2: IMC Networks Integrated Camera type: USB driver: uvcvideo 
  Display: x11 server: X.Org 1.20.9 driver: fbdev unloaded: modesetting,vesa 
 resolution: 2256x1504~95Hz