Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

how to use gitignore to ignore a folder

You can ignore entire directories, just by including their paths and putting a / on the end:

1
2
node_modules/
logs/
Comment

gitignore folder

in .gitignore:
	folder/
Comment

gitignore exclude folder

# Ignore all directories, and all sub-directories, and it's contents:
*/*

#Now ignore all files in the current directory 
#(This fails to ignore files without a ".", for example 
#'file.txt' works, but 
#'file' doesn't):
*.*

#Only Include these specific directories and subdirectories:
!wordpress/
!wordpress/*/
!wordpress/*/wp-content/
!wordpress/*/wp-content/themes/
!wordpress/*/wp-content/themes/*
!wordpress/*/wp-content/themes/*/*
!wordpress/*/wp-content/themes/*/*/*
!wordpress/*/wp-content/themes/*/*/*/*
!wordpress/*/wp-content/themes/*/*/*/*/*
Comment

PREVIOUS NEXT
Code Example
Shell :: powershell clear command 
Shell :: php artisan doctrine migrations add all 
Shell :: windows cmd opens and closes 
Shell :: pull unmerged branch 
Shell :: delete command from history 
Shell :: assigning permissions to folder and files in linux 
Shell :: open directory 
Shell :: install kubectl on linux 
Shell :: intel pinning threads 
Shell :: Editing a Commit message 
Shell :: expo uninstall 
Shell :: bash count occurrences of string in array 
Shell :: linux change file owner 
Shell :: how to delete all history for specific search term in chrome 
Shell :: sudo apt install xfce4 xfce4-goodies -y 
Shell :: man in linux 
Shell :: django upgrade 
Shell :: how to unistall dependencies 
Shell :: copy from vim to clipboard 
Shell :: chmod recursive group read 
Shell :: install mtools 
Shell :: concat strings inside array bash script 
Shell :: Pull Ubuntu image 
Shell :: update branch with master 
Shell :: C linux compiler online 
Shell :: download clamav via terminal 
Shell :: git new branch from current 
Shell :: ubuntu theme change command 
Shell :: sudo !! alias 
Shell :: fix node gyp issue on linux 
ADD CONTENT
Topic
Content
Source link
Name
1+6 =