“Git abaikan kecuali” Kode Jawaban

Git abaikan kecuali

# Skip all files
*

# But not `aDir/anotherDir/someOtherDir/aDir/bDir/cDir/a.txt`
!aDir/
aDir/*
!aDir/anotherDir/
aDir/anotherDir/*
!aDir/anotherDir/someOtherDir/
aDir/anotherDir/someOtherDir/*
!aDir/anotherDir/someOtherDir/aDir/
aDir/anotherDir/someOtherDir/aDir/*
!aDir/anotherDir/someOtherDir/aDir/bDir/
aDir/anotherDir/someOtherDir/aDir/bDir/*
!aDir/anotherDir/someOtherDir/aDir/bDir/cDir/
aDir/anotherDir/someOtherDir/aDir/bDir/cDir/*
!aDir/anotherDir/someOtherDir/aDir/bDir/cDir/a.txt
Outrageous Ostrich

gitignore abaikan semuanya kecuali

# ignore everything in current directory
/*

# !pattern now negates the "ignore everything" and keeps 'pattern'

# keep .gitignore
!.gitignore 

# keep mydirectory, along with everything inside it 
!mydirectory/
Gifted Gull

.gitignore semuanya kecuali

# Ignore everything
*

# But not these files...
!.gitignore
!script.pl
!template.latex
# etc...

# ...even if they are in subdirectories
!*/

# if the files to be tracked are in subdirectories
!*/a/b/file1.txt
!*/a/b/c/*
slohobo

Jawaban yang mirip dengan “Git abaikan kecuali”

Pertanyaan yang mirip dengan “Git abaikan kecuali”

Lebih banyak jawaban terkait untuk “Git abaikan kecuali” di Shell/Bash

Jelajahi jawaban kode populer menurut bahasa

Jelajahi bahasa kode lainnya