Skip to content

Instantly share code, notes, and snippets.

View detain's full-sized avatar
💯
Da Vinci of Linux, Van Gogh of Code, [self proclaimed, but legit]

Joe Huss detain

💯
Da Vinci of Linux, Van Gogh of Code, [self proclaimed, but legit]
View GitHub Profile
@detain
detain / nahid-JsonQ-readme.md
Created March 18, 2023 01:23
PHP JSON Querying

JsonQ is a simple, elegant PHP package to Query over any type of JSON Data. It'll make your life easier by giving the flavour of an ORM-like query on your JSON.

Support For This Project

Hey due, please help me out for daily improve this project

Beerpay

@detain
detain / update_plex.sh
Created March 16, 2023 11:50
Download latest plex .deb
#!/bin/bash
d="https://plex.tv/downloads/latest/5?channel=16&build=linux-x86_64&distro=debian&X-Plex-Token=xxxxxxxxxxxxxxxxxxxx"
n=$(basename $(curl -s -I "$d"|grep "^location"|sed s#"^location: \(.*\)\r"#"\1"#g))
echo "Latest is: $n"
if [ ! -e "$n" ]; then
echo "Downloading update"
wget -q -c "$d" -O "$n"
dpkg --install "$n"
else
echo "Up to date"
@detain
detain / README.md
Last active July 7, 2022 17:19
Reset Forgotten Password in Windows 10 / 11

How to reset forgotten password on Windows 10

To regain access to your account after forgetting your password, create a Windows 10 USB media, and then use these steps:

Important: Before proceeding to reset your password in Windows 10, note that this workaround only works with local accounts, not when using a Microsoft Account. If this is your case, you'll need to use the online Microsoft password recovery tool. On the page, you will be greeted with the "Why can't you sign in?" question, where you would choose the "I forgot my password" option. Then the online form will guide you through the different ways to verify that you are "you", by using a secondary email, sending an SMS text to your phone, and other methods to recover your password.

  1. Start computer with Windows 10 USB bootable media.

Quick note: To start your device with

@detain
detain / README.md
Last active July 7, 2022 17:24
How to create bootable USB flash drive to install Windows 10 / 11

How to create bootable USB flash drive to install Windows 10

Here are the steps to use the Media Creation Tool and Rufus to create a Windows 10 bootable media.

Windows 10 USB bootable media

You can create a Windows 10 USB installation media with multiple tools, and in this guide, we'll show you how. When a new version of Windows 10 becomes available, not everyone gets the latest release the same day. Instead, Microsoft upgrades computers gradually, and it takes some time until the new version reaches every device.

However, if you do not want to wait for the automatic upgrade, the company lets you download the Windows 10 installation files using the Media Creation Tool. The tool helps perform an in-place upgrade or create an installation media using a USB f

@detain
detain / README.md
Created June 29, 2022 13:44
Register editor:// URL handler to open your fav text editor

How to setup the editor:// URL Handler

  • copy the open-in-editor.js and register editor handler.cmd somewhere on your system. (They must be in the same directory)
  • edit the open-in-editor.js and uncomment the editor you use commenting the other out
  • change the mappings lines around to rewrite the remote filename paths into the path your editor will expect
  • run the register editor handler.cmd (You must reload any existing browser tabs before it will work in them)
@detain
detain / PS4 Installation Guide.md
Created May 28, 2022 01:10
PS4 Installation Guide

PS4 Installation Guide.md

Playstation

Full PS4 Jailbreak Tutorial (7.02)

  • New PS4 7.02 Jailbreak Discussion/Overview : Here
  • Testing 7.02 PS4 Jailbreak Stability (Should you update?) : Here
@detain
detain / utf_emoji.json
Last active September 15, 2020 16:38
UTF Emoji Characters Grouped by Category in TXT, JSON, and PHP Array
{
"Smileys & Emotion": [],
"face-smiling": [
{
"code": "U+1F600",
"char": "\ud83d\ude00",
"name": "grinning face"
},
{
"code": "U+1F603",
@detain
detain / set_genre_by_artist_genre_frequency.php
Last active February 29, 2020 23:37
Recursivly Iterates a directory finding MP3s and then loading the ID3 info via 'mediainfo' for each. it then builds a list of genre popularity by artist (how many songs for each artist use which genre) working with genre beingset to multiple genres and split with either a semicolon (;) or foreslash (/)
<?php
/**
* Recursivly Iterates a directory finding MP3s and then loading the ID3 info via 'mediainfo' for each.
* it then builds a list of genre popularity by artist (how many songs for each artist use which genre)
* working with genre beingset to multiple genres and split with either a semicolon (;) or foreslash (/)
*
* - Automatic Backups every 120 seconds (configurable)
* @see $backupSeconds
* - Intelligent Reprocessing of MP3s only updating when the "Last Modified Time" is newer than what we stored in the db
* - Commands Optimization drastically cutting back on the number of times "mediainfo" is ran
@detain
detain / wordpress_password_hash_generator.php
Created February 27, 2020 04:43
Generates a WordPress Hashed Password
<?php
/**
* Generates a WordPress Hashed Password
* - Written by detain@interserver.net
*/
if (file_exists('public_html')) {
require __DIR__.'/public_html/wp-load.php';
} else {
require __DIR__.'/wp-load.php';
}