This is a list of the name and values for the units by unit type.
| NAME ( human readable ) | VALUE ( to store in databases or use in code ) | Historical names, Common names, Acronyms ( CSV initially and may be used to look up the value ) |
| As if! |
| Contact point, Status, Email | |
| [email protected] | |
| [email protected] | |
| [email protected] | |
| [email protected] | |
| [email protected] | |
| [email protected] | |
| [email protected] | |
| [email protected] | |
| [email protected] |
|  | |
| You | |
| how to make a command to run from a windows terminal with powershell core 7.x so that I can do \`gitreplace <file\_path>\` and it have it go to the file and ultimately be running something like \` curl -L -o "ROADMAP.md" "https://raw.githubusercontent.com/{user}/{repo}/{branch}/ROADMAP.md"\` where the values for \`{user}\` and so on, are discern from git or the folders and file directly around the file(ie: the repo the file belongs to). I am surprised this is not already baked in .. is there an already done solution out there ? other ways please proceed | |
| ChatGPT | |
| ChatGPT |
| & { param($excludeLogs) $d = Get-Date -Format "yyyy-MM-dd-HH-mm"; $zipPath = "D:\_audit\logs\Foo-$d.zip"; $errorLog = "D:\_audit\logs\ErrorLog-$d.txt"; $logDir = "D:\_audit\logs\Foo-$d"; $null = New-Item -ItemType Directory -Force -Path $logDir; $counter = 0; $total = (wevtutil.exe el).Count; wevtutil.exe el | ForEach-Object { $counter++; if ($Host.UI.RawUI) { Write-Progress -Activity "Processing Event Logs" -Status "$_ Processing" -PercentComplete (($counter / $total) * 100); } $time = Measure-Command { if ($_ -notin $excludeLogs) { try { $log = Get-WinEvent -LogName $_ -MaxEvents 1 -Oldest -ErrorAction SilentlyContinue; } catch { $_ >> $errorLog; continue } if ($log) { $logPath = "$logDir\$d-$($_.Replace('/', '-'))-bk.evtx"; Remove-Item -Path $logPath -ErrorAction SilentlyContinue; try { $exportResult = wevtutil.exe epl "$_" $logPath 2>&1; if ($LASTEXITCODE -eq 0) { try { Compress-Archive -Path $logPath -DestinationPath $zipPath -Update -CompressionLevel Optimal; } catch { $_ >> $errorLog; continue }; try |
| function Get-ZipFiles { | |
| param ( | |
| [string]$Path = (Get-Location), | |
| [string]$GitIgnorePath = (Join-Path -Path (Get-Location) -ChildPath ".gitignore") | |
| ) | |
| # Read .gitignore file | |
| $gitIgnorePatterns = Get-Content -Path $GitIgnorePath | Where-Object { |
| {"lastUpload":"2020-01-08T10:54:06.695Z","extensionVersion":"v3.4.3"} |
| var values = new[] | |
| { | |
| new[] { 1, 2 }, | |
| new[] { 2, 3 }, | |
| new[] { 4, 5 }, | |
| }; | |
| var flattenedUniqueValues = values.SelectMany(x => x).Distinct();//technically it handles none int too |
| (function( window, $, WSU ){ | |
| WSU.time = null; | |
| WSU.timer = function( time, callback){ | |
| console.log("clear old timer"); | |
| window.clearTimeout(WSU.time); | |
| WSU.time = null; | |
| console.log("set timer"); | |
| WSU.time = window.setInterval(function(){ | |
| console.log("do timer callback"); | |
| if( "function" === typeof callback){ |
| [alias] | |
| pushdoc = "!f(){ git add -A; git commit -m ${0} && git push; };f" |