A New Frontier for Core Development

In a little over a decade, we’ve made twenty five thousand commits to WordPress. WordPress (along with the web itself) has come a long way, but our development workflow has remained largely the same.

As a part 3.7, I’ll be leading an effort to revamp and streamline our development workflow. We’re going to bring all of our coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. components—our code, our tests, and our tooling—under one roof. Developers will be able to use and improve the tools we’re already working with day-to-day, and we’ll be able to add new tools to make working with WordPress even easier.

We’re also making sure that any changes are compatible with our current workflow, so you won’t have to change the way you work. These changes won’t break any existing checkouts or scripts that use core.svn.wordpress.orgWordPress.org The community site where WordPress code is created and shared by the users. This is where you can download the source code for WordPress core, plugins and themes as well as the central location for community conversations and organization. https://wordpress.org/. Now that we’ve cleared that up…

develop.svn.wordpress.org

This week, we’re creating a new repository: develop.svn.wordpress.org.

The develop repository will be the new home for all core development. We’re going to sync over all of the commits from core.svn.wordpress.org and will reorganize this new repository to use a new directory structure:

The src directory

This is the WordPress core source. All of the existing WordPress core files will be moved into this directory. You’ll develop and test against this directory as usual, but the real power will come from using the rest of the tools in the repository. The contents will be optimized for development, not production (this means uncompressed files—including our internal libraries).

The tests directory

We’re going to pull our internal unit tests into this repository as well. This will make testing a cinch, and allow us to commit patches that include changes to both the source and the unit tests. We’ll also add JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. unit tests during the 3.7 cycle.

The tools directory

Our tools directory will include all of the little things that make our lives as developers easier. To start, we’ll include our internationalization tools, which will allow us to generate pot files from within core. We’ll also include a handful of scripts that some of us use to interact with TracTrac An open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress., like scripts to upload and apply patches.

The root directory

This frees up the root directory to include configuration files, allowing WordPress to interact more seamlessly with other applications and services like Travis CI and Composer.

A build process

We’ve had an implicit build process in the WordPress codebase for a considerable time now. Most of that process is now contained within bumpbot, a little script that lives on the WordPress.org servers. Whenever we update CSSCSS Cascading Style Sheets. or JavaScript files, bumpbot comes around, minifies them, and commits the result. Despite bumpbot’s efforts, this process is less than ideal. Our source files (in this case, JavaScript and CSS) live alongside our production-optimized files, which causes confusion and makes contributing to core considerably more difficult. Our built output—the files optimized for machines—shouldn’t live alongside the source code that’s optimized for developers, and beyond that, shouldn’t be tracked in source control.

We’re adopting Grunt to write a real build process and help us manage and run our various tools. Grunt is a JavaScript task runner that has a robust ecosystem of plugins focused around building modern web applications. We can include tools such as integrated testing, minification, linting (for PHPPHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 5.6.20 or higher, JSJS JavaScript, a web scripting language typically executed in the browser. Often used for advanced user interfaces and behaviors., and CSS), image optimization, and LiveReload—and that’s just the beginning.

Using Grunt will be an optional but encouraged part of WordPress development. These tools are all built atop Node.js, which Grunt needs in order to function.

So what’s happening to core.svn.wordpress.org?

In a word, nothing. The contents of the core repository have always been optimized for production, and that’s not going to change. core.svn.wordpress.org will now serve as the repository for our built output: every time we make a commit that changes the build, the core build will be updated with a corresponding commit. As mentioned earlier, scripts and checkouts will continue to function as expected. When you download a zip of WordPress, it will still be generated from this repository.

Let’s get started

The develop repository will go live soon. For now, I’ve made a preparatory repository available to illustrate the structure I’ve described above, and allow us to experiment with this new workflow. You can learn more about how the tools are installed and used on the repository page. Please provide feedback on this post—the goal is not to build all of the code there first, but to provide insight into the new process.

Lastly, I’d like to say thank you to all of the contributors who helped shape this idea over the past few months, especially at WordCampWordCamp WordCamps are casual, locally-organized conferences covering everything related to WordPress. They're one of the places where the WordPress community comes together to teach one another what they’ve learned throughout the year and share the joy. Learn more. San Francisco’s hack day. Together, we’ve created a structure that elegantly addresses many of our existing problems and opens the door to countless possibilities for better development practices.

#svn

Team Gandalf Update

Last week marked the end of our second cycle and the beginning of our sprint to get things done. We began by doing just that: last Friday, we merged the theme customizer into core. There’s still quite a bit to do and polish, so please keep that in mind. Development is being tracTrac An open source project by Edgewall Software that serves as a bug tracker and project management tool for WordPress.(k)ed at #19910.

