Skip to content

Instantly share code, notes, and snippets.

View pitchinnate's full-sized avatar

Nate pitchinnate

View GitHub Profile
@pitchinnate
pitchinnate / gist:991e69d7388bab63fa02e7c306394fc0
Last active September 16, 2025 02:01
Search for eslint-config-prettier malware
Get-ChildItem -Path "c:/" -Recurse -Directory -Force -ErrorAction SilentlyContinue |
Where-Object { $_.Name -in @("eslint-config-prettier", "eslint-plugin-prettier", "snyckit", "@pkgjs/core", "napi-postinstall", "@ctrl/tinycolor") } |
ForEach-Object {
$pkg = Join-Path $_.FullName 'package.json'
if (Test-Path $pkg) {
$ver = (Get-Content $pkg | ConvertFrom-Json).version
$validVersions = @{
"eslint-config-prettier" = @("8.10.1", "9.1.1", "10.1.6", "10.1.7")
"eslint-plugin-prettier" = @("4.2.2", "4.2.3")
"snyckit" = @("0.11.9")
@pitchinnate
pitchinnate / gist:890f5375f5e788f5a84b1b0bc399feab
Last active October 3, 2024 15:27
Powershell Starship update terminal title to directory and running command
# show directory as title, last 2 directories, can change by changing 2 to something else
function Invoke-Starship-PreCommand {
$current = ( $PWD -split '\\' | select -last 2 ) -join '\'
$host.ui.RawUI.WindowTitle = "$current"
}
# normal starship invoke
Invoke-Expression (&starship init powershell)
# this must be put in after the invoke of starship
@pitchinnate
pitchinnate / laravel_windows_environment.md
Last active June 24, 2019 10:33
Laravel Windows Environment Setup

Keybase proof

I hereby claim:

  • I am pitchinnate on github.
  • I am pitchinnate (https://keybase.io/pitchinnate) on keybase.
  • I have a public key whose fingerprint is 1FDF 5FCB 5E36 DC8E 06DB E177 5F28 10C7 7265 B554

To claim this, I am signing this object:

@pitchinnate
pitchinnate / file.rb
Created June 8, 2016 17:03
Ruby Warrior
class Player
@hitBackWall = false
def play_turn(warrior)
taking_damage = false
if @health.nil?
@health = warrior.health
end