Skip to content

Instantly share code, notes, and snippets.

@vhr
vhr / android-studio.desktop
Created October 8, 2017 11:32
Ubuntu application launcher icon for Android Studio
[Desktop Entry]
Version=1.0
Type=Application
Terminal=false
Icon=/usr/local/android-studio/bin/studio.png
Exec=sh /usr/local/android-studio/bin/studio.sh
Name=Android Studio
@vhr
vhr / mkvideo.sh
Created July 9, 2017 16:39 — forked from pklaus/mkvideo.sh
A Bash script to create a video from series of JPEG images. Ideal to create videos from timed sequences shot with a tripod. It uses mogrify (from imagemagick) to resize the images to FullHD and it then uses ffmpeg to create a video from the sequence of images.
#!/bin/bash
# This is a script to create a video from series of JPEG images
# Call it in a folder full of JPEGs that you want to turn into a video.
# Written on 2013-01-08 by Philipp Klaus <philipp.l.klaus →AT→ web.de>.
# Check <https://gist.github.com/4572552> for newer versions.
# Resources
# * http://www.itforeveryone.co.uk/image-to-video.html
# * http://spielwiese.la-evento.com/hokuspokus/index.html
@vhr
vhr / docker-compose.yml
Created April 28, 2017 15:11
Docker compose MySQL and phpMyAdmin containers
version: '2'
services:
mysql:
image: mysql:5
volumes:
- ./mysql:/var/lib/mysql
restart: always
ports:
- "3306:3306"
@vhr
vhr / BoyerMoore.php
Created October 20, 2015 19:26 — forked from nticaric/BoyerMoore.php
Boyer–Moore algorithm implementation in PHP
<?php
/**
* Returns the index of the first occurrence of the
* specified substring. If it's not found return -1.
*
* @param string
* @param string
* @return int
*/