Skip to content

Instantly share code, notes, and snippets.

View thinhdanggroup's full-sized avatar

thinhda thinhdanggroup

View GitHub Profile
@thinhdanggroup
thinhdanggroup / k8s-ssh-tunnel.md
Created March 13, 2022 04:04
Access another pod over SSH tunnel in K8s
  1. Install devspace to access k8s easily
    brew install devspace
  2. accessable-pod is a pod that you can access over ssh
    devspace -n <accessable-pod> enter -- bash -c "echo $(cat ~/.ssh/id_rsa.pub) >> ~/.ssh/authorized_keys"
  3. copy local key to
@thinhdanggroup
thinhdanggroup / Install_nodejs.md
Last active March 13, 2022 03:51
Fastest way to install newest nodejs

Requirement

  1. Download lastest version in homepage

http://nodejs.org

Install

  1. Extract file

tar -xvf node-*.tar.xz

@JamesMenetrey
JamesMenetrey / README.md
Last active September 29, 2022 08:27
Install Oh-My-Zsh + iTerm2 with Solarized + System-wide console in 2017 (macOS)

Install iTerm2 with Solarized in 2017

Here is the looks and feel of your terminal once the tutorial has been applied on your system:

Install iTerm2

Using Homebrew:

FWIW: I (@rondy) am not the creator of the content shared here, which is an excerpt from Edmond Lau's book. I simply copied and pasted it from another location and saved it as a personal note, before it gained popularity on news.ycombinator.com. Unfortunately, I cannot recall the exact origin of the original source, nor was I able to find the author's name, so I am can't provide the appropriate credits.


Effective Engineer - Notes

What's an Effective Engineer?

@marcel-dias
marcel-dias / ParseSample.java
Last active March 31, 2024 15:14
SnakeYAML Parse Example
package com.marceldias.mars.yaml;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.InputStream;
import org.yaml.snakeyaml.TypeDescription;
import org.yaml.snakeyaml.Yaml;
# Make sure you grab the latest version
curl -OL https://github.com/google/protobuf/releases/download/v3.2.0/protoc-3.2.0-linux-x86_64.zip
# Unzip
unzip protoc-3.2.0-linux-x86_64.zip -d protoc3
# Move protoc to /usr/local/bin/
sudo mv protoc3/bin/* /usr/local/bin/
# Move protoc3/include to /usr/local/include/
@dblock
dblock / getWeek.js
Created July 13, 2011 22:49
get week of the year in JavaScript
function( d ) {
// Create a copy of this date object
var target = new Date(d.valueOf());
// ISO week date weeks start on monday
// so correct the day number
var dayNr = (d.getDay() + 6) % 7;
// Set the target to the thursday of this week so the