Last Updated: February 25, 2016
·
2.715K
· rafaelune

Creating .gitignore file through command line on Windows

Here's a sample command line to create .gitignore files.

@echo off
(
echo *.log
echo localsettings.config
echo dir
name
) > .gitignore

And if you wanna see your command line back to normal again.

@echo on


Update
'@copy con .gitignore' then type your lines, Ctrl-Z, Enter. Works too!
Thanks @traeblain