Skip to content

Instantly share code, notes, and snippets.

@kadler
kadler / pase2rpg_ffi.py
Created March 1, 2017 04:40
Converting PASE structures to RPG structures with padding and alignment using Python CFFI
#
# The MIT License (MIT)
#
# Copyright (c) 2017 IBM Corp.
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
@tresf
tresf / zpl.js
Last active January 7, 2019 23:23
ZPL Label Sample
/*
* The re-use of the ZPL syntax and US Shipping Label
* - Provided as education example
* - Re-released by open source community under fair use
* - Fair use per US Copyright Act of 1976, 17 U.S.C. § 107
* The ZPL Printer Language
* - Copyright © 2014 ZIH Corp (zebra.com)
* The JavaScript syntax (minus ZPL markdown)
* Copyright © 2015 QZ Industries, LLC (qz.io)
* Licence: LGPL 2.1
@kbingham
kbingham / Makefile
Last active April 1, 2024 11:38
My Generic Makefile.Useful for creating a simple build for a single target from a set of c files.This could extended to provide support for other languages, or cross compilations.Let me know if you find this useful, or make any useful (generic) updates that are worth sharing.
# Kierans Generic Makefile
# www.kieranbingham.co.uk
# Default to build with multiple instances for speed
MAKEFLAGS =+ -j
# Beware, This will create this application
# binary based on the current directory name.
TARGET := $(shell basename `pwd`)
@andris9
andris9 / git-cache-meta.sh
Created March 5, 2012 13:15
git-cache-meta
#!/bin/sh -e
#git-cache-meta -- simple file meta data caching and applying.
#Simpler than etckeeper, metastore, setgitperms, etc.
#from http://www.kerneltrap.org/mailarchive/git/2009/1/9/4654694
#modified by n1k
# - save all files metadata not only from other users
# - save numeric uid and gid
# 2012-03-05 - added filetime, andris9