Skip to content

Instantly share code, notes, and snippets.

@Tblue
Tblue / setup.py
Created Jan 8, 2016
setuptools_scm: Include not only the date, but also the time in the "local" part of the version.
View setup.py
from setuptools import setup
setup(
# ...
use_scm_version={
# Include not only the date, but also the time in the "local" part of the version.
# Based on: https://git.io/vuPTX
"local_scheme": lambda version: \
version.format_choice("", "+d{time:%Y%m%d.h%H%M%S}") if version.exact else \
@Tblue
Tblue / svn-clean.py
Last active Jan 16, 2016
Lists and optionally removes untracked and/or ignored files in a SVN working copy.
View svn-clean.py
#!/usr/bin/env python3
#
# List and optionally remove untracked and/or ignored files in a SVN working copy.
#
# Copyright (c) 2015-2016, Tilman Blumenbach
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without modification,
# are permitted provided that the following conditions are met:
#
@Tblue
Tblue / git-split.sh
Created Aug 30, 2015
Git subtree splitter
View git-split.sh
#!/bin/sh
#
# Git subtree splitter.
#
# Copyright (c) 2014-2015, Tilman Blumenbach
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
@Tblue
Tblue / mozlz4a.py
Last active Jul 29, 2022
MozLz4a compression/decompression utility
View mozlz4a.py
#!/usr/bin/env python3
# vim: sw=4 ts=4 et tw=100 cc=+1
#
####################################################################################################
# DESCRIPTION #
####################################################################################################
#
# Decompressor/compressor for files in Mozilla's "mozLz4" format. Firefox uses this file format to
# compress e. g. bookmark backups (*.jsonlz4).
#