This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Flash drive swapon | |
Requires=dev-disk-by\x2duuid-7849984a\x2de42f\x2d497a\x2dafec\x2d8bebb8384f7a.device | |
After=dev-disk-by\x2duuid-7849984a\x2de42f\x2d497a\x2dafec\x2d8bebb8384f7a.device | |
[Service] | |
ExecStart=/sbin/swapon -U 7849984a-e42f-497a-afec-8bebb8384f7a | |
[Install] | |
WantedBy=dev-disk-by\x2duuid-7849984a\x2de42f\x2d497a\x2dafec\x2d8bebb8384f7a.device |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Windows Registry Editor Version 5.00 | |
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\dllfile\shell\Open with IDA Pro] | |
"Icon"="\"C:\\Program Files\\IDA Pro 8.3\\ida64.exe\",0" | |
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\dllfile\shell\Open with IDA Pro\Command] | |
@="C:\\Program Files\\IDA Pro 8.3\\ida64.exe \"%1\"" | |
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\exefile\shell\Open with IDA Pro] | |
"Icon"="\"C:\\Program Files\\IDA Pro 8.3\\ida64.exe\",0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* You have a set of scales which are unbalanced and the aim is to use a maximum of two of the remaining weights to see if you can balance the scales. If you do need to use 2 weights they can be placed on the same scale. | |
Write a function that can accept 3 arguments. The first argument will be an integer greater than 0 that represents the current weight of the left scale, the second argument will be an integer greater than 0 that represents the weight of the right scale and the last argument will be an array of positive integers that represent the weights you currently have remaining to use. | |
For example (5, 9, [3,5,8,12]). 5 represents the left scale’s current weight. 9 represents the right scale’s current weight and the array represents the weights you have at your disposal. | |
If you can balance the scales then the function should return an array of the number(s) required to make the scales balance. Otherwise it can return nil/null. | |
Examples | |
input (6, 8, [3, 4, 5, 8]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const x = (strings, ...params) => { | |
let arr = ''; | |
for(let i = 0; i < params.length; i++) { | |
arr += (strings[i]); | |
arr += (params[i]); | |
} | |
arr += (strings[params.length]); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Discord - Hide blocked messages | |
// @version 1 | |
// @grant none | |
// @match https://discordapp.com/* | |
// @run-at document-start | |
// ==/UserScript== | |
(() => { | |
const callback = (mutationsList, observer) => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const getEventNames = (root) => { | |
let events = [ ]; | |
const objectHasSubPrototype = (object, comp) => { | |
let proto = Object.getPrototypeOf(object); | |
while(proto !== null && proto !== EventTarget) { | |
proto = Object.getPrototypeOf(proto); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Windows Registry Editor Version 5.00 | |
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\exefile\shell\Open with ILSpy] | |
"Icon"="\"C:\\Users\\hayley\\Projects\\ILSpy\\ILSpy\\bin\\Release\\net6.0-windows\\ILSpy.exe\",0" | |
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\exefile\shell\Open with ILSpy\Command] | |
@="\"C:\\Users\\hayley\\Projects\\ILSpy\\ILSpy\\bin\\Release\\net6.0-windows\\ILSpy.exe\" \"%1\"" | |
[HKEY_LOCAL_MACHINE\SOFTWARE\Classes\dllfile\shell\Open with ILSpy] | |
"Icon"="\"C:\\Users\\hayley\\Projects\\ILSpy\\ILSpy\\bin\\Release\\net6.0-windows\\ILSpy.exe\",0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Concurrent; | |
using System.Collections.Generic; | |
using System.ComponentModel; | |
using System.Timers; | |
using System.Threading; | |
using System.Windows.Threading; | |
/// <summary> | |
/// Event debouncer helps to prevent calling the same event handler too often (like mark Dirty or Invalidate) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name GitHub "Earliest Commit" | |
// @version 1 | |
// @grant none | |
// @match https://github.com/* | |
// ==/UserScript== | |
const exec = () => { | |
const exists = (...sel) => { | |
return sel.every((s) => document.querySelectorAll(s).length > 0); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @name Twitch - Big emotes | |
// @version 1 | |
// @grant none | |
// @match https://www.twitch.tv/* | |
// @run-at document-start | |
// ==/UserScript== | |
// |