Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Automatically normalize line endings.
* text=auto

# Files and directories to exclude from the generated archive (export-ignore).
# These will be omitted from GitHub/Packagist ZIP archives to keep packages small.

# Tests and test fixtures
/tests/ export-ignore

# PHP unit / static analysis configs.
/phpcs.xml.dist export-ignore
/phpstan.neon.dist export-ignore
/phpunit.xml.dist export-ignore

# Continuous Integration configs.
/.github/ export-ignore

# Node and build artifacts.
package.json export-ignore
package-lock.json export-ignore
/composer.lock export-ignore

# Don't include the dotfiles for distribution.
/.* export-ignore

# Mark docs as documentation for GitHub Linguist.
/docs/ linguist-documentation export-ignore
/CONTRIBUTING.md linguist-documentation export-ignore
/LICENSE.md linguist-documentation
/README.md linguist-documentation
Empty file removed .wordpress-org/.gitkeep
Empty file.
27 changes: 4 additions & 23 deletions abilities-api.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,27 +26,8 @@
*/
define( 'WP_ABILITIES_API_DIR', plugin_dir_path( __FILE__ ) );

/**
* Version of the plugin.
*/
define( 'WP_ABILITIES_API_VERSION', '0.1.0' );
require_once WP_ABILITIES_API_DIR . 'includes/bootstrap.php';

/**
* First the WP_Ability class that users can extend.
*/
require_once WP_ABILITIES_API_DIR . 'includes/abilities-api/class-wp-ability.php';

/**
* Then the WP_Abilities_Registry class that manages the abilities.
*/
require_once WP_ABILITIES_API_DIR . 'includes/abilities-api/class-wp-abilities-registry.php';

/**
* Then the public access functions that users can use to interact with the abilities.
*/
require_once WP_ABILITIES_API_DIR . 'includes/abilities-api.php';

/**
* Initialize REST API controllers.
*/
require_once WP_ABILITIES_API_DIR . 'includes/rest-api/class-wp-rest-abilities-init.php';
if ( function_exists( 'add_action' ) ) {
add_action( 'rest_api_init', array( 'WP_REST_Abilities_Init', 'register_routes' ) );
}
30 changes: 18 additions & 12 deletions composer.json
Original file line number Diff line number Diff line change
@@ -1,33 +1,39 @@
{
"name": "wordpress/abilities-api",
"description": "AI Abilities for WordPress",
"description": "AI Abilities for WordPress.",
"license": "GPL-2.0-or-later",
"type": "wordpress-plugin",
"version": "0.1.0",
"keywords": [
"ai",
"api",
"llm",
"abilities",
"abilities-api",
"wordpress"
],
"homepage": "https://github.com/WordPress/abilities-api/issues",
"authors": [
{
"name": "WordPress AI Team",
"homepage": "https://make.wordpress.org/ai/"
}
],
"homepage": "https://github.com/WordPress/abilities-api",
"support": {
"issues": "https://github.com/WordPress/abilities-api/issues"
"issues": "https://github.com/WordPress/abilities-api/issues",
"source": "https://github.com/WordPress/abilities-api"
},
"minimum-stability": "dev",
"prefer-stable": true,
"config": {
"sort-packages": true,
"platform": {
"php": "7.4"
},
"allow-plugins": {
"dealerdirect/phpcodesniffer-composer-installer": true,
"phpstan/extension-installer": true,
"composer/installers": true
}
},
"platform": {
"php": "7.4"
},
"sort-packages": true
},
"minimum-stability": "dev",
"prefer-stable": true,
"repositories": [
{
"type": "composer",
Expand Down
Loading