The certificate will be an Encrypting File System (EFS) self-signed smart card certificate.
- Control Panel > User Accounts > Manage your file encryption certificates
Create new and store locally
<# | |
Given the list of folders and the dates over which to check then this script | |
will group the files by month for each folder between the given dates and get | |
the sum of the file sizes. So you will get a calculated property of 'folder', | |
'month', 'size' (where file size is in MB to two decimal places). Then that | |
calculated property is grouped by 'folder' and the cumulative file size over the | |
selected months is averaged. So you will have a calculated property of 'folder', | |
'monthly' (where 'monthly' is a monthly average in MB). | |
#> | |
$archives = @{ |
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. | |
; #Warn ; Enable warnings to assist with detecting common errors. | |
SendMode Input ; Recommended for new scripts due to its superior speed and reliability. | |
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. | |
; Colemak Mod-DH angle wide mapping for ANSI boards | |
SC029::Esc | |
;SC002::1 | |
;SC003::2 |
If you have a code-base under source control that is internal to your company, for instance, it's hosted on premises, you may have checked in some secrets in your configuration files. We all know we should have had those encrypted or kept outside of the checked-in source in some way but perhaps it was just better to accrue some technical debt and worry about it later. Okay, now it's later.
Windows Registry Editor Version 5.00 | |
; The hex data is in five groups of four bytes: | |
; 00,00,00,00,\ header version (always 00000000) | |
; 00,00,00,00,\ header flags (always 00000000) | |
; 02,00,00,00,\ # of entries (1 in this case) plus a NULL terminator line. | |
; Entries are in 2-byte pairs: Key code to send & keyboard key to send it. | |
; Each entry is in LSB, MSB order. | |
; 01,00,3a,00,\ Send ESC (0x0001) code when user presses the CAPS LOCK key (0x003a) | |
; 00,00,00,00 NULL terminator |
Import-Module SqlServer | |
$srv = New-Object Microsoft.SqlServer.Management.Smo.Server("(local)") | |
$db = $srv.Databases.Item("IntermediaryManagement.DB") | |
$scrp = New-Object Microsoft.SqlServer.Management.Smo.Scripter($srv) | |
$scrp.Options.ScriptData = $TRUE | |
$scrp.Options.ScriptSchema = $FALSE | |
$tbl = $db.tables | Where-Object { $_.IsSystemObject -eq $FALSE } | |
$scrp.EnumScript(@($tbl)) | %{ Add-Content temp.sql $_ } |
// .csproj | |
// <PackageReference Include="System.Data.SqlClient" Version="4.3.0" /> | |
// <PackageReference Include="System.Reflection.TypeExtensions" Version="4.3.0" /> | |
namespace HorribleThingsInHere | |
{ | |
using System.Data.SqlClient; | |
using System.Linq; | |
using System.Reflection; |
public struct Option<T> | |
{ | |
private readonly T _value; | |
public T Value | |
{ | |
get | |
{ | |
if (!HasValue) | |
throw new InvalidOperationException(); |
Install-Module Pscx | |
Install-Module posh-git | |
Install-Module PSReadLine | |
Install-Module PSake | |
Install-Module Pester |