improve gitignore and seafile-ignore
This commit is contained in:
parent
e1683a2d0a
commit
2bc8b3c57e
@ -2,7 +2,7 @@ echo "***************************************"
|
||||
echo "find \$FOLDER -mindepth \$MINDEPTH -maxdepth \$MAXDEPTH -type d_f_l -name \"\$PATTERN\" | while read item; do echo \"\$item\"; done"
|
||||
echo "***************************************"
|
||||
|
||||
echo "To find in which path? Enter [root path] or [leave blank] for the current path:"
|
||||
echo "To find in which path? Enter [root path] or [leave blank] for the current path [[`pwd`]]:"
|
||||
read -p ">>> " FIND_FOLDER
|
||||
if [ ! "$FIND_FOLDER" ]
|
||||
then
|
||||
|
@ -59,7 +59,7 @@ echo ""
|
||||
|
||||
find . -mindepth 1 -maxdepth 3 -type d -name '[^.]*' | grep -E -v 'node_modules|uni_modules|\.deploy_git|\.git|.svn|\.vscode|\.wrangler|unpackage|_webroot|_logstore|_datasotre|_archive|_filestore|_ssl' | while read repo
|
||||
do
|
||||
if [ -f "$repo/.gitignore.local.txt" ] # some git repo need to keep privacy, therefore judge from .gitignore, not from .git
|
||||
if [ -f "$repo/.gitignore" ] # some git repo need to keep privacy, therefore judge from .gitignore, not from .git
|
||||
then
|
||||
echo "---- updating [[$repo/.gitignore]] ----"
|
||||
if [ -f "$IGNOREPATH" ]
|
||||
@ -68,7 +68,7 @@ do
|
||||
else
|
||||
curl -sSL $IGNOREPATH | cat > $repo/.gitignore
|
||||
fi
|
||||
cat $repo/.gitignore.local.txt 2>/dev/null > $repo/.gitignore
|
||||
cat $repo/.gitignore.local.txt 2>/dev/null >> $repo/.gitignore
|
||||
echo ""
|
||||
fi
|
||||
done
|
||||
|
@ -17,6 +17,8 @@
|
||||
*.gitomit.*
|
||||
*.gitomit.*/
|
||||
# 保留
|
||||
!.gitignore
|
||||
!.gitignore.*
|
||||
!.gitkeep
|
||||
|
||||
# 通用
|
||||
|
Loading…
Reference in New Issue
Block a user