G'Day、
rsyncを使用して、次のようなリモートフォルダーツリーを再帰的に同期しています。
/folderA/a1/cache
/folderA/a1/cache/A1
/folderA/a1/cache/A2
/folderA/a1/somefolder
/folderA/a1/someotherfolder
/folderA/a2/somefolder/cache
/folderB/cache/
/folderB/b1/somefolder/cache
/folderB/b1/somefolder/yetanotherfolder/cache
/folderB/b1/somefolder/yetanotherfolder/cache/B1
/folderB/b1/somefolder/yetanotherfolder/cache/B2
フォルダーツリーがどのように表示されるかはわかりませんが、時間とともに変化します。したがって、私ができるようにしたいのは、上記を再帰的にrsyncすることですが、フォルダー「cache」とそこに含まれるサブフォルダーを除外して、最終的に同期をとることです。
/folderA/a1
/folderA/a1/somefolder
/folderA/a1/someotherfolder
/folderA/a2/somefolder
/folderB/
/folderB/b1/somefolder
/folderB/b1/somefolder/yetanotherfolder/
助言がありますか?
rsyncフィルターチュートリアルも参照してください。
—
ジル 'SO-悪であるのをやめる'