Forum: Radiant CMS strange behavior with git and extensions(and Capistrano)

Posted by Blake (Guest)
on 2010-10-13 16:52
(Received via mailing list)
I have googled and read all I can find, but with my limited knowledge,
I cant seem to figure out what is going on, any help would be awesome,
as I cant find anyone having the same problem.

my setup is a local version of radiant with two custom extensions, and
few installed ones (mailer, mediamaid, settings, share_layouts). I
have a git repo of the project that I can cap deploy to my server
successfully, but the extensions that I installed do not get copied
up, meaning that the 'folder' gets added to git and and empty folder
is pushed to the server.

I verify this with ssh and sure enough, the folders are empty.

So I do a little inspection and alter some files in a few of the
extensions (adding spaces and such), and then do a git status, with no
change.

My question is, If I have to install extensions on my server manually
via ssh, why is git sending an empty folder.  And why is git not
seeing changes?

Thanks for any insight.
Posted by John Muhl (johnmuhl)
on 2010-10-13 17:21
(Received via mailing list)
On Wed, Oct 13, 2010 at 9:51 AM, Blake <rockman@sharpend.us> wrote:
> my setup is a local version of radiant with two custom extensions, and
> few installed ones (mailer, mediamaid, settings, share_layouts). I
> have a git repo of the project that I can cap deploy to my server
> successfully, but the extensions that I installed do not get copied
> up, meaning that the 'folder' gets added to git and and empty folder
> is pushed to the server.

i believe `./script/extension install` adds extensions as git
submodules. try adding:

set :git_enable_submodules, 1

to your config/deploy.rb file.
Posted by Blake (Guest)
on 2010-10-16 05:31
(Received via mailing list)
thanks john, I just tried that and it does add the extensions, but
they are pulled from their original location (i.e. these are all
hosted at github)  but a couple of them have had to be altered by me
to have them work on my server, and I want them to either
a) have changes to /vendors/extensions/...  be added with git add .
b) ignore the folders all together and not create empty folders on the
server.

Anyway , thanks again.
Blake
Posted by Jim Gay (Guest)
on 2010-10-16 07:09
(Received via mailing list)
On Fri, Oct 15, 2010 at 11:30 PM, Blake <rockman@sharpend.us> wrote:
> thanks john, I just tried that and it does add the extensions, but
> they are pulled from their original location (i.e. these are all
> hosted at github) but a couple of them have had to be altered by me
> to have them work on my server, and I want them to either
> a) have changes to /vendors/extensions/... be added with git add .
> b) ignore the folders all together and not create empty folders on the
> server.

If you've pulled extensions from github and committed changes to them,
the submodule will fail because the submodule will point to a commit
that doesn't exist at the source (github). You should see errors from
capistrano during your deployment, what errors do you get?

You can add content to your main project without submodules by adding
the extension paths with a trailing slash.

Add a submodule path like this vendor/extensions/something
Add actual content like this vendor/extensions/something/

Note the trailing slash.

Does this help?
Please log in before posting. Registration is free and takes only a minute.
Existing account (Switch to SSL-encrypted connection)
NEW: Do you have a Google/GoogleMail or Yahoo account? No registration required!
Log in with Google account | Log in with Yahoo account
No account? Register here.