Skip to content

Commit

Permalink
v1.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
corsacca committed Apr 19, 2024
1 parent 482baaa commit b083a19
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 77 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
- name: Build project
run: |
mkdir disciple-tools-storage
cp -r disciple-tools-storage.php admin charts languages magic-link post-type rest-api site-link tile workflows spinner.svg version-control.json LICENSE SECURITY.md disciple-tools-storage/
cp -r disciple-tools-storage.php disciple-tools-storage-api.php disciple-tools-storage-filters.php admin rest-api version-control.json LICENSE SECURITY.md disciple-tools-storage/
zip -r disciple-tools-storage.zip disciple-tools-storage
- name: Create Release
id: create_release
Expand Down
41 changes: 2 additions & 39 deletions disciple-tools-storage.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* Description: Disciple.Tools - Storage is intended to help manage connections with remote object storage services, such as AWS S3.
* Text Domain: disciple-tools-storage
* Domain Path: /languages
* Version: 0.1
* Version: 1.0.0
* Author URI: https://github.com/DiscipleTools
* GitHub Plugin URI: https://github.com/DiscipleTools/disciple-tools-storage
* Requires at least: 4.7.0
Expand All @@ -18,14 +18,6 @@
* https://www.gnu.org/licenses/gpl-2.0.html
*/

/**
* Refactoring (renaming) this plugin as your own:
* 1. @todo Rename the `disciple-tools-storage.php file.
* 2. @todo Refactor all occurrences of the name Disciple_Tools_Storage, disciple_tools_storage, disciple-tools-storage, storage, and "Storage"
* 3. @todo Update the README.md and LICENSE
* 4. @todo Update the default.pot file if you intend to make your plugin multilingual. Use a tool like POEdit
*/

if ( ! defined( 'ABSPATH' ) ) {
exit; // Exit if accessed directly
}
Expand Down Expand Up @@ -99,26 +91,13 @@ private function __construct() {
require_once( 'disciple-tools-storage-api.php' );
require_once( 'disciple-tools-storage-filters.php' );

/**
* @todo Decide if you want to use the REST API example
* To remove: delete this following line and remove the folder named /rest-api
*/
if ( $is_rest && strpos( dt_get_url_path(), 'disciple_tools_storage' ) !== false ) {
require_once( 'rest-api/rest-api.php' ); // adds starter rest api class
}

/**
* @todo Decide if you want to add a custom admin page in the admin area
* To remove: delete the 3 lines below and remove the folder named /admin
*/
if ( is_admin() ) {
require_once( 'admin/admin-menu-and-tabs.php' ); // adds starter admin page and section for plugin
}

/**
* @todo Decide if you want to customize links for your plugin in the plugin admin area
* To remove: delete the lines below and remove the function named "plugin_description_links"
*/
if ( is_admin() ) { // adds links to the plugin description area in the plugin admin list.
add_filter( 'plugin_row_meta', [ $this, 'plugin_description_links' ], 10, 4 );
}
Expand All @@ -132,8 +111,7 @@ public function plugin_description_links( $links_array, $plugin_file_name, $plug
if ( strpos( $plugin_file_name, basename( __FILE__ ) ) ) {
// You can still use `array_unshift()` to add links at the beginning.

$links_array[] = '<a href="https://disciple.tools">Disciple.Tools Community</a>'; // @todo replace with your links.
// @todo add other links here
$links_array[] = '<a href="https://community.disciple.tools">Disciple.Tools Community</a>';
}

return $links_array;
Expand Down Expand Up @@ -273,21 +251,6 @@ function dt_hook_ajax_notice_handler(){
}
}
}

/**
* Plugin Releases and updates
* @todo Uncomment and change the url if you want to support remote plugin updating with new versions of your plugin
* To remove: delete the section of code below and delete the file called version-control.json in the plugin root
*
* This section runs the remote plugin updating service, so you can issue distributed updates to your plugin
*
* @note See the instructions for version updating to understand the steps involved.
* @link https://github.com/DiscipleTools/disciple-tools-storage/wiki/Configuring-Remote-Updating-System
*
* @todo Enable this section with your own hosted file
* @todo An example of this file can be found in (version-control.json)
* @todo Github is a good option for delivering static json.
*/
/**
* Check for plugin updates even when the active theme is not Disciple.Tools
*
Expand Down
15 changes: 1 addition & 14 deletions rest-api/rest-api.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,8 @@

class Disciple_Tools_Storage_Endpoints
{
/**
* @todo Set the permissions your endpoint needs
* @link https://github.com/DiscipleTools/Documentation/blob/master/theme-core/capabilities.md
* @var string[]
*/
public $permissions = [ 'access_contacts', 'dt_all_access_contacts', 'view_project_metrics' ];
public $permissions = [ 'manage_dt' ];


/**
* @todo define the name of the $namespace
* @todo define the name of the rest route
* @todo defne method (CREATABLE, READABLE)
* @todo apply permission strategy. '__return_true' essentially skips the permission check.
*/
//See https://github.com/DiscipleTools/disciple-tools-theme/wiki/Site-to-Site-Link for outside of wordpress authentication
public function add_api_routes() {
$namespace = 'disciple_tools_storage/v1';

Expand Down
21 changes: 0 additions & 21 deletions spinner.svg

This file was deleted.

4 changes: 2 additions & 2 deletions version-control.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "Disciple.Tools - Storage",
"version": "0.1",
"last_updated": "2021-03",
"version": "1.0.0",
"last_updated": "2024-04",
"author": "Disciple.Tools",
"author_homepage": "https://disciple.tools",
"git_owner": "DiscipleTools",
Expand Down

0 comments on commit b083a19

Please sign in to comment.