Skip to content

Instantly share code, notes, and snippets.

View sleeyax's full-sized avatar

Sleeyax sleeyax

View GitHub Profile

Conventional Commit Messages

See how a minor change to your commit message style can make a difference.

Tip

Have a look at git-conventional-commits , a CLI util to ensure these conventions, determine version and generate changelogs

Commit Message Formats

Default

@sleeyax
sleeyax / cbr-to-cbz.py
Created July 16, 2024 08:43
Convert CBR (supports media type `application/x-rar-compressed; version=5`) to CBZ
import os
import shutil
import patoolib
input_directory = '/path/to/input/direcotry'
# List of filenames
filenames = [
'01 - Example comic 1 (2020)',
@sleeyax
sleeyax / packet_capture_import_custom_certificate_instructions.md
Created March 31, 2024 14:54
Packet Capture Android app how to import custom certificate

Step by step guide on how to generate and import a custom certificate into the Packet Capture Android app. Useful when the "generate certificate" feature doens't work for you either.

  1. Generate certificate using openssl on your (linux) computer. You can also do this right on your Android device with a terminal/Termux/openssl app.
    • openssl req -x509 -newkey rsa:4096 -keyout key-private.pem -out key-public.pem -days 3650
  2. Export certificate to PKCS12 format
    • openssl pkcs12 -export -out keyBundle.p12 -inkey key-private.pem -in key-public.pem -name alias -legacy
    • Choose any password and alias name, make sure you remember it for the next few steps.
  3. Transfer keyBundle.p12 and key-public.pem to the android device
    • e.g. adb push keyBundle.p12 /sdcard/Download etc.
  4. In android settings, go to Biometrics and Security (note I have a Samsung device, it might be different for you) > Other Security Settings >
@sleeyax
sleeyax / beautfiful-markown-snippets.md
Created January 28, 2024 01:06
Beautfiful markown snippets

Alerts

Alerts are an extension of Markdown used to emphasize critical information. On GitHub, they are displayed with distinctive colors and icons to indicate the importance of the content.

An example of all five types:

Note

Highlights information that users should take into account, even when skimming.

Tip

Optional information to help a user be more successful.

@sleeyax
sleeyax / checkout_older_chromium_version.txt
Created October 15, 2023 21:17
Checkout older chromium version
mkdir ~/chromium && cd ~/chromium
fetch --nohooks --no-history chromium
cd src
git fetch https://chromium.googlesource.com/chromium/src.git +refs/tags/118.0.5993.71:chromium_118.0.5993.71 --depth 1
git checkout tags/118.0.5993.71
gclient sync -D --force --reset --with_branch_heads
@sleeyax
sleeyax / stremio_discord_integration.md
Last active September 24, 2024 00:57
Stremio and Discord integration guide

Stremio and Discord integration

2023_07_08_15_03_33

Show your favorite movies, series and channels from Stremio to your friends on Discord!

⚡ Quick start

@sleeyax
sleeyax / README.txt
Created May 18, 2023 14:43
Skylanders Figures
Source: https://github.com/mandar1jn/portfolio/blob/master/src/assets/skylanders/figures.json
@sleeyax
sleeyax / reinstall-grub.sh
Last active February 20, 2023 09:59 — forked from ppartarr/reinstall-grub.sh
Reinstall grub after Windows updates (Arch & Windows dual boot)
#!/usr/bin/env bash
# list partitions
lsblk -f
# mount the root partition
mount /dev/nvme1n1p2 /mnt
# mount the boot partition
mount /dev/nvme1n1p1 /mnt/boot

Keybase proof

I hereby claim:

  • I am sleeyax on github.
  • I am sleeyax (https://keybase.io/sleeyax) on keybase.
  • I have a public key whose fingerprint is E8DA EC0C 346D 354A CFA0 94C5 EEA3 74DC A7CB EE6B

To claim this, I am signing this object:

@sleeyax
sleeyax / lcs.sh
Last active July 9, 2022 23:16
Simple shell script to convert text to lowercase (GNU/linux)
#!/usr/bin/sh
if ! [ -z "$1" ]
then
echo "$1" | tr '[:upper:]' '[:lower:]'
else
echo "Usage: lcs <text>"
echo 'Example: lcs "Foo Bar BAZ"'
echo "Output: foo bar baz"
fi