Skip to content

Instantly share code, notes, and snippets.

View madkoding's full-sized avatar
🧩
Back to your reality

madKoding madkoding

🧩
Back to your reality
View GitHub Profile
@madkoding
madkoding / removeroms.md
Created May 21, 2024 23:04
Python Script for Removing Duplicate Files (roms) Based on Levenshtein Distance

Python Script for Removing Duplicate Files (roms) Based on Levenshtein Distance

This Python script identifies and removes duplicate files in a specified directory based on the Levenshtein distance between their names. Only the first file in each group of similar files is kept, and the rest are deleted. The script excludes directories and only processes files.

Requirements

  • Python 3.x
  • colorama library for colored console output

Installation

@madkoding
madkoding / instalar-proxmox-gpu-passthrough.md
Created December 28, 2023 17:17
Instalación de Proxmox y Configuración de Passthrough de GPU para una Máquina Virtual de Windows

Instalación de Proxmox y Configuración de Passthrough de GPU para una Máquina Virtual de Windows

Paso 1: Instalación de Proxmox

  1. Descargar Proxmox: Ve a la página oficial de Proxmox y descarga la última ISO de Proxmox VE.

  2. Crear un medio de instalación: Usa un programa como Rufus para quemar la ISO en un USB.

  3. Instalación: Arranca tu servidor desde el USB y sigue las instrucciones en pantalla para instalar Proxmox.

@madkoding
madkoding / lastfm-spotify.md
Last active December 15, 2023 23:27
Como crear una pagina que muestre lo que estas escuchando en spotify

Como crear una pagina que muestre lo que estas escuchando en spotify

HTML

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
@madkoding
madkoding / jwt-rs256-nest.md
Last active December 15, 2023 14:23
Autenticación de JWT con firma RS256 en Nest

Configuración Correcta de JWT en NestJS con firma RS256

Este resumen proporciona una guía sobre cómo configurar correctamente JWT en NestJS, especialmente para el uso de algoritmos RSA como RS256.

Problema Común

El problema suele estar en la configuración incorrecta del JwtModule y la instancia de JwtStrategy. Es crucial especificar los algoritmos utilizados para firmar y verificar los tokens, junto con las claves correspondientes.

Verificación del Algoritmo del Token

@madkoding
madkoding / get-playstore-in-chormeos-flex.md
Last active May 15, 2024 03:58
Get PlayStore in ChromeOS Flex

Get PlayStore in ChromeOS Flex

Basic Requirements

  • x86_64 based computer with UEFI boot support.
  • Administrative privileges on the device.
  • A basic understanding of the Linux terminal.

CPU Compatibility

  • Intel CPUs from Haswell (4th Gen) / Celeron CPUs from Braswell.
  • AMD Ryzen.
@madkoding
madkoding / playstore-in-chromeos-flex-ESP.md
Last active April 25, 2024 05:29
Obtener PlayStore en ChromeOS Flex

Obtener PlayStore en ChromeOS Flex

Requisitos Básicos

  • Computadora basada en x86_64 con soporte de arranque UEFI.
  • Privilegios administrativos en el dispositivo.
  • Un entendimiento básico del terminal de Linux.

Compatibilidad de CPU

  • CPUs Intel desde Haswell (4ta Gen) / CPUs Celeron desde Braswell.
  • AMD Ryzen.
@madkoding
madkoding / fix-hyperv-udp-packet-loss.md
Last active December 10, 2023 20:56
Fix Hyper-V UDP packet loss in linux (Minecraft Bedrock server issues)

Persistent Disabling of TCP/UDP Checksum Offloading in a Virtual Machine

This guide provides a method to persistently disable TCP/UDP checksum offloading on eth0 in a virtual machine, ensuring the changes remain effective even after a reboot. (Usually to fix issues for Minecraft Bedrock Server)

Steps

1. Install ethtool

First, ensure that ethtool is installed. If it's not installed, you can install it using the following command:

@madkoding
madkoding / semantic-emoji-commit-messages.md
Last active July 21, 2021 21:50
Semantic Emoji Commit Messages for Git

Semantic Emoji Commit Messages

Helps to keep a better order and keep easy to understand every change in the git log history Emojis looks nice, and i chose the most easy to remember ones

Syntax

type [scope] subject
emoji section (optional) Summary (present tense)
@madkoding
madkoding / install-zsh-powerline-ubuntu.md
Last active December 10, 2023 20:32
Install ZSH and Oh-my-zsh (powerline like) in Ubuntu

Install ZSH and Oh-my-zsh (Powerline-like) in Ubuntu

Introduction

This guide provides instructions on how to install ZSH and Oh-my-zsh with a Powerline-like theme in Ubuntu

Instructions

1. Install Powerline Fonts

  • First, install Powerline fonts. You can find them here.
@madkoding
madkoding / anticors-proxy-server.js
Last active December 10, 2023 20:35
Create proxy server for CORS issues (http-proxy package)
// Import required modules
const http = require("http");
const httpProxy = require("http-proxy");
// API target and proxy port configuration
const API_TARGET = 'https://pokeapi.co/api/v2/';
const PROXY_PORT = 8080;
// Create a proxy server
const proxy = httpProxy.createProxyServer({});