Skip to content

Instantly share code, notes, and snippets.

@dnozay
dnozay / block-beta.md
Last active October 17, 2024 11:23
Mermaid cheatsheet
@dnozay
dnozay / my-pagerduty-incidents.py
Created October 19, 2022 21:12
Very small script to list my pagerduty incidents using pdpyras
#!/usr/bin/env python
# Very small script to list my pagerduty incidents,
# useful to give a quick report about my oncall shift.
#
# https://github.com/PagerDuty/pdpyras
import os
import pdpyras
import dateutil.parser
import pytz
### Keybase proof
I hereby claim:
* I am dnozay on github.
* I am dnozay (https://keybase.io/dnozay) on keybase.
* I have a public key ASDwG1XeASnSt-x2dXIhT_fly2zyhqMcgVbytdebmg0TGgo
To claim this, I am signing this object:
@dnozay
dnozay / spy-variable.py
Created January 4, 2021 18:32
spy on variable in python
# https://stackoverflow.com/a/34620310/1733117
import sys
import dis
import random
watchme = 123
def foo():
global watchme
@dnozay
dnozay / osx-fix-dock.sh
Created August 5, 2020 15:59
Fix bug where osx dock still shows when going fullscreen
#!/bin/bash
# https://apple.stackexchange.com/questions/33600/
# Fix bug where osx dock still shows when going fullscreen
defaults write com.apple.dock autohide-delay -float 0
defaults write com.apple.dock autohide-time-modifier -float 0.14
killall Dock
@dnozay
dnozay / README.md
Last active May 30, 2020 21:16
pdf-diff
python3 -m venv env
source env/bin/activate
pip install -r requirements.txt
pdf-diff lorem-ipsum1.pdf lorem-ipsum2.pdf > diff.png
@dnozay
dnozay / swimlanes.dot
Created May 20, 2020 21:07
dot examples
digraph cloud_platform {
rankdir=LR
splines=ortho
subgraph cluster_1 {
11 -> 12 -> 13 -> 14
}
subgraph cluster_2 {
21 -> 22 -> 23 -> 24
@dnozay
dnozay / LICENSE
Created April 10, 2020 16:00
Find projects to fix in github based on matches in semaphore 2.0 secrets
The MIT License
Copyright (c) 2020, Damien Nozay
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
// exercise issue.
// https://github.com/semaphoreci/agent/pull/77
package main
import (
"fmt"
petname "github.com/dustinkirkland/golang-petname"
)
@dnozay
dnozay / FAQ.md
Created September 20, 2019 16:44
common problems with VSCode

Quick FAQ for issues I had with VSCode.

Best way to use this document is to ctrl-f / cmd-f.

vscode: go to symbol command not working (cmd-t)

Error:

/Library/Developer/CommandLineTools/usr/bin/ctags: illegal option -- -
usage: ctags [-BFadtuwvx] [-f tagsfile] file ...