Skip to content

Instantly share code, notes, and snippets.

@DecentM
DecentM / decentm-cla.md
Created January 29, 2023 12:50
DecentM - Contributor License Agreement

DecentM's Individual Contributor License Agreement

Thank you for your interest in contributing to my project! This Individual Contributor License Agreement (“Agreement”) sets out the terms governing any source code, object code, bug fixes, configuration changes, tools, specifications, documentation, data, materials, feedback, information or other works of authorship that you submit or have submitted, in any form and in any manner, to the repository. If you have any questions respecting this Agreement, please contact decentm+contrib@decentm.com.

You agree that the following terms apply to all of your past, present and future Contributions. Except for the licenses granted in this Agreement, you retain all of your right, title and interest in and to your Contributions.

Copyright License. You hereby grant, and agree to grant, to DecentM a non-exclusive, perpetual, irrevocable, worldwide, fully-paid, royalty-free, transferable copyright license to reproduce, prepare derivative works of, publicly display, pu

using UnityEditor;
using UnityEngine;
public sealed class ExampleClass : EditorWindow
{
private static readonly string[] mList =
{
"AboutWIndowLicenseLabel" ,
"AC LeftArrow" ,
"AC RightArrow" ,
@DecentM
DecentM / ffmpeg-vrc.sh
Last active August 14, 2022 11:26
Convert videos with FFmpeg to VRChat video player friendly format
#!/bin/sh -e
ffmpeg -i "$1" -c:v h264 -b:v 5M -maxrate 9M -bufsize 1M -preset veryslow -movflags +faststart -pix_fmt yuv420p -c:a aac -ab 1536k -strict 2 -threads 8 "$2"
const LdapAuth = require('ldapauth-fork')
const pify = require('pify')
// https://www.forumsys.com/tutorials/integration-how-to/ldap/online-ldap-test-server/
const options = {
'url': 'ldap://ldap.forumsys.com:389',
'bindDN': 'cn=read-only-admin,dc=example,dc=com',
'bindCredentials': 'password',
'searchBase': 'dc=example,dc=com',
'searchFilter': 'uid={{username}}'
@DecentM
DecentM / xvfb-run.sh
Created February 10, 2018 22:03 — forked from tyleramos/xvfb-run.sh
XVFB Run Bash script
#!/bin/sh
# $Id: xvfb-run 2027 2004-11-16 14:54:16Z branden $
# This script starts an instance of Xvfb, the "fake" X server, runs a command
# with that server available, and kills the X server when done. The return
# value of the command becomes the return value of this script, except in cases
# where this script encounters an error.
#
# If anyone is using this to build a Debian package, make sure the package
@DecentM
DecentM / test.user.css
Created January 5, 2018 15:35
test.user.css
/* ==userstyle==
@name Title
@description <b>Bold</b> - Not bold
@version 0.0.1
@namespace https://openusercss.org/theme/5a4605de961b8c0b001f2476
@homepageURL https://openusercss.org/theme/5a4605de961b8c0b001f2476
@author Something
==/userstyle== */
@DecentM
DecentM / ouc-cla.md
Created January 4, 2018 11:28
OpenUserCSS CLA

OpenUserCSS Individual Contributor License Agreement

Thank you for your interest in contributing to open source software projects (“Projects”) made available by OpenUserCSS or its affiliates (“OpenUserCSS”). This Individual Contributor License Agreement (“Agreement”) sets out the terms governing any source code, object code, bug fixes, configuration changes, tools, specifications, documentation, data, materials, feedback, information or other works of authorship that you submit or have submitted, in any form and in any manner, to OpenUserCSS in respect of any of the Projects (collectively “Contributions”). If you have any questions respecting this Agreement, please contact decentm+contrib@openusercss.org.

You agree that the following terms apply to all of your past, present and future Contributions. Except for the licenses granted in this Agreement, you retain all of your right, title and interest in and to your Contributions.

Copyright License. You hereby grant, and agree to grant, to OpenUserCS

@DecentM
DecentM / vpn-lan.sh
Created August 23, 2017 19:23
Forward 10.20.0.0/16 from my VPN to LAN
iptables -I FORWARD -i tun0 -o enxb827ebf29db7 -s 10.8.0.0/24 -d 10.20.0.0/16 -m conntrack --ctstate NEW -j ACCEPT
iptables -I FORWARD -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
iptables -t nat -I POSTROUTING -o eth0 -s 10.8.0.0/24 -j MASQUERADE
@DecentM
DecentM / material-userstyles-v2.css
Last active December 18, 2016 01:51
The previuos version of my theme "Material Userstyles", now under the public domain. A bit of tweaking is required for it to be able to have custom colors.
@namespace url(http://www.w3.org/1999/xhtml);
/* Material Userstyles v2.0 by DecentM */
@-moz-document regexp("https?\:\/\/userstyles.org.*") {
/*!
* Bootstrap v4.0.0-alpha.4 (http://getbootstrap.com)
* Copyright 2011-2016 The Bootstrap Authors
* Copyright 2011-2016 Twitter, Inc.
* Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE)
*//*! normalize.css v4.0.0 | MIT License | github.com/necolas/normalize.css */ html{font-family:sans-serif;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%}body{margin:0}article,aside,details,figcaption,figure,footer,header,main,menu,nav,section,summary{display:block}audio,canvas,progress,video{display:inline-block}audio:not([controls]){display:none;height:0}progress{vertical-align:baseline}[hidden],template{display:none}a{background-color:transparent}a:active,a:hover{outline-width:0}abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}b,strong{font-weight:inherit}b,strong{font-weight:bolder}dfn{font-style:ita
@DecentM
DecentM / material-userstyles-old.css
Last active December 18, 2016 01:28
This is the old version of my userstyle, Material Userstyles. This version is now under the Public Domain. Some amount of work is required to get it working.
@namespace url(http://www.w3.org/1999/xhtml);
/* Material Userstyles v1.0 by DecentM */
@-moz-document regexp("https?\:\/\/forum.userstyles.org.*") {
#advanced-search,
#advanced-search *,
#related,
#related li:not(.more),
#show-advanced-search,
#style-info,