Skip to content

Instantly share code, notes, and snippets.

Elric Milon whirm

Block or report user

Report or block whirm

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
from M2Crypto import EVP
from binascii import hexlify, unhexlify
def long_to_bytes(val, nrbytes=0):
hex_val = '%x' % abs(val)
if nrbytes:
padding = '0' * ((abs(nrbytes) * 2) - len(hex_val))
padding = ''
result = unhexlify(padding + hex_val)[::-1]
whirm / autopep8.el
Created Jul 31, 2013
Clean up python code from Emacs.
View autopep8.el
;;; autopep8.el -- clean up python code
; based on js-beautify.el -
; Rescued from
; put this in your emacs init:
; (add-to-list 'load-path "~/dir/containing/autopep8/")
; (require 'autopep8)
; to use:
You can’t perform that action at this time.