Skip to content

Instantly share code, notes, and snippets.

View thinkJD's full-sized avatar

Jan Georgens thinkJD

  • essentry
  • Germany
View GitHub Profile
@wgbartley
wgbartley / Spark-DHT22.pde
Last active November 20, 2016 17:09
Class for reading DHT22 values on a Spark Core
#define MAXTIMINGS 85
#define cli noInterrupts
#define sei interrupts
#define DHT11 11
#define DHT22 22
#define DHT21 21
#define AM2301 21
@soarez
soarez / ca.md
Last active November 21, 2025 15:58
How to setup your own CA with OpenSSL

How to setup your own CA with OpenSSL

For educational reasons I've decided to create my own CA. Here is what I learned.

First things first

Lets get some context first.

configure
delete system name-server
set system name-server 127.0.0.1
Since you are getting an IP on your WAN address via DHCP, you'll need to tell the dhcp-client not to add the ISP DNS servers to /etc/resolv.conf.
set interfaces ethernet eth0 dhcp-options name-server no-update
By default, dnsmasq will send queries to any of the upstream servers it knows about and tries to favour servers that are known to be up. If you want to query the servers in order instead, then add the following:
set service dns forwarding options strict-order
@Icaruk
Icaruk / multipleGitProfiles.md
Last active November 25, 2025 21:48
How to have multiple profiles on git

Last update: 30-01-2024
Last view: 25-11-2025

Step 1

Go to your work folder, mine is located at: F:/Work/EnterpriseName/

And then create a .gitconfig-work with the following data:

@jemadux
jemadux / gist:4019ade6580d062794111e7988d261e0
Created January 25, 2022 22:05
dracula theme powerlevel p10k
sed -i 's/POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND=255/POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND=244/g' ~/.p10k.zsh
sed -i 's/POWERLEVEL9K_OS_ICON_FOREGROUND=232/POWERLEVEL9K_OS_ICON_FOREGROUND=255/g' ~/.p10k.zsh
sed -i 's/POWERLEVEL9K_OS_ICON_BACKGROUND=7/POWERLEVEL9K_OS_ICON_BACKGROUND=67/g' ~/.p10k.zsh
sed -i 's/POWERLEVEL9K_PROMPT_CHAR_OK_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=76/POWERLEVEL9K_PROMPT_CHAR_OK_{VIINS,VICMD,VIVIS,VIOWR}_FOREGROUND=84/g' ~/.p10k.zsh
sed -i 's/POWERLEVEL9K_DIR_SHORTENED_FOREGROUND=250/POWERLEVEL9K_DIR_SHORTENED_FOREGROUND=0/g' ~/.p10k.zsh
sed -i 's/POWERLEVEL9K_DIR_ANCHOR_FOREGROUND=255/POWERLEVEL9K_DIR_ANCHOR_FOREGROUND=0/g' ~/.p10k.zsh
sed -i 's/POWERLEVEL9K_STATUS_OK_BACKGROUND=0/POWERLEVEL9K_STATUS_OK_BACKGROUND=235/g' ~/.p10k.zsh
sed -i 's/POWERLEVEL9K_STATUS_OK_PIPE_BACKGROUND=0/POWERLEVEL9K_STATUS_OK_PIPE_BACKGROUND=235/g' ~/.p10k.zsh