Skip to content

Instantly share code, notes, and snippets.

View Dramacydal's full-sized avatar
🔫
Just smile like a rifle

Dramacydal

🔫
Just smile like a rifle
View GitHub Profile
#!/bin/bash
curl telnet://127.0.0.1:11211 <<EOF
flush_all
quit
EOF
@Dramacydal
Dramacydal / scene-window-pos-updater.py
Created January 1, 2023 19:41
obs script to update scene items positions with actual window positions
import obspython as obs
import re
import win32gui
import win32api
# Global variables holding the values of data settings / properties
update_frequency = 50 # Update frequency in msec
# Global animation activity flag
is_active = True
@Dramacydal
Dramacydal / mysql_splitdump.sh
Created September 17, 2020 12:05 — forked from jasny/mysql_splitdump.sh
Split MySQL dump SQL file into one file per table or extract a single table
#!/bin/bash
####
# Split MySQL dump SQL file into one file per table
# based on http://blog.tty.nl/2011/12/28/splitting-a-database-dump
####
if [ $# -lt 1 ] ; then
echo "USAGE $0 DUMP_FILE [TABLE]"
exit
(function test() {
let e = document.getElementsByClassName('reply');
let i = 0;
e.forEach(function(e2) {
let author = '', text = '';
let authorE = e2.getElementsByClassName('author');
if (authorE.length > 0) {
author = authorE[0].innerText;
}
@Dramacydal
Dramacydal / thiswaifudoesnotexist.js
Created April 7, 2020 22:50
thiswaifudoesnotexist
// ==UserScript==
// @name waifu
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://www.thiswaifudoesnotexist.net/
// @grant none
// @run-at document-end
// @require http://code.jquery.com/jquery-3.4.1.min.js
// ==UserScript==
// @name twitch suggested friends hide
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author You
// @match https://www.twitch.tv/*
// @grant none
// @require http://code.jquery.com/jquery-3.4.1.min.js
// ==/UserScript==
.chat-line__message, .tw-root--theme-dark .top-nav__external-link {
color: #d4d4d4;
}
.drops-list__count {
background-color: #5a8045;
}
.player {
background-color: #1f1f1f;
#!/bin/bash
##/*
## * @Author: AllenYL
## * @Date: 2017-11-08 11:37:31
## * @Last Modified by: allen7575@gmail.com
## * @Last Modified time: 2017-11-08 11:37:31
## */
#
<?php
/**
* Checks that float value has fractional part
*
* @param float $value
*
* @return bool
*/
function hasFractionalPart($value)
{
public function getMap()
{
return [
self::FIELD__ID => [
'getter' => 'getId',
'setter' => 'setId',
'role' => [
self::ROLE__PRIMARY_KEY => true,
self::ROLE__GENERATE_KEY => true,
],