Sitecake and hidden .svn subfolders

Hi,

I am running Sitecake 2.3.4 and using it in an SVN checkout folder.
SVN is creating .svn folders for its administration.

I discovered two issues with this scenario:

  1. If the apache user has all the permissions to the /images/.svn folder. Sitecake removes files from /images/.svn/text-base leading to errors during SVN commit.
  2. If the apache user has no permissions to this folder. Which would be the best option in my opinion. The Publish from Sitecake will crash. See head of sitecake.log below.

In my opinion. Sitecake should not touch files in any folder not created by Sitecake. And certainly not in hidden folders.
May be you can let Sitecake ignore the dot/hidden folders or at least the .svn folders.
That would be of great help to me.

[2016-08-10 14:46:05] Warning: Warning (2): unlink(/var/www/html/images/.svn/prop-base/tabel-documentenbeheer-sc57a06a2c4e72f-985.png.svn-base): Permission denied in [/var/www/html/sitecake/2.3.4/vendor/league/flysystem/src/Adapter/Local.php, line 235]
Trace:
#0  Sitecake\Error\ErrorHandler::_logError(4, Array ([level] => 4,[code] => 2,[error] => Warning,[description] => unlink(/var/www/html/images/.svn/prop-base/tabel-documentenbeheer-sc57a06a2c4e72f-985.png.svn-base): Permission denied,[file] => /var/www/html/sitecake/2.3.4/vendor/league/flysystem/src/Adapter/Local.php,[line] => 235)) called at [/var/www/html/sitecake/2.3.4/src/Sitecake/Error/ErrorHandler.php:100]
#1  Sitecake\Error\ErrorHandler::handleError(2, unlink(/var/www/html/images/.svn/prop-base/tabel-documentenbeheer-sc57a06a2c4e72f-985.png.svn-base): Permission denied, /var/www/html/sitecake/2.3.4/vendor/league/flysystem/src/Adapter/Local.php, 235, Array ([path] => images/.svn/prop-base/tabel-documentenbeheer-sc57a06a2c4e72f-985.png.svn-base,[location] => /var/www/html/images/.svn/prop-base/tabel-documentenbeheer-sc57a06a2c4e72f-985.png.svn-base))

Hi you can declare ignored files/dirs by uploading .scignore file inside your site root where you can state all dirs and files each on separate line.

Hi @predragleka

That sounds like a great solution. I tried the following:

# Ignore files needed for SVN
.svn/
*.svn-base

This is the content of my .scignore file that is in the root of my webpage.

But either the file is not picked up, or the glob syntax like for other ignore files as .gitignore is not working for .scignore

What is the syntax of the .scignore file?
Should the paths be relative to the website root, or should they be stated as the full path starting from the os root?

Hi, glob syntax is not supported currently, but good idea to add this in some of future releases. Paths should be relative to site root.

Thanks a lot. I have changed .scignore into

images/.svn
files/.svn

and all seems to be working nicely right now.