Skip to content

Instantly share code, notes, and snippets.

View killshot13's full-sized avatar
Working remotely

Michael R. killshot13

Working remotely
View GitHub Profile
@killshot13
killshot13 / .wslconfig
Last active September 4, 2024 12:09
My personal configuration files [.wslconfig & wsl.conf] for Windows Subystem for Linux 2. These example do contain all of the most recent options for said files, but do not represent the default values in each situation. (asterisk = only available on Win 11)
[wsl2]
# An absolute Windows path to a custom Linux kernel.
# kernel=The Microsoft built kernel provided inbox (default)
# How much memory to assign to the WSL 2 VM, this can be set as whole numbers using GB or MB. Default is 50% of total memory on Windows or 8GB, whichever is less; formerly 80% of total memory on Windows.
memory=5700MB
# How many logical processors to assign to the WSL 2 VM.
# processors=The same number of logical processors on Windows (default)
@killshot13
killshot13 / pokemon.txt
Last active March 16, 2024 10:18
The names of all 1025 species of Pokémon currently known to exist, formatted as a wordlist to be used for password cracking
bulbasaur
ivysaur
venusaur
charmander
charmeleon
charizard
squirtle
wartortle
blastoise
caterpie
@killshot13
killshot13 / pandoc-install-intro.md
Last active August 1, 2023 07:59
A guide to installing and configuring Pandoc on the Windows & the Linux OS.

What is Pandoc?

Pandoc is open-source software used to transform various filetypes such as .md into more user-friendly filetypes including .pdf, .docx, and .html.

@killshot13
killshot13 / FullyStructuredReactFormControlledFinal.jsx
Last active July 2, 2023 20:41
React Forms: Controlled vs. Uncontrolled Components w/ Examples
// @ts-nocheck
import axios from 'axios'
import React, { useReducer, useState } from 'react'
const formReducer = (state, event) => {
if (event.reset) {
return {
name: '',
email: '',
tel: '',
@killshot13
killshot13 / settings.jsonc
Last active May 21, 2023 14:43
vscode-colorized-brackets
{
// Controls whether bracket pair colorization is enabled or not. Use 'workbench.colorCustomizations' to override the bracket highlight colors.
"editor.bracketPairColorization.enabled": true,
// Controls whether the editor should render indent guides.
"editor.guides.indentation": true,
// Controls whether bracket pair guides are enabled or not.
// - true: Enables bracket pair guides.
// - active: Enables bracket pair guides only for the active bracket pair.
// - false: Disables bracket pair guides.
"editor.guides.bracketPairs": "active",
@killshot13
killshot13 / forwardRef.jsx
Last active February 4, 2023 01:28
React useRef && forwardRef
// sample use case: scroll to a React component by using a reference.
import React, { forwardRef, useRef } from 'react'
// @ts-ignore
const Article = forwardRef(function Article({ onClick }, ref) {
return (
<article ref={ref}>
<h1>A React article for Latin readers</h1>
// Rest of the article's content...
<button onClick={onClick}>Back to the top</button>
@killshot13
killshot13 / settings.jsonc
Last active January 12, 2023 19:21
todo-tree-config
{
// If true, any subfolders containing a .git file will be ignored when searching.
"todo-tree.filtering.ignoreGitSubmodules": true,
// Add VSCode's `files.exclude` and/or `search.exclude` list to the ignored paths.
// - none: Don't used any built in excludes
// - file excludes: Use the Files:Exclude setting
// - search excludes: Use the Search:Exclude setting
// - file and search excludes: Use the Files:Exclude and the Search:Exclude setting
"todo-tree.filtering.useBuiltInExcludes": "file and search excludes",
// Set to true to enable automatic updates when files in the workspace are created, changed or deleted.
@killshot13
killshot13 / windows_snippets.md
Last active December 14, 2022 02:19
PowerShell Snippets

PowerShell Snippets

A quick reference to copypasta useful PowerShell commands. (randomCollection)

one-liners


1.) Identify & Kill a Process Listening on a Given Port (assuming PORT 5000 and PID 348):

@killshot13
killshot13 / thekey.json
Created November 5, 2022 07:54
[TheKey.json]: Base config file for Stack Overflow's The Key and The Key V2 Macropad
{
"version": 1,
"keyboard": {
"bounds": {
"max": {
"x": 3,
"y": 1
},
"min": {
"x": 0,
@killshot13
killshot13 / alias.md
Created October 16, 2022 11:15
git aliases

git aliases

[alias]
 a = add
 aa = add --all
 ai = add -i
 ap = apply
 aps = apply --stat
 apch = apply --check