Problem/Motivation

Rename the module and all settings and namespaces to "front" like the module name and directory name. That's best practice.

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

Issue fork front-3438829

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

Anybody created an issue. See original summary.

aaron.ferris made their first commit to this issue’s fork.

aaron.ferris’s picture

I was going to start this, but do we think it'd be worth waiting for some of the bulkier changes to be in before doing this, to avoid conflicts etc?

Happy to have a go at this when we feel it would be a good time.

aaron.ferris’s picture

Assigned: Unassigned » aaron.ferris
anybody’s picture

Assigned: aaron.ferris » Unassigned
Status: Active » Postponed

Thanks @aaron.ferris yes let's wait for that! It's also optional with no "real" benefit.

aaron.ferris’s picture

Sounds good thanks

erwangel’s picture

Although that's confusing for people wanting to install the module. You require it with composer as "front" but you have it to enable it with drush as "front_page". confusing and not very intuitive when drush tells you "Unable to install modules front due to missing modules front." I had to look in the modules's directory to realize that its "real" name was "front_page" and not "front". I think a quick fix will be useful so more people could install it and you could gain more feedback.

elc’s picture

Had a thought about this as it will be a rather large breaking change.

  1. Copy the entire module into a sub-dir called "modules"
  2. Rename all of the base dir module to the correct file and function names (and classes so as not to dup anything)
  3. Add an update to the sub-module to install "front"
  4. Add an enable to base dir module to uninstall "front_page" if it's installed
  5. Add a hook_requirements() to sub-dir module to ensure it can't be installed to start with

Haven't figured out the intricate details, or if this would work at all but it seems like it would. Use the lifecycle on the sub-dir module.

Agree with holding off until majority of changes are in so as not to increase the amount of work needed to do this.

elc’s picture

Had a think about this again - add a sub-module called "front" which requires "front_page" as a dependency. Fixes the original problem of trying to install the wrong module name, but without needing to make major changes to current module at all.

Optional - create an empty project using the namespace "front_page" which is marked as deprecated and to use "front" module instead.