Skip to content

Instantly share code, notes, and snippets.

Przemysław Pawełczyk przemoc

Block or report user

Report or block przemoc

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
@przemoc
przemoc / gist:a6a2bf05e112910be944
Created Aug 23, 2014
[Arch] List provisions with packages providing them
View gist:a6a2bf05e112910be944
# [Arch] List provisions with packages providing them
# pacman-based solution
pacman -Si \
| awk '/^$/{n=""}/^Name/{n=$3}/^Provides/{if($3!="None"){for(i=3;i<=NF;i++){if(t[$i]=="")t[$i]="";t[$i]=t[$i]" "n}}}END{for(p in t)printf("%44-s :%s\n",p,t[p])}' \
| sort | less
# expac-based solution (better)
expac -S "%n %P" \
| awk 'NF>1{for(i=2;i<=NF;i++){if(t[$i]=="")t[$i]="";t[$i]=t[$i]" "$1}}END{for(p in t)printf("%44-s :%s\n",p,t[p])}' \
@przemoc
przemoc / APK_Downgrade.md
Last active Sep 18, 2015
Android Application Downgrade
View APK_Downgrade.md
View numstr-test.c
#include <stdio.h>
#include <stdlib.h>
#define NUMBER 12345678901234567890
#define _Q(n) #n
#define Q(n) _Q(n)
#define ATOL(n) atol(Q(n))
#define SSCANF(n) ({ long val = 0; sscanf(Q(n), "%ld", &val); val; })
@przemoc
przemoc / p7zip-pwd-from-stdin.patch
Created Jan 10, 2011
Awful p7zip hack for reading passwords from stdin. Compatible w/ 9.04 and 9.13.
View p7zip-pwd-from-stdin.patch
--- p7zip_9.04.orig/CPP/7zip/UI/Console/Main.cpp 2009-06-27 16:18:14.000000000 +0200
+++ p7zip_9.04/CPP/7zip/UI/Console/Main.cpp 2011-01-10 01:25:36.000000000 +0100
@@ -48,6 +48,10 @@
#include "myPrivate.h"
#include "Windows/System.h"
+#include <iostream>
+
+#define MAX_PWD_SIZE_FROM_STDIN 1024
+
@przemoc
przemoc / gist:1105621
Created Jul 26, 2011
Blondie - Call me (Original 12 Mix) lyrics
View gist:1105621
Blondie - Call me (Original 12 Mix)
===================================
Colour me your colour baby, colour me your car
Colour me your colour darling, I know who you are
Come up off your colour chart
I know where you're coming from
Call me (call me) on the line
Call me, call me any, any time
@przemoc
przemoc / rc.lua
Created Feb 2, 2012
My trashy awesome/rc.lua file.
View rc.lua
-- Standard awesome library
require("awful")
require("awful.autofocus")
require("awful.rules")
-- Theme handling library
require("beautiful")
-- Notification library
require("naughty")
-- Load Debian menu entries
@przemoc
przemoc / almost-endless-history.sh
Created Feb 2, 2012
How not to lose your BASH history (and make it more compact)
View almost-endless-history.sh
# Add following lines to:
# - /etc/bash.bashrc
# - /etc/profile
export HISTSIZE=1000000
export HISTFILESIZE=$HISTSIZE
export HISTCONTROL=ignoredups
@przemoc
przemoc / festalon-Fix-CPUID-availability-test-for-x86_64.patch
Created Jun 25, 2012
Patch for festalon 0.5.5 to make it compilable on amd64 (Ryan C. Underwood's one is needlessly big and breaking DRY rule). // http://projects.raphnet.net/#festalon
View festalon-Fix-CPUID-availability-test-for-x86_64.patch
From: Przemyslaw Pawelczyk <przemoc@gmail.com>
Date: Sun, 8 May 2011 23:16:55 +0200
Subject: [PATCH] Fix CPUID availability test for x86_64.
Before you got following gcc/clang error in x86_64:
cputest.c: Assembler messages:
cputest.c:38: Error: suffix or operands invalid for `pop'
cputest.c:41: Error: suffix or operands invalid for `push'
cputest.c:44: Error: suffix or operands invalid for `pop'
@przemoc
przemoc / Fix-lowercase-sample-paths-in-.sfz.patch
Created Sep 11, 2012
Sonatina Symphonic Orchestra 1.0 - fix lowercase sample paths in .sfz files
View Fix-lowercase-sample-paths-in-.sfz.patch
From 4e7de246fa2db00112abca27c58922f2003af4c5 Mon Sep 17 00:00:00 2001
From: Przemyslaw Pawelczyk <przemoc@gmail.com>
Date: Tue, 11 Sep 2012 23:40:07 +0200
Subject: [PATCH] Fix lowercase sample paths in *.sfz.
---
Brass - Bass Trombone Solo.sfz | 28 ++++-----
Brass - Horn Solo.sfz | 26 ++++----
Brass - Tenor Trombone Solo.sfz | 22 +++----
Brass - Trumpet Solo.sfz | 26 ++++----
@przemoc
przemoc / tmux-Stop-searching-forward-at-the-end-of-the-buffer.patch
Created Feb 18, 2012
Patch for tmux 1.6: Stop searching forward at the end of the buffer.
View tmux-Stop-searching-forward-at-the-end-of-the-buffer.patch
From 6bccc3fc7362967ea7d4c296a22793f7f3a2c6d8 Mon Sep 17 00:00:00 2001
From: Przemyslaw Pawelczyk <przemoc@gmail.com>
Date: Sat, 18 Feb 2012 23:51:38 +0100
Subject: [PATCH] Stop searching forward at the end of the buffer.
Requested-by: Jacobo de Vera <devel@jacobodevera.com>
---
window-copy.c | 11 ++---------
1 files changed, 2 insertions(+), 9 deletions(-)
You can’t perform that action at this time.