Skip to content

Instantly share code, notes, and snippets.

@Muffo
Muffo / CapsLock.ahk
Last active July 16, 2020 14:39
Enable shortcuts using CapsLock key
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
#Warn ; Enable warnings to assist with detecting common errors.
#SingleInstance Force ; Only one instance of the script running at a time
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
SetCapsLockState, AlwaysOff ; Disable caps-lock
@Muffo
Muffo / 0_reuse_code.js
Created December 9, 2015 14:57
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@Muffo
Muffo / codingstyle.md
Last active August 29, 2015 14:27
OpenSSL coding style - standard

This document describes the coding style for the OpenSSL project. It is is derived from the Linux kernel coding style, which can be found at: https://www.kernel.org/doc/Documentation/CodingStyle This guide is not distributed as part of OpenSSL itself. Since it is derived from the Linux Kernel Coding Style, it is distributed under the terms of the kernel license, available here: https://www.kernel.org/pub/linux/kernel/COPYING

Coding style is all about readability and maintainability using commonly available tools. OpenSSL coding style is simple. Avoid tricky expressions.

@Muffo
Muffo / web_cpu.py
Last active August 29, 2015 14:26
CPU usage with bottle.py and psutil
__author__ = 'muffo'
from bottle import route, response, run
from time import sleep
from psutil import cpu_percent
from json import dumps
import thread
cpu = None
@Muffo
Muffo / rendering.py
Last active August 29, 2015 13:56
Blender scene manipulation and rendering with Python
import math
import bpy
# Replace with the correct object name
object = bpy.data.objects["Surface"]
scene = bpy.data.scenes['Scene']
# Set the resolution of the output image (this does not work)
# scene.render.resolution_x = 1920