Skip to content

Instantly share code, notes, and snippets.

View dee-me-tree-or-love's full-sized avatar
☮️
🌐

Mitja O dee-me-tree-or-love

☮️
🌐
View GitHub Profile
@dee-me-tree-or-love
dee-me-tree-or-love / twemojis-example.tex
Last active January 24, 2025 14:52
💡 Using `twemojis` for emoticons on `pdfLaTex` engine.
% twemojis package is maintained at CTAN here:
% - https://ctan.org/pkg/twemojis?lang=en
% see exammple below:
\documentclass{article}
\usepackage{hyperref}
\usepackage{twemojis}
\begin{document}
@dee-me-tree-or-love
dee-me-tree-or-love / todos.tex
Last active September 9, 2025 12:56
📝 Simple todo's and author utilities for annotating LaTeX
% Creates a basic in-text todo note with a margin callout mark.
%
% Arguments:
% (required) - todo text
% (optional) - mark symbol, default: $\odot$, provide an empty value to skip.
%
% Examples:
% \todoM{do the dishes before starting the next paragraph}
% \todoM[$\star$]{mention this later, mark with a star}
% \todoM[]{recall this, even without a margin mark}
@dee-me-tree-or-love
dee-me-tree-or-love / cricket.scm
Last active October 18, 2024 07:45
🦗 Simple stack based programming made in Guile Scheme.
; import stuff for profiling
; (use-modules (ice-9 time))
; use streams for efficiency soon
; (use-modules (ice-9 streams))
(use-modules (srfi srfi-1))
;----------
; parsing
;----------
@dee-me-tree-or-love
dee-me-tree-or-love / setup-git.sh
Last active December 13, 2024 08:26
My git cli configuration helper: defaults and aliases
# some defaults:
# git config --global pull.rebase false # setup the git pull strategy as merge
git config --global pull.rebase true # setup the git pull strategy as rebase
git config --global init.defaultBranch main # change the default git init branch name to `main`
git config --global core.editor "vim" # make sure Vim is used as default editor
# personal flavor aliases:
git config --global alias.ck checkout
git config --global alias.br branch
git config --global alias.aa "add --all"
@dee-me-tree-or-love
dee-me-tree-or-love / multiple_ssh_setting.md
Created June 4, 2021 07:19 — forked from jexchan/multiple_ssh_setting.md
Multiple SSH keys for different github accounts

Multiple SSH Keys settings for different github account

create different public key

create different ssh key according the article Mac Set-Up Git

$ ssh-keygen -t rsa -C "your_email@youremail.com"
@dee-me-tree-or-love
dee-me-tree-or-love / fetch-cleanup-gone-remote-git-branches.sh
Last active May 28, 2021 13:53
Check the active branches on remote, clean up the local branches that are no longer existing on remote
#!/bin/sh
################################################
# cleanup gone remote branches from local list #
################################################
git fetch -pP \ # fetch and prune gone remotes and remote tags
&& git branch -vv \ # display information about all branches
| grep "\: gone\]" \ # find all the branches with "gone" remotes
| awk '{print $1}' \ # get the branch names
@dee-me-tree-or-love
dee-me-tree-or-love / scared_machine.c
Last active December 13, 2024 08:28
A small mock example of a scared machine code that can be ported to Arduino 🐡
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
#include <unistd.h>
const int NOISE_THRESHOLD = 7;
const int NOISE_UPPER = 10;
int main_move_counter = 0;
int max_move_counter = 0;
@dee-me-tree-or-love
dee-me-tree-or-love / pop_o_time_o.py
Last active December 13, 2024 08:29
Sends out a current time notification on a Linux based platform (tested on Fedora) ⌚️
import datetime
import subprocess
def send_message(message):
subprocess.Popen(['notify-send', str(message)])
return
def print_message(message):
print(str(message))
return
@dee-me-tree-or-love
dee-me-tree-or-love / tasks.py
Last active May 2, 2019 22:23
Docker tasks with invoke
from invoke import task
def announce_action(action_message):
"""Prints the action message to the stdout
Args:
action_message (str): the message to be announced
"""
print("{}\n...\n".format(action_message))
@dee-me-tree-or-love
dee-me-tree-or-love / .gitignore-python
Created May 2, 2019 09:01
.gitignore file for Python projects
# Python
# IDEs
.vscode/
.idea/
.idea_modules/
*.tmlanguage.cache
*.tmPreferences.cache
*.stTheme.cache