2013-04-05 54 views
4

我正在使用WebDAV服务器来呈现虚拟文件系统中数据库的信息。实现虚拟文件系统时可以安全忽略的各种系统文件的列表

因此,用户可以在服务器上创建文件,并自动创建回db。

现在,只要用户连接到服务器时,一些操作系统倾向于立即创建自己的元数据文件/文件夹(思考的Thumbs.db,desktop.ini的,.fseventsd,DS_Store,...)

该文件弄乱数据库 - 而且往往以降低性能太(OSX例如只要打开文件夹做了很多索引,这意味着吨命中针对数据库)

所以演出和清洁的缘故我正在寻找由各种操作系统创建的(元)文件/文件夹的“完整”列表 - 这是“安全的”,被服务器压制。

我的名单至今:

//TODO: get rid of system files 
/* 
*** everywhere 
* Thumbs.db 
* desktop.ini 
* .DS_Store 
* .desktop 
* AlbumArt*.jpg 
* Folder.jpg 
* ._[ParentFoldername] // e.g. /foo/bar/._bar 
* ._[ExistingFoldername] // e.g. /foo/._bar 
* ._[ExistingFilename] // e.g. /foo/bar/._baz (baz is a legit file inside bar) 
* ._.     // ?!? 
*** root only 
* System Volume Information 
* .fseventsd 
* $recycling.bin 
* $Recycle.Bin 
* Recycled 
* .Trashes 
* hiberfil.sys 
* pagefile.sys 
* .hidden 
* mach_kernel 
* Backups.backupdb 
* Contents 
* 
*** special 
* .metadata_never_index // fake this file in root 
*      // (should keep OSX from indexing) 
*/ 

我现有的测试结构OSX是:打开/ MarioDemo /时

/MarioDemo/ 
/FrankTest/ 
/TestItemRelation/ 

/.metadata_never_index 

/MarioDemo/Alphabetical/ 
/MarioDemo/Hierarchical/ 

这里的文件OSX请求:

propfinds from OSX

+0

给我最好的,希望有助于使你感觉舒适; d – santa 2013-10-24 07:51:19

+0

肯定的是,我*可能*放过讽刺,另一方面手... :) – santa 2013-10-25 13:25:56

回答

3

我想你的名单已经很完整了。我只想补充以下,除非您特别想筛选出特定的文件类型:

.DS_Store? 
._* 
.Spotlight-V100 
.DocumentRevisions-V100 
.fseventsd 
.MobileBackups 
Icon? 
__MACOSX 
ehthumbs.db 
desktop.ini 
*.desktop 
*.bak 
.*~ 
*~ 

我把这些从一个名为Ignoramus项目。具有模式的相关文件是here,采用emacs格式。精确匹配列表如下印刷,这就是我把这些来自:

