From a4d7f9d033122b68e4841e5aa96497571e1df639 Mon Sep 17 00:00:00 2001 From: Friedrich von Never Date: Mon, 6 Nov 2023 23:35:41 +0100 Subject: [PATCH] Clean up parser_todos They all are done at this moment. --- parser_todos/sample1.ps1 | 52 ---------------------------------------- 1 file changed, 52 deletions(-) delete mode 100644 parser_todos/sample1.ps1 diff --git a/parser_todos/sample1.ps1 b/parser_todos/sample1.ps1 deleted file mode 100644 index 931f4628..00000000 --- a/parser_todos/sample1.ps1 +++ /dev/null @@ -1,52 +0,0 @@ -#1) value expression in single line 2) cmdlet name token -foreach ($i in get-childitem | sort-object length) - { - $i #highlight - $sum += $i.length - } - -# 3) variable name token: '$_.length ' and 'get-childitem' -switch -regex -casesensitive (get-childitem | sort length) -{ - "^5" {"length for $_ started with 5" ; continue} - { $_.length > 20000 } {"length of $_ is greater than 20000"} - default {"Didn't match anything else..."} -} - -# 4) statement termination by new line: -while ($i -lt 100) - { - echo i is $i - $i -= 1 - } - - -# 5) param argument name and cmdlets -#Here are examples showing what pipelines may look like: - get-childitem -recurse -filter *.ps1 | sort name - (2+3),3,4 | sort - & "c:\a path\with spaces.ps1" | % { $_.length } - get-childitem | sort-object > c:/tmp/junk.txt - -Get-Process | Where {$_.PM -gt 100MB} - -# 6) parameter names (DS_ALNUM) -param ([string]$str, [int]$start_pos = 0) -1 - - -# 7) variable variable names: -$totalCost -$Maximum_Count_26 -$végösszeg # Hungarian -$итог # Russian -$総計 # Japanese (Kanji) -${Maximum_Count_26} -${Name with`twhite space and `{punctuation`}} -${E:\File.txt} - -# 8) verbatim command argument: -echoargs.exe --% "%path%" # %path% is replaced with the value $env:path - -# 9) command name token: -echoargs.exe "my arg value" \ No newline at end of file