Skip to content

Instantly share code, notes, and snippets.

View NotoriousPyro's full-sized avatar

NotoriousPyro

View GitHub Profile
@NotoriousPyro
NotoriousPyro / connection-manager.ts
Created March 15, 2024 21:31
ConnectionManager Solana class for SexBot
import {
Instruction,
SwapInstructionsResponse
} from "@jup-ag/api";
import {
AddressLookupTableAccount,
ComputeBudgetProgram,
Connection,
Keypair,
PublicKey,
@NotoriousPyro
NotoriousPyro / Cardano-topology-builder.ps1
Last active February 24, 2021 21:55
Builds a topology for use with cardano-node. Set your own block producing relays inside the $newRelays object. Only looks for relays with addresses like *relays* but you can easily customise it. Creates a file called mainnet-topology.json
$relays = Invoke-WebRequest -Uri https://explorer.mainnet.cardano.org/relays/topology.json | ConvertFrom-Json
$relays2 = $relays.Producers | Where-Object {
$_.addr -like '*relays*'
} | Sort-Object { $_.addr -eq 'relays-new.cardano-mainnet.iohk.io' } -Descending
$newRelays = @{
"Producers" = [Collections.ArrayList]@(
@{
"addr" = "127.0.0.1"
@NotoriousPyro
NotoriousPyro / bitfinex.css
Created October 29, 2020 23:50
Bitfinex Stylebot Settings (for larger screens)
#sidebar-widget div.custom-scrollbar.custom-scrollbar {
width: 100;
height: 990px;
padding: 0px 0px 30px;
}
div.tickerlist__container {
height: 1000px;
}
@NotoriousPyro
NotoriousPyro / transmission_removecompleted.ps1
Created September 18, 2019 00:48
Transmission RPC to PowerShell Object calls example. Removes torrents which are completed. I may make this into a tool when I get more time.
$transmission = Join-Path "C:\Program Files\Transmission" transmission-remote.exe
$server = "127.0.0.1:9091"
function GetTorrentObjectList {
param (
$TorrentList
)
$torrents = [Collections.ArrayList]@()
foreach ($torrent in $TorrentList[1..($TorrentList.Count - 2)]) {
@NotoriousPyro
NotoriousPyro / OutlookAutostartAndMinimise.ps1
Last active November 18, 2025 17:54
Automatically finds, runs and places Outlook into the system tray.
<#
.Synopsis
Automatically finds, runs and places Outlook into the system tray.
.Description
Automatically finds, runs and places Outlook into the system tray.
By default, Outlook will start full-screen even when you have the option to minimize tray enabled and start the app as minimized.
@NotoriousPyro
NotoriousPyro / SQLite-to-MariaDB-TS3fixes.sh
Last active September 15, 2017 15:46
Fixes a few problems when converting SQLite to MariaDB/MySQL DB using the script at https://github.com/NotoriousPyro/SQLite-to-MariaDB-MySQL-perl-script
#!/usr/bin/env bash
file="$1"
if [ -z "$file" ]; then
echo "No filename specified. Aborted."
exit 1
fi
sed -i '/TABLE channel_properties/,/);/d' $file
@NotoriousPyro
NotoriousPyro / ProfilesPS.bat
Last active August 18, 2021 09:54
This is a PowerShell script I developed to delete all local profiles off the target PC that aren't: loaded, special (system profiles), have never been logged into, and that have not been used for more than 1 day. The last parameter is configurable via -lt (Get-Date).AddDays(-1)). It will safely delete profiles to avoid system issues such as loca…
@ECHO OFF
echo Powershell profile deleter
set /p PCNAME="PC:"
Powershell -Mta -NoProfile -Command "& {Get-WmiObject Win32_UserProfile -Computer %PCNAME% | Where {(!$_.Special) -and (!$_.Loaded) -and ($_.LastUseTime -ne $null) -and ($_.ConvertToDateTime($_.LastUseTime) -lt (Get-Date).AddDays(-1))} | Remove-WmiObject -Verbose}"
pause
@NotoriousPyro
NotoriousPyro / ProfilesCMD.bat
Last active August 18, 2017 18:59
This is a pretty dirty way to delete local profiles but it works. It copies the Default and Public profiles to C:\Users.Default\, then wipes the whole registry keys out and re-creates the defaults. Then it copies the Default and Public folders back into a new Users folder. Robocopy ensures that the permissions and attributes are set the same, bu…
@ECHO OFF
echo Batch profile deleter
set /p PCNAME="PC:"
psexec \\%PCNAME% -s robocopy "C:\Users\Default" "C:\Users.Default\Default" /XJ /E
psexec \\%PCNAME% -s robocopy "C:\Users\Public" "C:\Users.Default\Public" /XJ /E
reg delete "\\%PCNAME%\HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileGuid" /f
reg delete "\\%PCNAME%\HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList" /f
@NotoriousPyro
NotoriousPyro / session-shadow.bat
Last active December 9, 2021 12:01
RDP Session Shadow Batch file. Accepts --noping as a parameter. Works well with RDP Wrapper. Should only be used with Windows 10 onwards.
@ECHO OFF
MODE CON:COLS=80 LINES=40
COLOR 1A
SETLOCAL EnableDelayedExpansion
:ENTRY
CLS
CALL :PRINTBAR
ECHO ^| RDP Session Shadow Version 2.0 ^|
ECHO ^| By Craig Crawford ^|
ECHO ^|------------------------------------------------------------------------------^|
client
remote gateway.pyronexus.com 1194
proto udp
dev tun0
resolv-retry infinite
pkcs12 MyClientCertificate.p12
verify-x509-name 'C=GB, ST=Merseyside, L=Liverpool, O=PyroNexus, OU=PyroNexus.com, CN=gateway.pyronexus.com, [email protected]'
cipher AES-256-CBC
auth SHA256
nobind