BNF vs EBNF vs ABNF: which to choose?

You have to think about EBNF and ABNF as extensions that help you just to be more concise and expressive while developing your grammars. For example think about an optional non-terminal symbol, in a BNF grammar you would define it by using intermediate symbols like: A ::= OPTIONAL OTHER OPTIONAL ::= opt_part | epsilon while … Read more

conditional execution (&& and ||) in powershell

2019: the Powershell team are considering adding support for && to Powershell – weigh in at this GitHub PR Try this: $(command -arg1 -arg2 | Out-Host;$?) -and $(command2 -arg1 | Out-Host;$?) The $() is a subexpression allowing you to specify multiple statements within including a pipeline. Then execute the command and pipe to Out-Host so … Read more

AutoHotkey syntax highlighting in Notepad++

Thanks to jNizM for their helpful guide on the AHK forums. Setup Notepad++ for AutoHotkey Syntax-Highlighting Download userDefineLang_AHK.xml as raw (Right-click and choosing save as target…) Start Notepad++ and click on Menu Language -> Define your language Click Import… and select the file you downloaded in step 1 Restart Notepad++ Default Theme (Preview) Lazy Theme … Read more

Elasticsearch query on a specific index

Heres curl example what works, and allows you to search multiple indexes: curl ‘http://localhost:9200/myindex1,myindex2/_search?q=*’ For single specific index: curl ‘http://localhost:9200/myindex1/_search?q=*’ To find find index names: curl ‘localhost:9200/_cat/indices’ And if you want to search all indexes: curl ‘localhost:9200/_search?pretty’

Tab space in Markdown

This can be helpful Type nbsp to add a single space. Type ensp to add 2 spaces. Type emsp to add 4 spaces. You can use non-breaking space (nbsp) 4 times to insert a tab. Please append & in the beginning and ; in the end of the above suggested space syntax

Why do some Vim mappings include after a colon?

That isn’t part of the syntax for the onoremap command, that is explaining what a particular mapping does. That mapping is: onoremap <silent> F :<C-U>normal! 0f(hviw<CR> So, when the F key is used while an operator is pending vim will replace that with the bits in the next argument to the onoremap command. That starts … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)