Skip to content

Instantly share code, notes, and snippets.

#!/bin/bash
BRANCH=retroplayer-17alpha1
WORKSPACE=/data/kodibuild
STAGE=/data/kodigame
LOGFILE=/home/user/logretro.log
echo "$(date "+%m%d%Y %T") : Cleaning Up" >> $LOGFILE 2>&1
sudo rm -rf $WORKSPACE >> $LOGFILE 2>&1
sudo rm -rf $STAGE >> $LOGFILE 2>&1
echo "Building $BRANCH"
let a = (![]+[])[+!+[]];
let b = ({[{}]:{}}+[])[!+[]+!+[]];
let c = ({[{}]:{}}+[])[!+[]+!+[]+!+[]+!+[]+!+[]];
let d = ([![]]+[][[]])[+!+[]+!+[]+!+[]+!+[]+!+[]+!+[]+!+[]];
let e = (!![]+[])[!+[]+!+[]+!+[]];
let f = (![]+[])[+[]];
let j = ({[{}]:{}}+[])[!+[]+!+[]+!+[]];
let i = ([![]]+[][[]])[+!+[]+[+[]]];
let l = (![]+[])[!+[]+!+[]];
let n = ([![]]+[][[]])[+!+[]+!+[]+!+[]+!+[]+!+[]+!+[]];
@MrTarantula
MrTarantula / dupes.js
Created November 6, 2017 22:24
Duplicate files in .*proj files
var proj = ``;
const pattern = /\s*<Content Include="(.*)" \/>/;
const testing = proj.split("\n");
const matches = [];
testing.forEach((str) => {
if (str.match(pattern)) {
if (matches.find((match) => match === str)) {
console.log("Duplicate found: " + str);
@MrTarantula
MrTarantula / CryptoRandom.cs
Created August 30, 2018 13:18 — forked from niik/CryptoRandom.cs
Buffered CryptoRandom implementation based on Stephen Toub and Shawn Farkas' CryptoRandom
/*
* Original version by Stephen Toub and Shawn Farkas.
* Random pool and thread safety added by Markus Olsson (freakcode.com).
*
* Original source: http://msdn.microsoft.com/en-us/magazine/cc163367.aspx
*
* Some benchmarks (2009-03-18):
*
* Results produced by calling Next() 1 000 000 times on my machine (dual core 3Ghz)
*
@MrTarantula
MrTarantula / Chart.cs
Created October 28, 2020 22:13
Sane Y-axis ticks
using System;
using System.Collections.Generic;
public static class Chart
{
public static List<double> GetChartTicks(double minValue, double maxValue)
{
double diff = maxValue - minValue;
double initialValue = minValue;