Skip to content

Instantly share code, notes, and snippets.

Avatar
🌻
if you know, you know

Meghan nektro

🌻
if you know, you know
View GitHub Profile
View commands.md
@nektro
nektro / Dockerfile
Created Mar 19, 2021
minimal requirements to build and install zig from scratch with docker
View Dockerfile
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND=noninteractive
WORKDIR /root
COPY . .
RUN apt update
RUN apt -y upgrade
RUN apt -y install apt-utils apt-transport-https ca-certificates
RUN apt -y install wget gpg
View update_zig.sh
#!/usr/bin/env bash
set -e
arch=$(uname -m)
os=$(uname -s | tr '[:upper:]' '[:lower:]')
double="$arch-$os"
if [[ $1 == *"dev"* ]]; then
wget -q --show-progress https://ziglang.org/builds/zig-linux-x86_64-$1.tar.xz
@nektro
nektro / network_containers.go
Created Oct 7, 2020
Read the names and IDs of all the containers in a docker network
View network_containers.go
package main
import (
"encoding/json"
"fmt"
"io/ioutil"
"net"
"net/http"
)
View daemonset.node_exporter.yml
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: node_exporter
namespace: prometheus/node_exporter
spec:
template:
metadata:
labels:
name: node_exporter
@nektro
nektro / get_github_user.sh
Created Sep 29, 2020
./get_github_user.sh <username>
View get_github_user.sh
#!/usr/bin/env bash
c1=1
c2=0
mkdir -p $1
cd $1
IFS=$'\n'
uid="$GITHUB_CLIENT"
@nektro
nektro / onion-address-gen.go
Last active Jun 25, 2022
Golang Vanity v3 Onion Address Generator
View onion-address-gen.go
package main
import (
"crypto"
"crypto/ed25519"
"encoding/base32"
"encoding/base64"
"encoding/hex"
"flag"
"fmt"
@nektro
nektro / hello_world.ll
Last active Aug 7, 2020
LLVM 10 Hello World
View hello_world.ll
@0 = global [15 x i8] c"Hello, world!\0A\00"
define i32 @1(i8* %0) {
1:
%2 = ptrtoint i8* %0 to i64
%3 = call i64 asm sideeffect "syscall", "=r,{rax},{rdi},{rsi},{rdx}"(i64 1, i64 1, i64 %2, i64 15)
ret i32 0
}
define i32 @main() {
0:
View keybase.md

Keybase proof

I hereby claim:

  • I am nektro on github.
  • I am nektro (https://keybase.io/nektro) on keybase.
  • I have a public key ASDrf2NGIRUIhTL0Q-W-WOtb4NhTV26AcwT265RmVSmdSwo

To claim this, I am signing this object:

View gpg.txt
-----BEGIN PGP PUBLIC KEY BLOCK-----
mQINBF11bxYBEAC33e7bGs/uISbcR4vCZ0z/PsFHBKL1eL/VpzbDStHYo3N4e7kv
cHd1NptpRltSgdqsC3bAgVS37q8sQBDsQXEpWtFGC1b3v82OI8E7caTlNDZKwv2P
UAwT7R9SdoX8QJImWo7eRZDMnFMc0/HbOXNzvWYExoYcQM3awlUjTEOsaX3WwFDx
fZ0MKcx5XTXk3qSixZLt7pIyx4CaIACUM36wbvxU7CpSL0qkRyGwlWjangvN+b9o
vmPbZk3uVeZO4mvHUmimpiZYCOjrDBaIMAUm9KBtfSWZU25wbj5QKvKVkSyDvWFw
Wz5YdBkLWsORBU5G8KTZAMh/XdDuO2hXPIlbUagCmxm7WFPtglY//nCuXiUAGPxL
lBeKFlduJ6er4ICXGYtOJ0g9Ay5x6CM1Dn7a0myM2ZGXa/SlTMfbLaa9/4xfy0Ew
aLqwNQQ7vkjTyuW2AKgEsGNYUYIZ7iAaYoR+HuapQdRQ8anTNrL4g1M3ja2wEPcb