Skip to content

Instantly share code, notes, and snippets.

View nickzelei's full-sized avatar

Nick Zelei nickzelei

View GitHub Profile
@nickzelei
nickzelei / sidebar.tsx
Created May 21, 2025 20:54
Shadcn multi-sidebar
import { cn } from '@/lib/utils'
import { Slot } from '@radix-ui/react-slot'
import { VariantProps, cva } from 'class-variance-authority'
import { PanelLeftIcon } from 'lucide-react'
import * as React from 'react'
import { useIsMobile } from '../../lib/hooks/useMobile'
import { Button } from './button'
import { Input } from './input'
import KeybindingTooltip from './KeybindingTooltip'
import { Separator } from './separator'
@nickzelei
nickzelei / 1-setup.md
Created January 10, 2025 03:48 — forked from troyfontaine/1-setup.md
Signing your Git Commits on MacOS

Methods of Signing Git Commits on MacOS

Last updated March 13, 2024

This Gist explains how to sign commits using gpg in a step-by-step fashion. Previously, krypt.co was heavily mentioned, but I've only recently learned they were acquired by Akamai and no longer update their previous free products. Those mentions have been removed.

Additionally, 1Password now supports signing Git commits with SSH keys and makes it pretty easy-plus you can easily configure Git Tower to use it for both signing and ssh.

For using a GUI-based GIT tool such as Tower or Github Desktop, follow the steps here for signing your commits with GPG.

@nickzelei
nickzelei / main.go
Created May 23, 2024 18:12
Prometheus Daily Counts Optimized
package main
import (
"context"
"fmt"
"log"
"sort"
"sync"
"time"
@nickzelei
nickzelei / main.go
Last active May 22, 2024 16:40
Prometheus Daily Counts
package main
import (
"context"
"fmt"
"log"
"sort"
"time"
"github.com/prometheus/client_golang/api"
@nickzelei
nickzelei / helmfile.yaml
Created June 9, 2023 18:43
Istio Ingress on GKE
repositories:
- name: istio
url: https://istio-release.storage.googleapis.com/charts
---
releases:
- name: istio-ingressgateway
chart: istio/gateway
version: 1.17.1
namespace: istio-system
createNamespace: false
@nickzelei
nickzelei / db.mjs
Last active May 20, 2023 18:07
DragonBall Subbed File Rename Script
/*
* Quick and dirty script to rename files downloaded from: https://archive.org/details/dragon-ball-remastered-bluray-complete-e-1-e-153-eng-dub
* I only downloaded the mkv files but this will rename them well enough for Sonarr to be able to properly organize.
*/
import fs from 'fs';
const matcher = /Dragonball\sS01[E|e](\d+)(.+)/i;
(async () => {
@nickzelei
nickzelei / main.go
Created February 14, 2023 03:34
STS V2 Presign K8s Token
package main
import (
"context"
"encoding/base64"
"fmt"
"net/http"
"time"
"github.com/aws/aws-sdk-go-v2/aws"
@nickzelei
nickzelei / main.go
Created October 18, 2022 17:06
Kube Connect
package main
import (
"os"
"k8s.io/client-go/kubernetes"
"k8s.io/client-go/tools/clientcmd"
clientcmdapi "k8s.io/client-go/tools/clientcmd/api"
)

Keybase proof

I hereby claim:

  • I am nickzelei on github.
  • I am nicknucleus (https://keybase.io/nicknucleus) on keybase.
  • I have a public key ASATSc9csCnNU8kcskFKEbqCEvaTzYFKO7fZS-E2PhrfLgo

To claim this, I am signing this object:

@nickzelei
nickzelei / github-release.sh
Last active May 14, 2020 16:11
Create a Github Release at the current package.json version
#!/bin/sh
# https://gist.github.com/DarrenN/8c6a5b969481725a4413
# Modified to trim spaces
PACKAGE_VERSION=$(cat package.json \
| grep version \
| head -1 \
| awk -F: '{ print $2 }' \
| sed 's/[ ",]//g')
RELEASE_NAME="v$PACKAGE_VERSION"