Skip to content

Instantly share code, notes, and snippets.

View mohitt's full-sized avatar
🎯
Focusing

Mohit Thakral mohitt

🎯
Focusing
View GitHub Profile
https://codesandbox.io/s/4lr7oxxrl7?file=/src/Hello.js:311-321
@mohitt
mohitt / setup-windows.ps1
Created February 25, 2020 21:14
Setting up windows
choco install -y vsvim
choco install -y resharper
choco install -y vscode
choco install -y jetbrains-resharper
choco install -y golang
# restart terminal
go get github.com/pcarrier/gauth
# get the gauth.csv file from .config folder to copy paste
choco install -y microsoft-windows-terminal
@mohitt
mohitt / _vsvimrc-resharper
Last active February 14, 2020 03:06
_vsvimrc_resharper
let mapleader="\<space>"
set clipboard=unnamed
nnoremap <leader>j :vsc Window.PreviousTab<CR>
nnoremap <leader>k :vsc Window.NextTab<CR>
nnoremap <leader>r :vsc Resharper.Resharper_GotoRecentFiles<CR>
nnoremap <leader>e :vsc Resharper.Resharper_GotoType<CR>
nnoremap <leader>f :vsc Resharper.Resharper_GotoFile<CR>
nnoremap <leader>d :vsc File.Close<CR>
@mohitt
mohitt / command.pwsh
Created January 8, 2020 21:51
Get process id for port
Get-Process -Id (Get-NetTCPConnection -LocalPort 5050).OwningProcess
@mohitt
mohitt / idea vim
Created December 17, 2019 20:40
ideavim
let mapleader=" "
nnoremap <Leader>ve :e c:\users\mohit.thakral\.ideavimrc<CR>
nnoremap <Leader>vl :source c:\users\mohit.thakral\.ideavimrc<CR>
set clipboard=unnamedplus,unnamed
set nu
set rnu
set is
"
nmap <Leader>f :action GotoFile<CR>
nmap <Leader>s :action FileStructurePopup<CR>
@mohitt
mohitt / another displayplacer.sh
Last active December 17, 2019 17:15
4 Monitors Display
displayplacer "id:0E0042C0-B227-4AD6-015B-5AF8116D137F res:1920x1080 hz:60 color_depth:4 scaling:off origin:(0,0) degree:0" "id:17E22855-A931-833E-8314-5CE8FFA63380 res:1920x1080 hz:60 color_depth:4 scaling:off origin:(0,-1080) degree:0" "id:D9534633-F47D-42FF-FA84-857343474BE8 res:1920x1080 hz:60 color_depth:4 scaling:off origin:(-1920,0) degree:0" "id:2131DD01-FB84-952C-5F7B-02BEEF31621F res:1920x1080 hz:60 color_depth:4 scaling:off origin:(-1920,-1080) degree:0"
@mohitt
mohitt / Powershell
Last active December 3, 2019 18:47
Delete All Windows Temp files
Set-Location “C:\Windows\Temp”
Remove-Item * -recurse -force
Set-Location “C:\Windows\Prefetch”
Remove-Item * -recurse -force
Set-Location “C:\Documents and Settings”
Remove-Item “.\*\Local Settings\temp\*” -recurse -force
Set-Location “C:\Users”
let mapleader=" "
nnoremap <Leader>ve :e ~/.ideavimrc<CR>
nnoremap <Leader>vl :source ~/.ideavimrc<CR>
set clipboard=unnamedplus,unnamed
set nu
set rnu
set is
"
nmap <Leader>f :action GotoFile<CR>
nmap <Leader>s :action FileStructurePopup<CR>
--- Actions ---
$Copy <M-C>
$Cut <M-X> <S-Del>
$Delete <Del> <BS> <M-BS>
$LRU
$Paste <M-V>
$Redo <M-S-Z> <A-S-BS>
$SearchWeb
$SelectAll <M-A>
$Undo <M-Z>
@mohitt
mohitt / webpack.dev.js
Created October 5, 2019 04:45
Headers for CORS
,
headers: {
"Access-Control-Allow-Origin": "*",
"Access-Control-Allow-Methods":
"GET, POST, PUT, DELETE, PATCH, OPTIONS",
"Access-Control-Allow-Headers":
"X-Requested-With, content-type, Authorization"
}