WordPress.org

Make WordPress Core

Opened 5 years ago

Closed 4 years ago

#12880 closed enhancement (wontfix)

Reorganize Directory Structure in /wp-includes

Reported by: mikeschinkel Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.0
Component: General Keywords:
Focuses: Cc:

Description

This is a simple one and I'm not married to the idea but would like to suggest we consider reorganizing the directory structure in /wp-includes. I find that I'm constantly paging up and down in my IDE to find the files I'm looking for.

Maybe we could create subdirectories for the obvious groups, i.e.:

/wp-includes/category
/wp-includes/classes
/wp-includes/comments
/wp-includes/default
/wp-includes/feeds
/wp-includes/functions
/wp-includes/multisite
/wp-includes/pluggable
/wp-includes/post

If we do this it will be easier to work with the remaining files that are not in those groups. Something to consider. I can write a patch...

Change History (2)

comment:1 @nacin5 years ago

I don't see this happening, personally, and I'm -1 on spawning new folders. More folders for example would make my own workflow worse, as I'd constantly be navigating up and down trees -- both in file->open dialog boxes and the command line. It's a matter of preference, and the status quo will probably win out.

That said, most things are already prefixed with class-, feed-, ms-, pluggable-, default-. Then there is the -template suffix, which makes a lot of sense as generally you're looking for the object being templated first, not the templates in general.

There are some improvements to be made, but we can't do it with any files that aren't included by wp-load as then you'll have backwards compatibility issues and you'll need back compat files (see also, rss-functions and registration-functions).

One such improvement would be breaking out classes.php into multiple files, such as class.walkers, class.wp, class.wp-error, etc. I don't see anything else that really stands out, other than perhaps finally removing rss-functions, which is a back compat file of rss.php, which in turn is deprecated.

Also, renaming files is a pain when you want to svn blame something. I've seen too many changesets years ago of files getting shifted around -- there have been a good three or four solid reshufflings -- while looking back for things. We're in a good, manageable position now.

comment:2 @nacin4 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.