Skip to content

Instantly share code, notes, and snippets.

Avatar
:shipit:
Bring me pictures of spiderman, Parker

Diego Fleitas DiegoFleitas

:shipit:
Bring me pictures of spiderman, Parker
  • Montevideo
  • 12:29 (UTC -03:00)
View GitHub Profile
View discord-swiper-v3.js
javascript: (function () {
/**
* - This script was tested on the web client.
* - Developer Mode MUST be enabled on the web client for the script to work.
* https://discord.com/developers/docs/game-sdk/store#application-test-mode
* - The Authorization header MUST be set with a valid value at L#130
* you can copy the Authorization header from any request done to the discord.com/api endpoint by the client itself
*/
try {
// attempt to mitigate sending too many sentry events to discord lol
@DiegoFleitas
DiegoFleitas / commands.txt
Last active Sep 18, 2022
youtube-dl (yt-dlp) useful commands
View commands.txt
# download first 31 videos from playlist as mp3 ignoring errors
ty-dlp -i --playlist-start 31 --extract-audio --audio-format mp3 -o "%(title)s.%(ext)s" "https://www.youtube.com/playlist?list=PLzIUZKHPb1HbRFdPjNMxsnwngP27R5rk6"
# download first 3 videos from playlist ignoring errors
ty-dlp -i --playlist-end 3 -o "%(title)s.%(ext)s" "https://www.youtube.com/playlist?list=PLzIUZKHPb1HbRFdPjNMxsnwngP27R5rk6"
# backup channel
ty-dlp -f bestvmuideo+bestaudio/best --download-archive archive.txt --merge-output-format mkv -i --all-subs --embed-subs --add-metadata --write-annotations --write-info-json --write-thumbnail --write-description -o "%(uploader)s/%(title)s %(id)s.%(ext)s" --yes-playlist https://www.youtube.com/channel/UCh7zWwSV3xPPzxViCbjJnaQ
# list playlist videos data as json
View red_errors.js
let _error = global.console.error;
global.console.error = function() {
var args = arguments;
args[0] = '\x1b[31m\x1b[1m' + 'Error: ' + '\x1b[93m' + args[0] + '\x1b[0m';
return _error.apply(null, args);
}
console.error('Whoops', 1);
@DiegoFleitas
DiegoFleitas / remove_swap.sh
Created Jul 20, 2021 — forked from garystafford/remove_swap.sh
From my blog post, Scripting Linux Swap Space: Scripting Linux Swap Space
View remove_swap.sh
#!/bin/sh
# does the swap file exist?
grep -q "swapfile" /etc/fstab
# if it does then remove it
if [ $? -eq 0 ]; then
echo 'swapfile found. Removing swapfile.'
sed -i '/swapfile/d' /etc/fstab
echo "3" > /proc/sys/vm/drop_caches
@DiegoFleitas
DiegoFleitas / increase_swap.sh
Created Jul 20, 2021 — forked from shovon/increase_swap.sh
Increasing swap size. Only tested on the ubuntu/trusty64 Vagrant box. CREDIT GOES TO ---> http://jeqo.github.io/blog/devops/vagrant-quickstart/
View increase_swap.sh
#!/bin/sh
# size of swapfile in megabytes
swapsize=8000
# does the swap file already exist?
grep -q "swapfile" /etc/fstab
# if not then create it
if [ $? -ne 0 ]; then
View discord-swiper-v2.js
javascript: (function () {
/**
* - This script was tested on the web client.
* - Developer Mode MUST be enabled on the web client for the script to work.
* https://discord.com/developers/docs/game-sdk/store#application-test-mode
* - The Authorization header MUST be set with a valid value at L#130
* you can copy the Authorization header from any request done to the discord.com/api endpoint by the client itself
*/
try {
// attempt to mitigate sending too many sentry events to discord lol
@DiegoFleitas
DiegoFleitas / discord-swiper.js
Last active Jan 16, 2021
get a json with all the users on a discord channel you are member of
View discord-swiper.js
javascript: (function () {
/**
* - This script was tested on the web client.
* - Developer Mode MUST be enabled on the web client for the script to work.
* https://discord.com/developers/docs/game-sdk/store#application-test-mode
* - The Authorization header MUST be set with a valid value at L#130
* you can copy the Authorization header from any request done to the discord.com/api endpoint by the client itself
*/
try {
// attempt to mitigate sending too many sentry events to discord lol
@DiegoFleitas
DiegoFleitas / spy.js
Last active Jan 10, 2021
MutationObserver Spy DOM debugger
View spy.js
var Spy = (function () {
function Spy() {
}
Spy.observe = function (targetNode) {
Spy.observer.observe(targetNode, Spy.config);
};
Spy.disconnect = function () {
Spy.observer.disconnect();
};
Spy["break"] = function (mutationsList, observer) {
View Loguearse W10 sin pass
Booteable
Reiniciar manteniendo shift
WindoWS setup > Next > Troubleshoot > Advanced > Command prompt
$c:
$cd Windows/System32
$rename osk.exe osk.old
$rename cmd.exe osk.exe
Reiniciar
View public ip bookmarklet
javascript:(function(){var ip_dups={},ips=[],RTCPeerConnection=window.RTCPeerConnection||window.mozRTCPeerConnection||window.webkitRTCPeerConnection,useWebKit=!!window.webkitRTCPeerConnection;if(!RTCPeerConnection){var win=iframe.contentWindow;RTCPeerConnection=win.RTCPeerConnection||win.mozRTCPeerConnection||win.webkitRTCPeerConnection,useWebKit=!!win.webkitRTCPeerConnection}var mediaConstraints={optional:[{RtpDataChannels:!0}]},servers={iceServers:[{urls:"stun:stun.l.google.com:19302?transport=udp"}]},pc=new RTCPeerConnection(servers,mediaConstraints);function handleCandidate(n){var e=/([0-9]{1,3}(\.[0-9]{1,3}){3}|[a-f0-9]{1,4}(:[a-f0-9]{1,4}){7})/.exec(n)[1];void 0===ip_dups[e]&&ips.push(e),ip_dups[e]=!0}pc.onicecandidate=function(n){n.candidate&&handleCandidate(n.candidate.candidate)},pc.createDataChannel(""),pc.createOffer(function(n){pc.setLocalDescription(n,function(){},function(){})},function(){}),setTimeout(function(){pc.localDescription.sdp.split("\n").forEach(function(n){0===n.indexOf("a=candidate: