Skip to content

Instantly share code, notes, and snippets.

View Ditti4's full-sized avatar

Rico Dittrich Ditti4

View GitHub Profile
@Ditti4
Ditti4 / skype-always-on-top.lua
Created September 4, 2018 17:43
Simple devilspie2 script to enable the "Always on top" property on the new Skype's (version 8) mini video popup window. Place in .config/devilspie2/
-- The only situation where Skype will spawn a new window is during a call when
-- another application is brought to the foreground. This new window will then
-- be called "Skype", just like the main window, but will not be resizable.
if (get_window_name() == "Skype" and
get_window_role() == "browser-window" and
not string.find(get_window_property("_NET_WM_ALLOWED_ACTIONS"), "RESIZE")) then
make_always_on_top()
end
@Ditti4
Ditti4 / ebpe-skip-logout-warning.user.js
Last active October 13, 2017 17:05
Logout-Hinweis-Skipper für eBanking Private Edition
// ==UserScript==
// @name eBPE-Logout-Hinweis-Skipper
// @namespace https://gist.github.com/Ditti4
// @version 0.1
// @description Überspringt in der Software "eBanking Private Edition" (eingesetzt unter anderem von der Volksbank und Wüstenrot) den Hinweis über eine "vergessene" Abmeldung.
// @author Ditti4
// @match https://*.de/banking-private/portal?token=*
// @grant none
// ==/UserScript==
@Ditti4
Ditti4 / steamstatus.php
Last active December 21, 2015 17:38
Little functions to get the Steam server status (and echo it, depending on the function you'd like to use) from http://issteamdown.com. Supposed to be used in chat bots and similar things.
<?php
function echoSteamStatus()
{
echo (strpos(file_get_contents('http://issteamdown.com'), 'Steam is down') ? 'Steam is down.' : 'Steam is up.').' Source: http://issteamdown.com';
}
function getSteamStauts()
{
//true means it's up, false means it's down
@Ditti4
Ditti4 / mysqlbackup.sh
Created June 26, 2013 07:00
Just a simple script to backup all databases of a MySQL/MariaDB server and send it with mutt to an specified mail address.
#!/bin/bash
# This file is licensed under the DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE Version 2, December 2004
# See http://www.wtfpl.net/txt/copying/
password=''
mail=''
date=$(date +%m_%d_%Y%H_%M_%S)
mysqldump --add-drop-database --flush-privileges --all-databases -u root -p${password} > /backup/sql/${date}.sql

Keybase proof

I hereby claim:

  • I am Ditti4 on github.
  • I am ricod1996 (https://keybase.io/ricod1996) on keybase.
  • I have a public key whose fingerprint is EE48 71F4 2BFB D35C ACDB 005B 8B81 C4D7 D810 C877

To claim this, I am signing this object: