Skip to content

Instantly share code, notes, and snippets.

View pyriand3r's full-sized avatar

pyriand3r

  • Foo Bar Inc.
  • localhost
View GitHub Profile
@pyriand3r
pyriand3r / LayerManagementService.js
Created November 7, 2014 12:10
A layer management service class for draw2d touch ( http://www.draw2d.org ). It handles the movement of object in the stack moving them around. IMPORTANT: To work properly this class assumes, that all children of an object are positioned straight in front of that parent figure.
(function () {
/**
* @class pyriand3r.service.LayerManagementService
* Handles the arranging of the mapObjects on the canvas.
* Needed reimplementation because the method provided by draw2d is faulty (only toBack, toFront works, if you move
* an object between other objects labeltext will vanish).
* Reimplements the faulty behaviour by arranging the items only with toBack and toFront.
* All children of a figure are supposed to be placed in front of the parent figure.
*
@pyriand3r
pyriand3r / mp3join.py
Last active October 9, 2016 20:14
Concatinates all mp3-files of a folder in right order and repairs the header of the new file afterwords. Usage: -src <folderpath> = Folder with mp3s to concatinate / -dest <filepath> = Destination for concatinated new file ATTENTION: This script is written for use under linux.
#!/usr/bin/env python2.7
# -*- coding: iso-8859-1 -*-
''' Concatinate all mp3-files of a folder in right order
and repair header afterwords.
Usage: -s / --source <folderpath> = Folder with mp3s to concatinate.
-d / --destination <filepath> = Destination for concatinated files
ATTENTION: This script is written for use under linux (Ubuntu)
'''
import os
@pyriand3r
pyriand3r / mp3headrep.py
Last active October 9, 2016 20:17
Searches a folder recursively for mp3-files and repairs the header for every file using ffmpeg. A backup of the original file is made. If you don't want this, decomment line 38. Usage: -r <Rootpath> = Path to start the incremential search. ATTENTION: This script is written for use under linux
#!/usr/bin/env python2.7
# -*- coding: iso-8859-1 -*-
''' Search a folder recursively for mp3-files and repair
the header for every file. A backup of the original file
is made. If you don't want this, decomment line 38.
Usage: -r <Rootpath> = Path to start the incremential search.
ATTENTION: This script is written for use under linux
'''
@pyriand3r
pyriand3r / snippy.sh
Last active August 22, 2017 08:40 — forked from coderofsalvation/snippy.sh
modified version of snippy which features easier installation, follows symlinks, bashdown templates and automatic detection of cli vs window. This version also combines snippy.sh and snippy_1line.sh, making it possible to use both with just one script. Default the file ~/.snippy/oneliner is used, if you start snippy with the paramter `multi` the…
#!/usr/bin/env bash
# originally written by "mhwombat": https://bbs.archlinux.org/viewtopic.php?id=71938&p=2
# Based on "snippy" by "sessy"
# (https://bbs.archlinux.org/viewtopic.php?id=71938)
# and the modified version by "coderofsalvation"
# (https://gist.github.com/coderofsalvation/46549e3788ade2f3a938)
#
# You will also need "dmenu", "xsel" and "xdotool". Get them from your linux
# distro in the usual way.
@pyriand3r
pyriand3r / Ext5Container.js
Last active January 16, 2021 03:45
Container to integrate an Ext4/Ext5 Container into an Ext3.4 environment with use of the Ext4/Ext5 sandbox mode. This Class uses a Ext.Panel to host the Ext4-Container.
/**
* @class pyriand3r.util.Ext5Container
* This class provides a panel for an Ext5 application inside an Ext3.4 environment.
*
* @extends Ext.Panel
*/
pyriand3r.util.Ext5Container = Ext.extend(Ext.Panel, {
/**
* @constructor