Skip to content

Instantly share code, notes, and snippets.

View Cynnexis's full-sized avatar
:octocat:

Valentin Berger Cynnexis

:octocat:
View GitHub Profile
@Cynnexis
Cynnexis / $Starship ZSH Configuration.md
Last active July 22, 2025 08:55
Starship ZSH Configuration

Starship ZSH Configuration

Get started

Ubuntu

To install ZSH and Cynnexis' configuration, please follow these instructions:

  1. Install [FiraCode Nerd Font][firacode].
  2. Install [ZSH][zsh]:
@Cynnexis
Cynnexis / $ Bash Magic Spellbook.md
Last active January 21, 2026 13:45
✨ Bash Magic Spellbook
@Cynnexis
Cynnexis / $TMUX Configuration File.md
Last active April 20, 2023 09:38
TMUX configuration file

TMUX Configuration File

To download the default TMUX configuration file, please use the following commands:

cd
curl -fsSL "https://gist.githubusercontent.com/Cynnexis/055949bac3d3f6850747e4928a38d52e/raw/.tmux.conf" -o ~/.tmux.conf
@Cynnexis
Cynnexis / Install-apk.md
Created August 3, 2021 15:42
Install APK on android with ADB

APK Installation with adb

Tutorial

Make sure that your phone has USB debugging enabled.

Connect your phone to your computer, and make sure that the OS identified the device with:

adb devices -l
@Cynnexis
Cynnexis / $pre-commit dartfmt.md
Last active December 10, 2020 20:40
Git hook pre-commit to run dartfmt on Dart code

pre-commit dartfmt

Installation

One-time installation

Put the pre-commit file under .git/hooks/ of your Dart and/or Flutter project, and make sure it is well-formatted (LF) and it has the correct permissions.

The following steps will get you the pre-commit hook in your project:

@Cynnexis
Cynnexis / $ZSH Configuration.md
Last active July 4, 2025 09:16
ZSH configuration

ZSH Configuration

Warning

This configuration is deprecated, please see Starship ZSH Configuration.

Get started

To install ZSH and Cynnexis' configuration, please launch the following command:

@Cynnexis
Cynnexis / $post-commit dos2unix.md
Last active August 4, 2021 14:25
Git post-commit hook for making Shell script in project executable. This is for Windows users using git.

post-commit dos2unix

Put the post-commit file under .git/hooks/ of your project, and make sure it is well-formatted (LF) and it has the correct permissions.

If you want to automate its creation from a Makefile, use the following rule:

.PHONY: help configure-git configure

# [...]
@Cynnexis
Cynnexis / $pre-commit yapf.md
Last active April 11, 2022 08:34
Git hook pre-commit to run YAPF on Python code

pre-commit yapf

Installation

One-time installation

Put the pre-commit file under .git/hooks/ of your Python project, and make sure it is well-formatted (LF) and it has the correct permissions.

The following steps will get you the pre-commit hook in your project:

@Cynnexis
Cynnexis / find-best-CTAN-mirror.sh
Created August 28, 2020 10:45
Find the best CTAN mirror to download TeX Live according to the ping.
#!/bin/bash
mirrors=$(curl -sSL http://dante.ctan.org/mirmon/ | grep -oE "<TD ALIGN=RIGHT><A HREF=\"[^\"]+" | cut -d\" -f2)
all_ctan_mirrors=($mirrors)
re_number='^[0-9.]+$'
declare -a all_ping=()
declare -a all_url=()
i=0
for ctan_mirror in ${all_ctan_mirrors[@]}; do
results=$(ping -c 1 -w 1 -W 1 $(echo $ctan_mirror | sed -re 's/^[a-zA-Z0-9]+\:\/\/([^\/]+).+$/\1/'))
avg=$(echo $results | sed -re 's/^.*=\s*[0-9.]+\/([0-9.]+).*$/\1/')
@Cynnexis
Cynnexis / .block
Last active December 12, 2019 10:09
TP5 - Interaction
license: mit