Skip to content

Commit

Permalink
added node informations
Browse files Browse the repository at this point in the history
add node* informations. thanks @Menrath for the idea!
  • Loading branch information
pfefferle committed Dec 22, 2023
1 parent b71b84d commit 8ab7d95
Show file tree
Hide file tree
Showing 6 changed files with 26 additions and 8 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
**Tags:** nodeinfo, fediverse, ostatus, diaspora, activitypub
**Requires at least:** 4.9
**Tested up to:** 6.4
**Stable tag:** 2.2.0
**Stable tag:** 2.3.0
**Requires PHP:** 5.6
**License:** MIT
**License URI:** https://opensource.org/licenses/MIT
Expand All @@ -24,6 +24,10 @@ This plugin provides a barebone JSON file with basic "node"-informations. The fi

Project and support maintained on github at [pfefferle/wordpress-nodeinfo](https://github.com/pfefferle/wordpress-nodeinfo).

### 2.3.0 ###

* add nodeName, nodeDescription and nodeIcon to meta array

### 2.2.0 ###

* add MAUs
Expand Down
6 changes: 4 additions & 2 deletions includes/class-nodeinfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,14 +107,16 @@ public function generate_services() {
public function generate_metadata() {
$metadata = $this->metadata;

$metadata['email'] = get_option( 'admin_email' );

$metadata['generator'] = array(
'name' => 'NodeInfo WordPress-Plugin',
'version' => nodeinfo_version(),
'repository' => 'https://github.com/pfefferle/wordpress-nodeinfo/',
);

$metadata['nodeName'] = \get_bloginfo( 'name' );
$metadata['nodeDescription'] = \get_bloginfo( 'description' );
$metadata['nodeIcon'] = \get_site_icon_url();

$this->metadata = apply_filters( 'nodeinfo_data_metadata', $metadata, $this->version );
}

Expand Down
10 changes: 9 additions & 1 deletion includes/class-nodeinfo2.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,15 @@ public function generate_services() {
public function generate_metadata() {
$metadata = $this->metadata;

$metadata['email'] = get_option( 'admin_email' );
$metadata['generator'] = array(
'name' => 'NodeInfo WordPress-Plugin',
'version' => nodeinfo_version(),
'repository' => 'https://github.com/pfefferle/wordpress-nodeinfo/',
);

$metadata['nodeName'] = \get_bloginfo( 'name' );
$metadata['nodeDescription'] = \get_bloginfo( 'description' );
$metadata['nodeIcon'] = \get_site_icon_url();

$this->metadata = apply_filters( 'nodeinfo2_data_metadata', $metadata, $this->version );
}
Expand Down
4 changes: 2 additions & 2 deletions languages/nodeinfo.pot
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
# This file is distributed under the MIT.
msgid ""
msgstr ""
"Project-Id-Version: NodeInfo 2.2.0\n"
"Project-Id-Version: NodeInfo 2.3.0\n"
"Report-Msgid-Bugs-To: "
"https://wordpress.org/support/plugin/wordpress-nodeinfo\n"
"POT-Creation-Date: 2023-10-16 15:44:17+00:00\n"
"POT-Creation-Date: 2023-12-22 14:57:32+00:00\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
Expand Down
2 changes: 1 addition & 1 deletion nodeinfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Plugin Name: NodeInfo
* Plugin URI: https://github.com/pfefferle/wordpress-nodeinfo/
* Description: NodeInfo is an effort to create a standardized way of exposing metadata about a server running one of the distributed social networks.
* Version: 2.2.0
* Version: 2.3.0
* Author: Matthias Pfefferle
* Author URI: https://notiz.blog/
* License: MIT
Expand Down
6 changes: 5 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Donate link: https://notiz.blog/donate/
Tags: nodeinfo, fediverse, ostatus, diaspora, activitypub
Requires at least: 4.9
Tested up to: 6.4
Stable tag: 2.2.0
Stable tag: 2.3.0
Requires PHP: 5.6
License: MIT
License URI: https://opensource.org/licenses/MIT
Expand All @@ -24,6 +24,10 @@ This plugin provides a barebone JSON file with basic "node"-informations. The fi

Project and support maintained on github at [pfefferle/wordpress-nodeinfo](https://github.com/pfefferle/wordpress-nodeinfo).

= 2.3.0 =

* add nodeName, nodeDescription and nodeIcon to meta array

= 2.2.0 =

* add MAUs
Expand Down

0 comments on commit 8ab7d95

Please sign in to comment.