Download the PHP package wp-spaghetti/bedrock-autoloader-mu without Composer

On this page you can find all versions of the php package wp-spaghetti/bedrock-autoloader-mu. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package bedrock-autoloader-mu

Sync Status Latest Stable Version Total Downloads License

Bedrock MU-Plugin Autoloader

Self-contained Bedrock autoloader for must-use plugins. This package is automatically synchronized daily from roots/bedrock and roots/bedrock-autoloader.

Why this package?

The original roots/bedrock-autoloader requires the library to be loaded before the mu-plugin wrapper executes. This creates a chicken-and-egg problem in standard WordPress environments where mu-plugins load before regular plugins.

This package solves that by:

Installation

Method 1: Via Composer with Auto-Copy Helper (Recommended)

Install the package:

Add this to your project root composer.json:

The helper class will automatically copy bedrock-autoloader.php to mu-plugins/ root on install and update.

Method 2: Via Composer with Direct Download

Install the package to manage versions via Composer, then download the file directly:

Add this to your project root composer.json:

Note: Adjust the path wp-content/mu-plugins/bedrock-autoloader.php according to your project structure.

Usage

Once installed, the autoloader will automatically load all subdirectories in wp-content/mu-plugins/ as plugins.

Example structure after installation:

How It Works

  1. Composer installs the package in mu-plugins/bedrock-autoloader-mu/
  2. Your post-install script copies dist/bedrock-autoloader.php to mu-plugins/ root
  3. WordPress loads mu-plugins/bedrock-autoloader.php directly
  4. The autoloader loads all other mu-plugin subdirectories

Auto-Sync

This repository automatically syncs the following files every day at 2 AM UTC:

The combined file is generated and saved in the dist/ directory to prevent it from being autoloaded by itself.

When changes are detected, a new version tag is automatically created with format v1.0.YYYYMMDD.

Troubleshooting

File not copied to mu-plugins root

Make sure:

  1. You've added the scripts to your project root composer.json (not the package's composer.json)
  2. Your installer-paths correctly points to your mu-plugins directory
  3. The helper class can write to the mu-plugins directory (check permissions)

Different project structure

If your project has a custom structure, adjust the paths in your scripts. The helper class copies the file relative to the vendor directory, so you may need to use a custom shell script instead:

Contributing

For your contributions please use:

See CONTRIBUTING for detailed guidelines.

Sponsor

Buy Me A Coffee

Credits

Based on the original work by Roots:

License

MIT License - See LICENSE file for details.

Original code © Roots
Self-contained package © Frugan


All versions of bedrock-autoloader-mu with dependencies

PHP Build Version
Package Version
Requires php Version >=7.1
composer-runtime-api Version ^2.0
composer/installers Version ^1.0 || ^2.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package wp-spaghetti/bedrock-autoloader-mu contains the following files

Loading the files please wait ...