Skip to content

Instantly share code, notes, and snippets.

Avatar

ePirat ePirat

View GitHub Profile
@ePirat
ePirat / wwdc.md
Last active Dec 11, 2021
WWDC Resources
View wwdc.md

WWDC 2014

  • 704: [Building Apps for Enterprise and Education][704] ([HD][704_HD], [SD][704_SD], [Slides][704_Slides], [ASCII][704_ASCII])
  • 236: [Building Interruptible and Responsive Interactions][236] ([HD][236_HD], [SD][236_SD], [Slides][236_Slides], [ASCII][236_ASCII])
  • 416: [Building Modern Frameworks][416] ([HD][416_HD], [SD][416_SD], [Slides][416_Slides], [ASCII][416_ASCII])
  • 508: [Camera Capture: Manual Controls][508] ([HD][508_HD], [SD][508_SD], [Slides][508_Slides], [ASCII][508_ASCII])
  • 415: [Continuous Integration with Xcode 6][415] ([HD][415_HD], [SD][415_SD], [Slides][415_Slides], [ASCII][415_ASCII])
  • 224: [Core iOS Application Architectural Patterns][224] ([HD][224_HD], [SD][224_SD], [Slides][224_Slides], [ASCII][224_ASCII])
  • 509: [Creating 3D Interactive Content with WebGL][509] ([HD][509_HD], [SD][509_SD], [Slides][509_Slides], [ASCII][509_ASCII])
  • 221: [Creating Custom iOS User Interfaces][221] ([HD][221_HD], [SD][221_SD], [Slides][221_Slides], [ASCII
@ePirat
ePirat / pre-push.sh
Created Nov 4, 2019
Push check git hook
View pre-push.sh
#!/bin/bash
protected_remote='origin'
protected_branch='master'
current_remote="$1"
current_branch=$(git symbolic-ref HEAD | sed -e 's,.*/\(.*\),\1,')
if [ $protected_remote = $current_remote ]
then
read -p "You're about to push to $current_remote, is that what you intended? [y|n]" -n 1 -r < /dev/tty
@ePirat
ePirat / main.m
Last active Nov 6, 2018
MoltenPlacebo
View main.m
//
// main.m
// MoltenPlacebo
//
// This proof-of-concept is extremely naive. This is probably not
// what you should be doing for a real program!
//
// Created by Marvin Scholz on 05.11.18.
// Based on sdl.c
//
View pre-push.sh
#!/bin/bash
# Git hook to ask before pushing to specific branch or remote
# Adapted from https://blog.ghost.org/prevent-master-push/
# Put this in .git/hooks/pre-push and do not forget to make it executable
protected_remote='origin'
protected_branch='master'
current_remote="$1"
View VLCWinCompile.md

Compile for Windows (64bit)

Pull the VideoLAN Docker container and run it in interactive mode with bash:

(The -v ~/docker:/root/shared maps /root/shared in the container to ~/docker on your machine to easily obtain the build results, so make sure ~/docker exists.)

docker pull registry.videolan.org:5000/vlc-debian-win64
docker run -v ~/docker:/root/shared -it registry.videolan.org:5000/vlc-debian-win64 /bin/bash
View VLCQtCompileMacOS.md

Compile VLC with Qt Intf on macOS

First, export the QTDIR variable, it should contain the path to your Qt 5 directory:

QTDIR="/Applications/Qt/5.9.3/clang_64"

Now, configure VLC:

@ePirat
ePirat / article.md
Last active Feb 2, 2017
Häusliche Gewalt in „50 Shades of Grey“
View article.md

Häusliche Gewalt in „50 Shades of Grey“

Dies ist eine Übersetzung des Artikels „Domestic Violence in 50 Shades of Grey

Am 12. Februar eröffnet Karen Ingala Smith in Zussamenarbeit mit Women's Aid „The Femicide Census: Profiles of Women Killed By Men“ auf einer Konferenz in London. Währenddessen finden sich weniger als 4 km entfernt die Fans zur UK Premiere von Fifty Shades of Grey zusammen, der Film-Adaption des sehr erfolgreichen Romans von EL James. Die beiden Veranstaltungen scheinen nichts miteinander gemeinsam. Doch für Betroffene, die mit häusliche Gewalt zu tun oder diese erlebt haben, sind die beiden Verstanltungen eine verstörende Gegenüberstellung von häuslicher Gewalt mit einer fiktionalen, romantisierten Version dieser, welche von der Gesellschaft akzeptiert wird.

@ePirat
ePirat / INSTALL.md
Last active Aug 21, 2022
Cross-compile libaacs for Windows (64bit)
View INSTALL.md

Cross-compile libaacs for Windows (64bit)

For this guide the ubuntu:yakkety Docker image was used.

Install the cross-compile toolchain

apt-get install mingw-w64-tools gcc-mingw-w64-x86-64 g++-mingw-w64-x86-64 wget gettext bison flex
@ePirat
ePirat / help.md
Created Feb 27, 2015
Buy something on Steam while in another Country
View help.md

Recently I had to buy something on Steam while in another Country. Turns out it was impossible, because the country information of my Payment method differs from the Country selected based on my IP Address. So I contacted the Steam support, and they advised me to pass a special Argument to the URL when visiting the Steam Store through a Webbrowser:

http://store.steampowered.com/?cc=<countrycode>

Replace <countrycode> with a 2 character country code, for example:

http://store.steampowered.com/?cc=DE

@ePirat
ePirat / parse_playlist.php
Last active Aug 29, 2015
Ice PlaylistParser
View parse_playlist.php
#!/usr/bin/php
<?php
if (php_sapi_name() == "cli") {
// If this is executed via CLI, parse options and stuff
// Helper
function report_error($e) {
// Get the current script name
$our_name = (($v =strrchr(__FILE__, DIRECTORY_SEPARATOR)) == FALSE)
? __FILE__