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
// This is a simple https://scriptable.app script which receives link to a mastodon status | |
// and fetches the thread and converts it to markdown (as this was designed for glitch instances | |
// which supports html/markdown) and then returns it. | |
// No warranty or promise that this will work. It's a "bodge". | |
const DEFAULT_URL = "https://infosec.exchange/@gnyman/112688072805600720"; | |
// Function to fetch JSON data from a URL | |
async function fetchJSON(url) { | |
const request = new Request(url); |
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
<?php | |
/* == Minimal stupidly simple file upload script == | |
* *DO NOT USE THIS IN A UNTRUSTED ENVIRONMENT* | |
* There very little security. I have tried to block the most obvious thing | |
* (uploading of php files) and directory traversal. But this was done in 30 | |
* minutes mostly with a LLM so I wouldn't trust it at all. Use something | |
* better for a untrusted environment. | |
* | |
* With that said, you can run this by placing it in a folder, naming it | |
* index.php then running php -S 0.0.0.0:8000 in that folder. You can then |
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
// Simple script that adds a "incognito" shortcut to ChatGPT (toggles the history) | |
// run this in the console, or add it to StopTheMadness, Tampermonkey or similar | |
// Author @gnyman | |
// Licence CCO | |
function waitForElement(xpath) { | |
return new Promise((resolve, reject) => { | |
// Check if the element already exists | |
var existingElement = document.evaluate(xpath, document, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue; | |
if (existingElement) { |
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
import os | |
import time | |
import sys | |
import csv | |
import datetime | |
import subprocess | |
from huawei_lte_api.Client import Client | |
from huawei_lte_api.Connection import Connection |
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
#!/bin/bash | |
# this script allows you to monitor the memory usage of a command like | |
# mmmon.sh "docker save my/image:0.1 | xdelta3 -d -s /dev/stdin delta-0.1-to-0.2.xdelta /dev/stdout | docker load" | |
# the ""'s are important | |
# it will include any child processes | |
# it will handle ctrl+c and forward it | |
# I couldn't find this anywhere else, hope someone finds it useful | |
# - Gabriel | |
# licence: public domain |
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
// ActiveTable - a bookmarklet to make tables sortable and editable | |
function init() { | |
var aHrows = getHrows(); | |
var numHrows = aHrows.length; | |
var aHidden = getHiddenColumns(); | |
ATpopup = document.createElement("div"); | |
ATpopup.style.cssText = "position: absolute; visibility: hidden; padding: 0; font-family: Arial; background-color: rgba(255, 255, 255, 0.9); border-radius: .5em; text-align: center; box-shadow: .05em .05em .5em #00C;"; | |
ATpopup.innerHTML = "<a href='sort' title='sort' onclick='sortColumn(); return false'>↕️</a><br><a href='hide' style='color: #C00; font-family: monospace; font-size: 1.5em; text-decoration: none;' title='hide' onclick='hideColumn(); return false'>x</a>"; // TODO - use protocol-less URL for img |
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
on run | |
set imessage_id to "" -- leave blank to skip sending periodic iMessage progress updates, put your iMessage ID here to get updates as the script runs | |
set delay_seconds to 5 -- Don't set to 0, it runs too fast. 0.75 is a good setting for "go fast". | |
set computer_name to do shell script "scutil --get ComputerName" | |
set os_version to do shell script "sw_vers -productVersion" | |
set os_build to do shell script "sw_vers -buildVersion" | |
set _uptime to do shell script "uptime" | |
set url_list to {"http://techmeme.com", "http://www.consumerreports.org/laptops/macbook-pros-fail-to-earn-consumer-reports-recommendation/", "https://twitter.com/panzer/status/812367550734401536", "http://www.politico.com/story/2016/12/foreign-travelers-social-media-232930", "http://www.macworld.com/article/3153384/gaming/nintendo-plans-to-release-2-or-3-mobile-games-a-year-after-super-mario-runs-success.html", "http://www.wsj.com/articles/cyber-experts-cite-link-between-dnc-hacks-and-aggression-against-uk |
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
on run | |
set imessage_id to "" -- leave blank to skip sending periodic iMessage progress updates, put your iMessage ID here to get updates as the script runs | |
set delay_seconds to 5 -- Don't set to 0, it runs too fast. 0.75 is a good setting for "go fast". | |
set computer_name to do shell script "scutil --get ComputerName" | |
set os_version to do shell script "sw_vers -productVersion" | |
set os_build to do shell script "sw_vers -buildVersion" | |
set _uptime to do shell script "uptime" | |
set url_list to {"http://techmeme.com", "http://www.consumerreports.org/laptops/macbook-pros-fail-to-earn-consumer-reports-recommendation/", "https://twitter.com/panzer/status/812367550734401536", "http://www.politico.com/story/2016/12/foreign-travelers-social-media-232930", "http://www.macworld.com/article/3153384/gaming/nintendo-plans-to-release-2-or-3-mobile-games-a-year-after-super-mario-runs-success.html", "http://www.wsj.com/articles/cyber-experts-cite-link-between-dnc-hacks-and-aggression-against-uk |
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
package main | |
import ( | |
"strings" | |
"github.com/shomali11/slacker" | |
"github.com/slack-go/slack" | |
) | |
func main() { |
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
This contains lots of senseitive information and I clicked the wrong button. Oops. |
NewerOlder