In the past week, we’ve introduced better JSJS JavaScript, a web scripting language typically executed in the browser. Often used for advanced user interfaces and behaviors. APIs, working preview navigation (you can click URLs and it works, hooray), namespaced attributes (which will allow us to enable form submission within previews), and more. We also uncovered and fixed a fairly insane bugbug A bug is an error or unexpected result. Performance improvements, code optimization, and are considered enhancements, not defects. After feature freeze, only bugs are dealt with, with regressions (adverse changes from the previous version) being the highest priority. that stemmed from a low-level bug in Opera’s JS engine. Good times.

Moving forward, the main goals are to integrate more setting types (headers, widgets), improve the refreshing process, polish the UIUI User interface, and remove any vestigial pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party cruft. Dominik’s time will be limited over the next few weeks due to exams, so if any of this sounds exciting to you, please let me know.

#customize, #gandalf, #team-update

Team Gandalf Update

Yesterday marked the halfway point of our second cycle. We’re moving along at a steady clip. The main goal for the coming week is to tie up any loose ends and begin integrating the pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party into coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress.. Until then, follow our progress at #19910 and in the plugin repo.

We’ve made considerable progress in the past week. We completed a first pass for menu locations and have almost all of the elements we need for custom backgrounds (all that remains is the file upload dialog and fixing the color picker). We also added the ability to alter/choose a static front pageStatic Front Page A WordPress website can have a dynamic blog-like front page, or a “static front page” which is used to show customized content. Typically this is the first page you see when you visit a site url, like wordpress.org for example. within the customization (as decided in dev chat yesterday). Under the hood, we’ve made numerous improvements including working APIs (including rendering controls, previewing, and saving) for theme_mods and options, proper handling of multidimensional IDs, and a whole bunch of bugbug A bug is an error or unexpected result. Performance improvements, code optimization, and are considered enhancements, not defects. After feature freeze, only bugs are dealt with, with regressions (adverse changes from the previous version) being the highest priority. fixes.

#customize, #gandalf, #team-update

Team Gandalf Update

Our first cycle ended yesterday, and all is well. Follow along with the fun at #19910 in the plugin repo.

Dominik (ocean90) and I have implemented a base UIUI User interface, and have properly sandboxed both the theme preview and the customization controls. Only the target theme can alter the controls/preview, the preview can be independently refreshed, and the controls/preview can communicate with each other.

We’re set to begin our second cycle. A tentative scope:

  • Develop APIs for adding/previewing/saving individual settings.
  • Implement custom background (properly, with save).
  • CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. integration (decided in dev chat).
  • Work with the Headerators to implement custom headers.
  • Begin work on adding menu locations.

#customize, #gandalf

Team Gandalf Update

Wednesday marked the halfway point of our first iteration. The description of our current cycle can be found in #19910. Development is currently taking place in a pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party (you can find the repo here). For an overview of appearance improvements, see #19909.

We’ve accomplished most of the initial goals for this cycle and are now refining and building out the existing concepts. Currently, the two remaining points are to add an (initially blank) save action and to enable communication between the UIUI User interface and preview via postMessage.

On Tuesday, we had a UXUX User experience review with Jane where we decided to proceed with a stacked accordion UI to navigate between different components in the preview frame. We also decided to add a button to collapse the sidebarSidebar A sidebar in WordPress is referred to a widget-ready area used by WordPress themes to display information that is not a part of the main content. It is not always a vertical column on the side. It can be a horizontal rectangle below or above the content area, footer, header, or any where in the theme. (similar to the “collapse menu” button in the adminadmin (and super admin) menu, but larger and “more buttony”). Once postMessage support has been added, we’ll also experiment with a zooming feature to allow the user to get a bird’s eye view of the page. In addition to adding the save action and postMessage, ocean90 and I are hoping to get a head start on the accordion UI so we can break more tasks out to subteams.

We have another meeting with Jane in #wordpress-dev scheduled on Monday at 21:00 UTC that will double as office hours. If you have any questions or comments, feel free to swing by the meeting, drop a comment here, or pingPing The act of sending a very small amount of data to an end point. Ping is used in computer science to illicit a response from a target server to test it’s connection. Ping is also a term used by Slack users to @ someone or send them a direct message (DM). Users might say something along the lines of “Ping me when the meeting starts.” me (koopersmith) or ocean90 in IRCIRC Internet Relay Chat, a network where users can have conversations online. IRC channels are used widely by open source projects, and by WordPress. The primary WordPress channels are #wordpress and #wordpress-dev, on irc.freenode.net.. All in all, we’re on track to meet our two week deadline.

#customize, #gandalf