Thursday, May 26, 2016

Adding alias in windows like in Linux

Here doskey cmd is used to set alias.
All alias set using 'doskey' are temporary, once you reopen a new cmd window its gone.

Let see how to set alias like in linux we save it in .bashrc file

IN WINDOWS
First open a notepad and past below commands to test

doskey ls=dir
doskey !=ping google.com -t
doskey mv=ren

save it as alias.cmd,
Open your run window and type %appdata% then enter. Copy the alias.cmd file to this Appdata-Roming folder.

Open regdit from your run window.
Go to HKEY_CURRENT_USER\SOFTWARE\Microsoft\Command Processor
Select 'Command processor' Folder and on the right side of window, Right click - New-Expandable string value
Give 'Name' as AutoRun, then right click and modify value as  "%AppData%\alias.cmd"

That's it! Now go to cmd prompt and do
ls and see it its working.

CSS tricks

Mixed paint in background: background: linear-gradient(to right, #b6e358, #38b143) Grid view: display: grid; grid-template-columns: a...