Skip to content

Instantly share code, notes, and snippets.

View Log1x's full-sized avatar

Brandon Log1x

View GitHub Profile
@Log1x
Log1x / Win10.preset
Created February 8, 2020 21:54
Recommended Windows 10 Performance Preset
# See: https://github.com/Disassembler0/Win10-Initial-Setup-Script
### Require administrator privileges ###
RequireAdmin
### Privacy Tweaks ###
DisableTelemetry # EnableTelemetry
DisableWiFiSense # EnableWiFiSense
DisableSmartScreen # EnableSmartScreen
DisableWebSearch # EnableWebSearch
@Log1x
Log1x / application.php
Last active April 3, 2020 20:38 — forked from swalkinshaw/application.php
Trellis + Sentry
<?php
/**
* composer require sentry/sentry-sdk
*/
Env::init();
// ...
if (env('SENTRY_DSN') && env('WP_ENV') !== 'development') {
@Log1x
Log1x / windows.md
Last active March 13, 2022 13:33
Some stuff I use on Windows

Windows Setup

Screenshot

This contains various software and tools I use for customizing Windows.

Warning: Installing a bad Windows theme can render your system unusable (dwm.exe crash-loop – "black screen of death") due to resource map changes.

  • Always match your winver.exe build to the theme you're installing.
  • Before major build updates, always change back to a default windows theme.
@Log1x
Log1x / vanilla.js
Created March 11, 2019 17:19
Here lives a beautiful, elegant library to help you get started with vanilla Javascript. Made with ❤️ by Log1x
//
@Log1x
Log1x / functions.php
Created March 7, 2019 16:38
Remove noopener & noreferrer on WordPress links
/**
* Remove rel="noopener noreferrer" in TinyMCE links
*
* @param array $init
* @return array
*/
add_filter('tiny_mce_before_init', function ($init) {
$init['allow_unsafe_link_target'] = true;
return $init;
});
@Log1x
Log1x / debloatNox.md
Last active May 3, 2024 22:03
Debloating & Optimizing Nox

Debloating Nox

Nox, despite being the most feature-filled Android emulator, has a lot of negativity surrounding it due to their antics when it comes to making income off of their program. It is known for running repeated advertisments in the background, calling home and passing along system information (outside of your Android instance) as well as a vast amount of potentially sensitive data in an encrypted payload back to their multitude of servers. With the following preventitive measures, we can stop a majority of this happening as well as greatly improve the overall performance.

  1. Download and Install a fresh copy of Nox. The latest version is fine (for now). If you already have it installed, that is fine too. No need to reinstall.

  2. Enable Root Mode on Nox by clicking the gear icon and then checking the Root Startup box.

  3. Install a new Launcher from the Play Store. ANYTHING but Nox's default. I suggest [Nova Launcher](https://play.google.com/s

@Log1x
Log1x / countdown.js
Created January 22, 2019 01:27
Vanilla JS Countdown Timer
/**
* Countdown
*/
function init() {
const second = 1000,
minute = second * 60,
hour = minute * 60,
day = hour * 24;
const date = document.querySelector('[data-date]').dataset.date;
@Log1x
Log1x / form.js
Created January 22, 2019 01:25
Vanilla AJAX with FormCarry
/**
* Form
*/
function init() {
if (document.forms[0] && window.FormData) {
const form = document.forms[0];
const button = form.querySelector('.button');
const request = new XMLHttpRequest();
request.open('POST', 'https://formcarry.com/s/XXXXXXXX', true);
@Log1x
Log1x / Default.preset
Created November 17, 2018 23:23
My personally used Win10 Preset
##########
# Win 10 / Server 2016 / Server 2019 Initial Setup Script - Default preset
# Author: Disassembler <disassembler@dasm.cz>
# Version: v3.3, 2018-10-22
# Source: https://github.com/Disassembler0/Win10-Initial-Setup-Script
##########
### Require administrator privileges ###
RequireAdmin
@Log1x
Log1x / data.json
Last active March 22, 2019 05:52
Import to WordPress from JSON
{
"0":{
"slug":"lorem-ipsum",
"title":"Lorem Ipsum",
"publish_date":"2018-10-12T05:00:00.000Z",
"featured_image":"https://link.to/image.jpg",
"content":"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque blandit tempus feugiat. Nullam purus massa, ultricies vel erat ac, tempor condimentum lorem. Etiam malesuada egestas tincidunt.",
"page_title":"Welcome to Lorem Ipsum",
"description":"Nulla sit amet massa fringilla eros tempor tempus. Fusce auctor arcu sed ipsum eleifend, sit amet tincidunt ligula porta."
}