Skip to content

Instantly share code, notes, and snippets.

@0xack13
0xack13 / gha_map.py
Created January 29, 2025 22:21
gha_map
import os
import yaml
from pathlib import Path
import argparse
def find_called_workflows(file_path):
"""Parse a workflow file to find referenced workflows."""
called_workflows = set()
with open(file_path, "r") as f:
try:
@0xack13
0xack13 / compare_ts.py
Last active January 28, 2025 20:28
compare_ts
import sys
from datetime import datetime
def prepend_diff(input_file, output_file):
# Read all lines from the input file
with open(input_file, 'r') as file:
lines = file.readlines()
output_lines = []
prev_timestamp = None
@0xack13
0xack13 / github-actions-notes.md
Created January 16, 2025 04:56 — forked from br3ndonland/github-actions-notes.md
Getting the Gist of GitHub Actions
@0xack13
0xack13 / .tmux.conf
Last active January 27, 2025 15:36
Brewfile
source-file ${HOME}/.tmux-themepack/powerline/default/green.tmuxtheme
setw -g mouse on
bind -T copy-mode-vi y send -X copy-pipe "xclip -selection c"
bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'select-pane -t=; copy-mode -e; send-keys -M'"
bind -n WheelDownPane select-pane -t= \; send-keys -M
bind -n C-WheelUpPane select-pane -t= \; copy-mode -e \; send-keys -M
bind -T copy-mode-vi C-WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-vi C-WheelDownPane send-keys -X halfpage-down
bind -T copy-mode-emacs C-WheelUpPane send-keys -X halfpage-up
bind -T copy-mode-emacs C-WheelDownPane send-keys -X halfpage-down
@0xack13
0xack13 / flink-quickstart-scala.sh
Created July 13, 2024 19:49 — forked from cesarcneto/flink-quickstart-scala.sh
Create an apache-flink scala project using the provided quickstart archetype
@0xack13
0xack13 / ca.md
Created February 11, 2024 02:26 — forked from soarez/ca.md
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.

@0xack13
0xack13 / nix-shell-shebang.md
Created January 26, 2024 00:45 — forked from travisbhartwell/nix-shell-shebang.md
nix-shell and Shebang Lines

NOTE: a more up-to-date version of this can be found on my blog

nix-shell and Shebang Lines

A few days ago, version 1.9 of the Nix package manager was released. From the release notes:

nix-shell can now be used as a #!-interpreter. This allows you to write scripts that dynamically fetch their own dependencies.

@0xack13
0xack13 / bash_flock.sh
Created January 25, 2024 05:07 — forked from jpclipffel/bash_flock.sh
Bash flock example
#!/bin/bash
#
# Bash `flock` example.
# Works on: Linux, BSD
# Doesn't work on: MacOS
# The file which represent the lock.
LOCKFILE="`basename $0`.lock"
# Timeout in seconds.
@0xack13
0xack13 / nix_inputs.md
Created January 20, 2024 21:36 — forked from CMCDragonkai/nix_inputs.md
Understanding Nix Inputs #nix

Understanding Nix Inputs

Every Nix derivation produces a Nix store output that has 3 things:

  • Executables
  • Libraries
  • Data

Executables are always exported using the PATH environment variable. This is pretty much automatic.

@0xack13
0xack13 / vagrant-vmware-tech-preview-apple-m1-pro.md
Created January 20, 2024 18:15 — forked from sbailliez/vagrant-vmware-tech-preview-apple-m1-pro.md
Vagrant and VMWare Tech Preview 21H1 on Apple M1 Pro

Vagrant and VMWare Tech Preview 21H1 on Apple M1 Pro

UPDATE November 20, 2022: VMWare Fusion 13

VMWare Fusion 13 is now released. Read Vagrant and VMWare Fusion 13 Player on Apple M1 Pro for the latest.

Summary

This document summarizes notes taken while to make the VMWare Tech preview work on Apple M1 Pro, it originated