Skip to content

Instantly share code, notes, and snippets.

View atrenton's full-sized avatar
💭
"It’s not what we make. It’s what we make possible."

Art Trenton atrenton

💭
"It’s not what we make. It’s what we make possible."
View GitHub Profile
@atrenton
atrenton / Start-Custom-Scan.md
Created January 4, 2023 16:53
Start Windows Defender Custom Scan

The following script runs a custom Windows Defender scan on multiple drives with exclusions.

👉 NOTE: Since this is a long-running script, be sure to turn off the Sleep setting for your computer before you run it.

Windows 10 procedure to change the Sleep setting to 'Never'

  1. Navigate to Settings > System > Power & sleep
  2. Click the drop-down setting for Sleep and change it to Never

✅ Don't forget to restore your system Sleep setting preference when the script finishes

@atrenton
atrenton / Upgrade-PowerShell-7-x86.md
Created December 31, 2022 17:34
Upgrade PowerShell 7-x86

The following script will automatically download and install the latest x86 version of PowerShell 7.

# Upgrade-PowerShell.ps1
# REF: https://community.idera.com/database-tools/powershell/powertips/b/tips/posts/resolving-urls-3
#requires -version 7.0

$Params = @{
    Method = 'HEAD'
@atrenton
atrenton / Create-SelfSigned-Certificate.ps1
Created August 18, 2020 22:32
Create self-signed code signing certificate with PowerShell
# Create-SelfSigned-Certificate.ps1
#requires -Version 5
#-------------------------------------------------------------------------------
# Create self signed code signing certificate
# REF: https://docs.microsoft.com/en-us/windows/uwp/packaging/create-certificate-package-signing
#-------------------------------------------------------------------------------
Import-Module PKI
$storeLocation = 'cert:\CurrentUser\My'
@atrenton
atrenton / 0_MyJournal-Notebook-Organization.md
Last active October 23, 2019 18:37
MyJournal.Notebook Add-in for OneNote — Organizational Structure
  1. Notebook

    • Name: My Journal
    • Type: Directory
    • Location: Documents » OneNote Notebooks » My Journal
  2. Section Group

    • Name: Year (4-digit YYYY format)
    • Type: Directory
    • Location: Documents » OneNote Notebooks » My Journal » YYYY
@atrenton
atrenton / keybase.md
Created October 2, 2019 22:58
Keybase proof

Keybase proof

I hereby claim:

  • I am atrenton on github.
  • I am atrenton (https://keybase.io/atrenton) on keybase.
  • I have a public key ASDt4J0sK3Arxh44DwIgejQE0D3TGlWYYll7GPFisQ9woQo

To claim this, I am signing this object:

@atrenton
atrenton / Dotnet-Create-Win32-Classlib-Solution.ps1
Created April 19, 2019 19:04
PowerShell script: Use dotnet CLI to create a Windows 32-bit C# class library solution
# Dotnet-Create-Win32-Classlib-Solution.ps1
# Uses dotnet CLI to create a Windows 32-bit C# class library solution
function not-exist { -not (Test-Path $args) }
Set-Alias !exist not-exist -Option "Constant, AllScope"
Set-Alias exist Test-Path -Option "Constant, AllScope"
# TODO: Configure
$classlib = '32-bit' # project subdirectory (I.E. ~\src\32-bit)
$repoName = 'Windows.Classlib' # C# project namespace