■PowerShell用
◇強調キーワード定義
基本
コマンドレットキーワードより大きな数字の強調キーワードに設定すること。
PowerShell基本.kwd
// PowerShell基本 キーワード定義ファイル
// CASE=False
param
if
elseif
else
switch
default
and
or
not
band
bor
bnot
bxor
shl
shr
is
isnot
as
do
while
for
until
foreach
in
break
continue
exit
eq
ieq
ceq
ne
ine
cne
gt
igt
cgt
ge
ige
cge
lt
ilt
clt
le
ile
cle
like
ilike
clike
notlike
inotlike
cnotlike
match
imatch
cmatch
notmatch
inotmatch
cnotmatch
try
catch
finally
型
PowerShell型.kwd
// PowerShell型 キーワード定義ファイル
// CASE=False
array
bool
byte
char
datetime
decimal
double
float
guid
hashtable
int16
int32
int64
int
long
nullable
psobject
regex
sbyte
scriptblock
single
string
switch
timespan
type
uint16
uint32
uint64
xml
コマンドレット
基本キーワードより小さな数字の強調キーワードに設定すること。
PowerShellコマンドレット.kwd
// PowerShellコマンドレット キーワード定義ファイル
// CASE=False
Add-Computer
Add-Content
Add-History
Add-LocalGroupMember
Add-Member
Add-PSSnapin
Add-Type
Checkpoint-Computer
Clear-Content
Clear-EventLog
Clear-History
Clear-Item
Clear-ItemProperty
Clear-RecycleBin
Clear-Variable
Compare-Object
Complete-Transaction
Connect-PSSession
Connect-WSMan
Convert-Path
Convert-String
ConvertFrom-Csv
ConvertFrom-Json
ConvertFrom-SecureString
ConvertFrom-String
ConvertFrom-StringData
ConvertTo-Csv
ConvertTo-Html
ConvertTo-Json
ConvertTo-SecureString
ConvertTo-Xml
Copy-Item
Copy-ItemProperty
Debug-Job
Debug-Process
Debug-Runspace
Disable-ComputerRestore
Disable-LocalUser
Disable-PSBreakpoint
Disable-PSRemoting
Disable-PSSessionConfiguration
Disable-RunspaceDebug
Disable-WSManCredSSP
Disconnect-PSSession
Disconnect-WSMan
Enable-ComputerRestore
Enable-LocalUser
Enable-PSBreakpoint
Enable-PSRemoting
Enable-PSSessionConfiguration
Enable-RunspaceDebug
Enable-WSManCredSSP
Enter-PSHostProcess
Enter-PSSession
Exit-PSHostProcess
Exit-PSSession
Export-Alias
Export-Clixml
Export-Console
Export-Counter
Export-Csv
Export-FormatData
Export-ModuleMember
Export-PSSession
ForEach-Object
Format-Custom
Format-List
Format-Table
Format-Wide
Get-Acl
Get-Alias
Get-AuthenticodeSignature
Get-ChildItem
Get-Clipboard
Get-CmsMessage
Get-Command
Get-ComputerInfo
Get-ComputerRestorePoint
Get-Content
Get-ControlPanelItem
Get-Counter
Get-Credential
Get-Culture
Get-Date
Get-Event
Get-EventLog
Get-EventSubscriber
Get-ExecutionPolicy
Get-FormatData
Get-Help
Get-History
Get-Host
Get-HotFix
Get-Item
Get-ItemProperty
Get-ItemPropertyValue
Get-Job
Get-LocalGroup
Get-LocalGroupMember
Get-LocalUser
Get-Location
Get-Member
Get-Module
Get-PSBreakpoint
Get-PSCallStack
Get-PSDrive
Get-PSHostProcessInfo
Get-PSProvider
Get-PSSession
Get-PSSessionCapability
Get-PSSessionConfiguration
Get-PSSnapin
Get-PfxCertificate
Get-Process
Get-Random
Get-Runspace
Get-RunspaceDebug
Get-Service
Get-TimeZone
Get-TraceSource
Get-Transaction
Get-TypeData
Get-UICulture
Get-Unique
Get-Variable
Get-WSManCredSSP
Get-WSManInstance
Get-WinEvent
Get-WmiObject
Group-Object
Import-Alias
Import-Clixml
Import-Counter
Import-Csv
Import-LocalizedData
Import-Module
Import-PSSession
Invoke-Command
Invoke-Expression
Invoke-History
Invoke-Item
Invoke-RestMethod
Invoke-WSManAction
Invoke-WebRequest
Invoke-WmiMethod
Join-Path
Limit-EventLog
Measure-Command
Measure-Object
Move-Item
Move-ItemProperty
New-Alias
New-Event
New-EventLog
New-FileCatalog
New-Item
New-ItemProperty
New-LocalGroup
New-LocalUser
New-Module
New-ModuleManifest
New-Object
New-PSDrive
New-PSRoleCapabilityFile
New-PSSession
New-PSSessionConfigurationFile
New-PSSessionOption
New-PSTransportOption
New-Service
New-TimeSpan
New-Variable
New-WSManInstance
New-WSManSessionOption
New-WebServiceProxy
New-WinEvent
Out-Default
Out-File
Out-GridView
Out-Host
Out-Null
Out-Printer
Out-String
Pop-Location
Protect-CmsMessage
Push-Location
Read-Host
Receive-Job
Receive-PSSession
Register-ArgumentCompleter
Register-EngineEvent
Register-ObjectEvent
Register-PSSessionConfiguration
Register-WmiEvent
Remove-Computer
Remove-Event
Remove-EventLog
Remove-Item
Remove-ItemProperty
Remove-Job
Remove-LocalGroup
Remove-LocalGroupMember
Remove-LocalUser
Remove-Module
Remove-PSBreakpoint
Remove-PSDrive
Remove-PSSession
Remove-PSSnapin
Remove-TypeData
Remove-Variable
Remove-WSManInstance
Remove-WmiObject
Rename-Computer
Rename-Item
Rename-ItemProperty
Rename-LocalGroup
Rename-LocalUser
Reset-ComputerMachinePassword
Resolve-Path
Restart-Computer
Restart-Service
Restore-Computer
Resume-Job
Resume-Service
Save-Help
Select-Object
Select-String
Select-Xml
Send-MailMessage
Set-Acl
Set-Alias
Set-AuthenticodeSignature
Set-Clipboard
Set-Content
Set-Date
Set-ExecutionPolicy
Set-Item
Set-ItemProperty
Set-LocalGroup
Set-LocalUser
Set-Location
Set-PSBreakpoint
Set-PSDebug
Set-PSSessionConfiguration
Set-Service
Set-StrictMode
Set-TimeZone
Set-TraceSource
Set-Variable
Set-WSManInstance
Set-WSManQuickConfig
Set-WmiInstance
Show-Command
Show-ControlPanelItem
Show-EventLog
Sort-Object
Split-Path
Start-Job
Start-Process
Start-Service
Start-Sleep
Start-Transaction
Start-Transcript
Stop-Computer
Stop-Job
Stop-Process
Stop-Service
Stop-Transcript
Suspend-Job
Suspend-Service
Tee-Object
Test-ComputerSecureChannel
Test-Connection
Test-FileCatalog
Test-ModuleManifest
Test-PSSessionConfigurationFile
Test-Path
Test-WSMan
Trace-Command
Unblock-File
Undo-Transaction
Unprotect-CmsMessage
Unregister-Event
Unregister-PSSessionConfiguration
Update-FormatData
Update-Help
Update-List
Update-TypeData
Use-Transaction
Wait-Debugger
Wait-Event
Wait-Job
Wait-Process
Where-Object
Write-Debug
Write-Error
Write-EventLog
Write-Host
Write-Information
Write-Output
Write-Progress
Write-Verbose
Write-Warning
◇正規表現キーワード
PowerShell.rkw
// 正規表現キーワード Ver1
RxKey[000]=RK1,/^\s*function\s+.+$/ki
RxKey[001]=RK5,/[\$\|>`]/k
◇アウトラインルール
PowerShell.rule
;Mode=RegexReplace
;RegexOption=i
;Title=PowerShell
^\s*(function)\s+([^\s\({]+) /// $2() /// FUNC,Level=1
^\s*(for)\s*(\(.+$) /// $1 $2 /// LOOP,Level=2
^\s*(foreach)\s*(\(.+$) /// $1 $2 /// LOOP,Level=2
^\s*(while)\s*(\(.+$) /// $1 $2 /// LOOP,Level=2
^\s*(.+\sForEach-Object)\s*(.+$) /// $1 $2 /// LOOP,Level=2
◇キーワードヘルプ
PowerShell辞書1.khp
// キーワード辞書設定 Ver1
eq,ieq,cep /// =
ne,ine,cne /// ≠
gt,igt,cgt /// >
ge,ige,cge /// ≧
lt,ilt,clt /// <
le,ile,cle /// ≦
■Markdown用
◇アウトラインルール
Markdown.rule
;Mode=RegexReplace
;Title=Markdown
^#\s*([^#].*$) /// $1 /// Headline,Lv=1
^##\s*([^#].*$) /// $1 /// Headline,Lv=2
^###\s*([^#].*$) /// $1 /// Headline,Lv=3
^####\s*([^#].*$) /// $1 /// Headline,Lv=4
^#####\s*([^#].*$) /// $1 /// Headline,Lv=5
^######\s*([^#].*$) /// $1 /// Headline,Lv=6
メモ
- キーワード定義
- タイプ別設定 → カラー → 強調キーワード → 共通設定
- 正規表現キーワード
- タイプ別設定 → 正規表現キーワード
- アウトラインルール
- タイプ別設定 → スクリーン → アウトライン解析方法 → ルールファイル
- キーワードヘルプ
- タイプ別設定 → キーワードヘルプ