"$RECYCLE.BIN"       ; ms-windows 
".AppleDouble"       ; OS X 
".DS_Store"       ; OS X 
".DocumentRevisions-V100"    ; OS X 
".LSOverride"       ; OS X 
".Rhistory"       ; R 
".Spotlight-V100"      ; OS X 
".TemporaryItems"      ; OS X 
".Trashes"        ; OS X 
".actionScriptProperties"    ; actionscript 
".apt_generated"      ; gwt 
".build"        ; perl 
".buildpath"       ; eclipse 
".builds"        ; visualstudio 
".bzr"         ; bazaar 
".cdv"         ; codeville 
".classpath"       ; eclipse 
".com.apple.timemachine.donotpresent" ; OS X 
".com.apple.timemachine.supported"  ; OS X 
".coverage"       ; python 
".cproject"       ; eclipse 
".directory"       ; KDE 
".dropbox"        ; dropbox 
".dropbox.cache"      ; dropbox 
".emacs.desktop"      ; emacs desktop.el 
".emacs.desktop.lock"     ; emacs desktop.el 
".eunit"        ; erlang 
".externalToolBuilders"    ; eclipse 
".flexProperties"      ; actionscript 
".fseventsd"       ; OS X 
".git"         ; git 
".hg"         ; mercurial 
".idea"        ; various 
".ido.last"       ; emacs ido-mode 
".last_cover_stats"     ; perl 
".lein-deps-sum"      ; leiningen 
".loadpath"       ; eclipse 
".netrwhist"       ; vim 
".org-id-locations"     ; emacs org-mode 
".pc"         ; quilt 
".project"        ; eclipse 
".projectile"       ; emacs projectile 
".recentf"        ; emacs recentf 
".redcar"        ; redcar 
".rspec"        ; rails 
".sass-cache"       ; sass 
".scala_dependencies"     ; scala 
".svn"         ; subversion 
".tox"         ; python 
".wmncach.el"       ; emacs WoMan 
".yardoc"        ; yard 
"_MTN"         ; monotone 
"__history"       ; delphi 
"_build"        ; perl 
"_cgo_defun.c"       ; go 
"_cgo_gotypes.go"      ; go 
"_darcs"        ; darcs 
"_obj"         ; go 
"_sgbak"        ; vault 
"_site"        ; jekyll 
"_test"        ; go 
"_testmain.go"       ; go 
"_yardoc"        ; yard 
"aclocal.m4"       ; automake 
"auto-save-list"      ; emacs 
"autom4te.cache"      ; autoconf 
"bin-debug"       ; various 
"bin-release"       ; various 
"blib"         ; perl 
"build"        ; various 
"Build"        ; various 
"Build.bat"       ; perl 
"COMMIT_EDITMSG"      ; git 
"cmake_install.cmake"     ; cmake 
"CMakeCache.txt"      ; cmake 
"CMakeFiles"       ; cmake 
"cover_db"        ; perl 
"cscope.csd"       ; cscope 
"cscope.files"       ; cscope 
"cscope.inc"       ; cscope 
"cscope.lst"       ; cscope 
"cscope.out"       ; cscope 
"cscope.out.po"      ; cscope 
"cscope.tmplist"      ; cscope 
"CVS"         ; CVS 
"Debug"        ; various 
"debug"        ; various 
"depcomp"        ; automake 
"DerivedData"       ; xcode 
"Desktop.ini"       ; ms-windows 
"ehthumbs.db"       ; ms-windows 
"git-rebase-todo"      ; git 
"gwt-unitCache"      ; gwt 
"gwt_bree"        ; gwt 
"install-sh"       ; automake 
"install_manifest.txt"     ; cmake 
"InstalledFiles"      ; ruby 
"Makefile.in"       ; automake 
"MCVS"         ; meta-CVS 
"META.yml"        ; perl 
"MERGE_MSG"       ; git 
"minimal-session-saver-data.el"  ; emacs minimal-session-saver 
"MYMETA.yml"       ; perl 
"nbbuild"        ; netbeans 
"nbdist"        ; netbeans 
"nosetests.xml"      ; python 
"pm_to_blib"       ; perl 
"Profile"        ; various 
"profile"        ; various 
"RCS"         ; RCS 
"Release"        ; various 
"release"        ; various 
"SCCS"         ; SCCS 
"Session.vim"       ; vim 
"slprj"        ; matlab 
"SQUASH_MSG"       ; git 
"TAGS"         ; ctags/etags 
"tags"         ; ctags/etags 
"TestResult"       ; visualstudio 
"testresult"       ; visualstudio 
"Thumbs.db"       ; ms-windows 
"tmtags"        ; textmate 
"xcuserdata"       ; xcode 
"xhtml-loader.rnc"      ; emacs nxhtml 
"{arch}"        ; arch - todo is this correct? 
"~.dep"        ; xcode 
"~.dot"        ; xcode 
"~.nib"        ; xcode 
"~.plst"        ; xcode 
"test.out"        ; generic testing 
"test_out"        ; generic testing 
"test.output"       ; generic testing 
"test_output"       ; generic testing 
+1

谢谢 - 这甚至比我预期发现更好的名单 - 你的荣誉已被转移;) – santa 2013-04-14 15:21:47

+1

谢谢,不用客气。通常,如果你想做一些明智的事情,其他人已经做了非常类似的事情:) – likeitlikeit 2013-04-14 15:23:46

+0

这就是为什么我一直在问的原因;) – santa 2013-04-15 07:54:45