Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ReferenceError: scForm is not defined in Sitecore 8

I get this javascript-error in Sitecore 8 > Control Panel when e.g. clicking "Install a package" or any other link:

ReferenceError: scForm is not defined

Looking in Firebug, seems like a file is missing: http://my.site/-/speak/v1/assets/main.js.

like image 714
Frederik Struck-Schøning Avatar asked Feb 27 '26 01:02

Frederik Struck-Schøning


1 Answers

Found out: this error occurs, because the file App_Config/Include/.Sitecore.Speak.Important.config is missing.

Why is it missing? Because filename starts with a period '.', and we use TeamCity and Octopus Deploy / OctoPack to generate a NuGet package for deploying.

This is by-design behaviour by OctoPack - i.e. to not include files with leading periods in output packages (see here). But as comments state, there is now an option to allow for dot-files to deploy:

In your build-build step in TeamCity (runner type MsBuild or Visual Studio (sln)), in the field Command line parameters, insert or append the following:

/p:OctoPackNuGetArguments=-NoDefaultExcludes

Who the heck names files with a leading period anyway...

like image 108
Frederik Struck-Schøning Avatar answered Mar 02 '26 20:03

Frederik Struck-Schøning



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!