/wpcli-sanitizer

Sanitizes Wordpress attachments if their filenames differ from the result of sanitize_title().

Primary LanguagePHPMIT LicenseMIT

cubetech/wpcli-sanitizer

Using

wp media ct-sanitize sanitizes Wordpress attachments if their filenames differ from the result of sanitize_title.

Installing

Installing this package requires WP-CLI v1.1.0 or greater. Update to the latest stable release with wp cli update.

Once you've done so, you can install this package with:

wp package install git@github.com:cubetech/wpcli-sanitizer.git

Contributing

We appreciate you taking the initiative to contribute to this project.

Contributing isn’t limited to just code. We encourage you to contribute in the way that best fits your abilities, by writing tutorials, giving a demo at your local meetup, helping other users with their support questions, or revising our documentation.

For a more thorough introduction, check out WP-CLI's guide to contributing. This package follows those policy and guidelines.

Reporting a bug

Think you’ve found a bug? We’d love for you to help us get it fixed.

Before you create a new issue, you should search existing issues to see if there’s an existing resolution to it, or if it’s already been fixed in a newer version.

Once you’ve done a bit of searching and discovered there isn’t an open or fixed issue for your bug, please create a new issue. Include as much detail as you can, and clear steps to reproduce if possible. For more guidance, review our bug report documentation.

Creating a pull request

Want to contribute a new feature? Please first open a new issue to discuss whether the feature is a good fit for the project.

Once you've decided to commit the time to seeing your pull request through, please follow our guidelines for creating a pull request to make sure it's a pleasant experience.

Changelog

1.0.3

  • Handle OSX specific cases on umlauts before sanitizing.

1.0.2

  • Count amount of sanitized attachments.

1.0.1

  • Removed usage of undefined class member.

1.0.0

  • Moved command to be a subcommand in wp media.
  • Progress files one by one (db entry, then rename file).

0.1.5

  • PSR-2 formatting, updated PHPdoc.

0.1.2 / 0.1.3 / 0.1.4

  • Fixed autoloading.

0.1.1

  • Fixed composer.json schema.

0.1.0

  • Initial Release with basic feature.

License

MIT License

Copyright (c) 2017 cubetech GmbH

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.