----- Tech -----
拡張現実【かくちょうげんじつ】 augmented reality, AR
投資家【とうしか】 investor
静的【せいてき】 static
| # 配置 Emacs 输入模式 | |
| Set-PSReadLineOption -EditMode Emacs | |
| # https://github.com/Canop/broot/issues/159 | |
| function br { | |
| $tempFile = New-TemporaryFile | |
| try { | |
| $broot = $env:BROOT |
----- Tech -----
拡張現実【かくちょうげんじつ】 augmented reality, AR
投資家【とうしか】 investor
静的【せいてき】 static
| 我本想享受生活,结果发现活下来都很困难。 | |
| 你的计划,就像零食,吃到肚子里之后就是个屁。 | |
| 我已经不是那个花五十块钱,也要考虑很久的小孩了,现在五块钱都要深思熟虑。 | |
| 今天天气很好,在房间里宅久了,准备去客厅散散心。 | |
| 春节你要小心了,毕竟过年,都是要杀猪的。 | |
| 经过多年的打拼,虽然没有什么收获,但你有债呀! | |
| 人为什么叫人类,因为人活着就是累。 | |
| 说错话不要紧,你还会继续说错的。 | |
| 你倒下了,能顶替你的人千千万 | |
| 你获得了很多金钱,但同时也失去了很多东西,比如烦恼。 |
| <# | |
| TechNet Contribution: Convert Alphanumeric String to the NATO Phonetic Alphabet Equivalent | |
| Previous link: https://gallery.technet.microsoft.com/Convert-Alphanumeric-8c1d6a79 | |
| Downloaded: 858 times (as of 05/21/2020) | |
| There was a post in the TechNet Forum about needing a solution to convert a string into the NATO phonetic alphabet | |
| equivalent (link). I really liked the project and quickly wrote out an advanced function in Windows PowerShell to | |
| accompany the VBS solution that was also posted. Please let me know if there are any problems that need correcting. | |
| The 1.3 version will speak the results, if the -Speak switch parameter is included when the function is run. |
| function Set-WindowState { | |
| <# | |
| .LINK | |
| https://gist.github.com/Nora-Ballard/11240204 | |
| #> | |
| [CmdletBinding(DefaultParameterSetName = 'InputObject')] | |
| param( | |
| [Parameter(Position = 0, Mandatory = $true, ValueFromPipeline = $true)] | |
| [Object[]] $InputObject, |
| local UP = hs.keycodes.map['up'] | |
| local DOWN = hs.keycodes.map['down'] | |
| local LEFT = hs.keycodes.map['left'] | |
| local RIGHT = hs.keycodes.map['right'] | |
| local RETURN = hs.keycodes.map['return'] | |
| function hasCmd(event) | |
| local flags = event:getFlags() | |
| return flags.cmd and not (flags.alt or flags.ctrl or flags.shift) | |
| end |
From: http://stackoverflow.com/questions/1676632/whats-a-quick-way-to-comment-uncomment-lines-in-vim
For those tasks I use most of the time block selection.
Put your cursor on the first # character, press Ctrl``V (or Ctrl``Q for gVim), and go down until the last commented line and press x, that will delete all the # characters vertically.
For commenting a block of text is almost the same: First, go to the first line you want to comment, press Ctrl``V, and select until the last line. Second, press Shift``I``#``Esc (then give it a second), and it will insert a # character on all selected lines. For the stripped-down version of vim shipped with debian/ubuntu by default, type : s/^/# in the second step instead.
| %s/<!--\_.\{-}-->//g |
| //http://stackoverflow.com/questions/105034/how-to-create-a-guid-uuid-in-javascript | |
| Math.random().toString(36).substring(2, 15) + Math.random().toString(36).substring(2, 15); |