Skip to content

Instantly share code, notes, and snippets.

View hypernova7's full-sized avatar
🦀
Rust is 💪😉

Eddy Otsutsuki hypernova7

🦀
Rust is 💪😉
  • www
  • México
  • 00:46 (UTC -06:00)
View GitHub Profile
#################################
# Animations #
#################################
animations = true;
# Global animation parameters
animation-stiffness-in-tag = 150; # Smoother opening
animation-stiffness-tag-change = 80; # Smoother tag transitions
animation-window-mass = 0.4; # Slightly heavier for more "weighty" feel
@meow464
meow464 / gtk_list_box_row_scrollable.py
Last active November 22, 2025 21:47
Gtk.ListBox programmatically scroll to Gtk.ListBoxRow
# Copyright (c) 2021 CEO of Programming <ceo_of_email@protonmail.com>
# GPG Fingerprint: 0D0B9511F2B562DC59A2BB3538A6B4C850773FAC
# All rights reserved.
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
# 1. Redistributions of source code must retain the above copyright notice,
# this list of conditions and the following disclaimer.
@siwalikm
siwalikm / aes-256-cbc.js
Last active August 11, 2025 11:49
AES-256-CBC implementation in nodeJS with built-in Crypto library
'use strict';
const crypto = require('crypto');
const ENC_KEY = "bf3c199c2470cb477d907b1e0917c17b"; // set random encryption key
const IV = "5183666c72eec9e4"; // set random initialisation vector
// ENC_KEY and IV can be generated as crypto.randomBytes(32).toString('hex');
const phrase = "who let the dogs out";
var encrypt = ((val) => {
@KurtJacobson
KurtJacobson / transparent_window.py
Last active October 28, 2025 17:32
Transparent Window in Gtk+ 3, python
#!/usr/bin/env python
# Copyright (c) 2017 Kurt Jacobson
# License: https://kcj.mit-license.org/@2017
import cairo
import gi
gi.require_version('Gtk', '3.0')
gi.require_version('Gdk', '3.0')
@Integralist
Integralist / Python TCP Client Example.py
Created September 18, 2016 15:07
Python TCP Client Server Example
import socket
hostname, sld, tld, port = 'www', 'integralist', 'co.uk', 80
target = '{}.{}.{}'.format(hostname, sld, tld)
# create an ipv4 (AF_INET) socket object using the tcp protocol (SOCK_STREAM)
client = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
# connect the client
# client.connect((target, port))
@zollinger
zollinger / getcolor.py
Last active November 6, 2024 08:18
Simple way to get dominant colors from an image in Python
from PIL import Image, ImageDraw
import argparse
import sys
def get_colors(image_file, numcolors=10, resize=150):
# Resize image to speed up processing
img = Image.open(image_file)
img = img.copy()
img.thumbnail((resize, resize))