Skip to content

Instantly share code, notes, and snippets.

View szampardi's full-sized avatar

Silvano Zampardi szampardi

View GitHub Profile
@KunYi
KunYi / meshtastic_pio_heltec_v2.0.md
Last active April 30, 2026 08:13
build meshtastic firmware for heltec LoRa 32 v2.0

Build meshtastic firmware (2.5.16.c3d60342) for Heltec LoRAa 32 v2

$ mkdir -p /tmp/pio
$ cd /tmp/pio
$ virtualenv .
$ source bin/activate
$ pip install -U platformio
$ git clone https://github.com/meshtastic/firmware.git --recurse-submodules # pull source code
$ cd firmware
@nbeguier
nbeguier / nginx.conf
Last active May 2, 2026 19:58
Nginx: TLS Security Configuration 2026
# Nginx TLS security configuration
# Updated: 2026-05-02
# Baseline: Mozilla SSL Configuration Generator 6.0, Intermediate
server {
listen 80;
listen [::]:80;
server_name __REDACTED__;
return 301 https://$host$request_uri;
}

[guide] keycloak authentication for proxmox

How to setup Proxmox to use Keycloak as authentication realm.

Proxmox Setup

root@proxmox:/etc/pve# cat domains.cfg
pam: pam
        comment Linux PAM standard authentication
@smallnest
smallnest / fork_and_daemon.go
Created April 20, 2020 06:52 — forked from wrfly/fork_and_daemon.go
golang fork and exec and handle signals
package main
import (
"flag"
"fmt"
"log"
"os"
"os/signal"
"syscall"
)
@arjunv
arjunv / keyevents.json
Created December 2, 2018 00:01
All Android Key Events for usage with adb shell
{
"key_events": {
"key_unknown": "adb shell input keyevent 0",
"key_soft_left": "adb shell input keyevent 1",
"key_soft_right": "adb shell input keyevent 2",
"key_home": "adb shell input keyevent 3",
"key_back": "adb shell input keyevent 4",
"key_call": "adb shell input keyevent 5",
"key_endcall": "adb shell input keyevent 6",
"key_0": "adb shell input keyevent 7",
@mraaroncruz
mraaroncruz / steps.md
Last active April 23, 2026 01:32
Get the Telegram channel ID

To get the channel id

  1. Create your bot with botfather
  2. Make you bot an admin of your channel

Simplest way (via @anhtuank7c)

Go to Telegram web and open a channel, get the ID from -[channel id] from hash in the path

https://web.telegram.org/k/#-9999999999999

@petemoore
petemoore / main_windows.go
Last active August 8, 2024 15:32
Running process as interactive user from windows service with UAC process elevation
package main
import (
"context"
"errors"
"fmt"
"log"
"os"
"os/exec"
"syscall"
@heralight
heralight / gen-dummy-package.sh
Created November 3, 2015 17:59
A script to generate dummy debian package with equivs to bypass crazy dependencies
#!/bin/bash
installPackage=false
function process
{
packageName=$1
echo "######### key : $packageName"
v=$(eval "apt-cache policy $packageName | grep 'Candidate:' | cut -c 14-")
echo "######### version: $v"
@cpburnz
cpburnz / Brother_DCP-L2540DW_on_Arch_Linux.rst
Last active May 11, 2026 07:58
Brother DCP-L2540DW on Arch Linux

Brother DCP-L2540DW on Arch Linux

Printer

The printer driver can be installed with the brother-brgenml1 AUR package.

@plentz
plentz / nginx.conf
Last active May 5, 2026 07:20
Best nginx configuration for improved security(and performance)
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048