我試圖rsync我的網站到服務器,同時保留一些符號鏈接。我有一些裏德文件和本應該做的伎倆rsync符號鏈接到php文件
rsync -vra --links
除了一個問題:它不會複製那些不針對某個文件夾的符號鏈接,而是一個文件(在這種情況下.PHP,但我不要認爲這很重要)。它基本上打破了。
此鏈接:
htdocs/content/uploads -> /data/sharedstorage/uploads
這個環節不會被跳過
htdocs/content/config.php -> /data/sharedstorage/config.php
有誰知道我怎麼能解決這個問題?
P.S:我想保留符號鏈接,所以我不想複製原始符號鏈接鏈接到的文件。
爲什麼你認爲它被跳過是因爲它是符號鏈接?你能給完整的rsync命令嗎? –
rsync -vrla --delete --update --dry-run --exclude = .git --exclude = htdocs/.htaccess --exclude = .git * --exclude = *。old --exclude =。*。舊--exclude = *。dist --exclude =。*。dist --exclude = www --exclude =。* --exclude = vendor/bin --exclude = vendor/cube --exclude = vendor/johnpbloch - exclude = vendor/koodimonni --exclude = vendor/koodimonni-language --exclude = *。json --exclude = Gruntfile.js --exclude = vvv * --exclude = wp-cli.yml --exclude = *。lock --exclude = *。md --exclude = node_modules --exclude = htdocs/content/themes/starter/tests --exclude = htdocs/content/themes/starter/*。json --exclude = htdocs/content/themes /首先/ *。txt –
--exclude = htdocs/content/themes/starter/*。md --exclude = htdocs/content/themes/starter/resources/assets/bower --exclude = htdocs/content/themes/starter /資源/資產/ scss --exclude = htdocs/content/themes/starter/resources/assets/js/*/--exclude = htdocs/content/themes/starter/resources/assets/css/**/*。map。/user @ server: 是完整的命令。 -l應該和--links一樣(兩者都試過)如果我檢查正確,它不會排除這些文件。 –