Skip to content
This repository was archived by the owner on Apr 21, 2021. It is now read-only.

Add the "folder structure" chapter and modify the "extension" chapter - #370

Closed
lionel-m wants to merge 19 commits into
contao:4.0from
lionel-m:folder-structure-noNewChapter
Closed

Add the "folder structure" chapter and modify the "extension" chapter#370
lionel-m wants to merge 19 commits into
contao:4.0from
lionel-m:folder-structure-noNewChapter

Conversation

@lionel-m

Copy link
Copy Markdown
Contributor

This is the same as #345 but without adding a new chapter.

@aschempp

aschempp commented May 2, 2016

Copy link
Copy Markdown
Member

Wow, this is great!

Two things:

  • Contao 3 extensions can also be installed with Composer, if the developer said them to be compatible with Contao 4
  • I would suggest to write the full class name instead of a use statement in the kernel.

@lionel-m

lionel-m commented May 2, 2016

Copy link
Copy Markdown
Contributor Author

Contao 3 extensions can also be installed with Composer, if the developer said them to be compatible with Contao 4

Ok I will separate into two sub-chapter "with Composer" and "manually".

I would suggest to write the full class name instead of a use statement in the kernel.

Can I have an example please?

@aschempp

aschempp commented May 3, 2016

Copy link
Copy Markdown
Member

Can I have an example please?

public function registerBundles()
{
    $bundles = [
        new Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
        new Contao\CoreBundle\ContaoCoreBundle(),
        new Contao\CoreBundle\HttpKernel\Bundle\ContaoModuleBundle('myExtensionName', $this->getRootDir()),
    ];

    return $bundles;
}

@lionel-m

lionel-m commented May 3, 2016

Copy link
Copy Markdown
Contributor Author

Thanks!

@lionel-m

lionel-m commented May 4, 2016

Copy link
Copy Markdown
Contributor Author

Contao 3 extensions can also be installed with Composer, if the developer said them to be compatible with Contao 4

I added this part in 7bc9f0f.
Should we add a line in the app/AppKernel.php file if we install an extension with Composer?

@lionel-m

lionel-m commented May 9, 2016

Copy link
Copy Markdown
Contributor Author

@aschempp Could you add a new branch for the 4.2 please


An extension that can be installed via Composer can be found through its main
repository [Packagist][2]. A name of an extension is divided into two parts.
The first part is the name of the project owner and the second the extension

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

project owner is usually called vendor

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kept "project owner" in parentheses because everyone does not necessarily know this term.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like me for example ;-)

@lionel-m lionel-m changed the title Add the "folder structure" chapter and modify the "extension" chapter [WIP] Add the "folder structure" chapter and modify the "extension" chapter May 26, 2016
@lionel-m lionel-m changed the title [WIP] Add the "folder structure" chapter and modify the "extension" chapter Add the "folder structure" chapter and modify the "extension" chapter May 26, 2016
@lionel-m

Copy link
Copy Markdown
Contributor Author

@aschempp I made all the changes.

@aschempp

aschempp commented Aug 4, 2016

Copy link
Copy Markdown
Member

Public files of each bundle are located in the web/bundles folder through symlinks. These can be regenerated from the back end under maintenance.

Not sure if that's correct. @leofeyer do we call assets:install from the backend or just contao:symlinks?

@aschempp

aschempp commented Aug 4, 2016

Copy link
Copy Markdown
Member

The part about installing extensions is a bit confusing to me. It explains about bundles, but what we're installing in the example seems to be old Contao 3 extensions. Are you intentionally not mentioning how to install a real bundle? Maybe we should be more clear about the differences?

@lionel-m

lionel-m commented Aug 4, 2016

Copy link
Copy Markdown
Contributor Author

Are you intentionally not mentioning how to install a real bundle? Maybe we should be more clear about the differences?

No it's not intentional. I will improve this point... Add the installation of a real bundle and make the difference between the two types of extension.

@leofeyer

leofeyer commented Aug 4, 2016

Copy link
Copy Markdown
Member

Just contao:symlinks.

@lionel-m

lionel-m commented Aug 5, 2016

Copy link
Copy Markdown
Contributor Author

No it's not intentional. I will improve this point... Add the installation of a real bundle and make the difference between the two types of extension.

@aschempp it's better now WDYT?

@aschempp

aschempp commented Aug 8, 2016

Copy link
Copy Markdown
Member

Great progress! For a Contao 3 extension to be installed in Contao 4, a developer has to mark it as compatible. Therefore the warning about compatibility should probably go into the "manual installation" section, what do you think?

We should also add a link to Packagist that lists all Contao things, they currently look like this:
https://packagist.org/search/?q=&type=contao-bundle (Contao 4 bundles) or
https://packagist.org/search/?q=&type=contao-module (Contao 3 extensions)

@lionel-m

lionel-m commented Aug 8, 2016

Copy link
Copy Markdown
Contributor Author

I removed the warning and improved the existing chapter (Contao modules) on this subject in c066a7c.

@lionel-m

lionel-m commented Aug 8, 2016

Copy link
Copy Markdown
Contributor Author

We should also add a link to Packagist that lists all Contao things, they currently look like this:
https://packagist.org/search/?q=&type=contao-bundle (Contao 4 bundles) or
https://packagist.org/search/?q=&type=contao-module (Contao 3 extensions)

I added a new sub-chapter (Finding extensions or bundles).

@lionel-m

lionel-m commented Aug 8, 2016

Copy link
Copy Markdown
Contributor Author

What do you think about changing the chapter name: "Extensions and bundles" instead of "Extensions" only?

@aschempp

Copy link
Copy Markdown
Member

I like it 😎
We should maybe add more information about the different types of extensions, and why you should use one or the other. I could create a pull request for you with my ideas, ok?

@lionel-m

Copy link
Copy Markdown
Contributor Author

I could create a pull request for you with my ideas, ok?

Yes thx 👍

@lionel-m

lionel-m commented Aug 22, 2016

Copy link
Copy Markdown
Contributor Author

@aschempp I recreate this PR for the 4.2 branch with the last changes?

UPDATE: https://github.com/blog/2224-change-the-base-branch-of-a-pull-request 👍

@aschempp

Copy link
Copy Markdown
Member

Reviewed this again. I wonder if the folder structure belongs to the chapter "installing Contao"? Not really relevant for a regular user, is it? Maybe we should move this to a cookbook chapter, what do you think?

@lionel-m

Copy link
Copy Markdown
Contributor Author

Reviewed this again. I wonder if the folder structure belongs to the chapter "installing Contao"? Not really relevant for a regular user, is it? Maybe we should move this to a cookbook chapter, what do you think?

OK I will create a chapter with this part in the cookbook and recreating this PR that will target the 4.2 branch.

@lionel-m

Copy link
Copy Markdown
Contributor Author

Closed in favor of #424 and #425.

@lionel-m lionel-m closed this Sep 30, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants