diff options
author | Maxence Lange <maxence@artificial-owl.com> | 2018-10-01 14:14:23 +0200 |
---|---|---|
committer | Maxence Lange <maxence@artificial-owl.com> | 2018-10-01 14:14:23 +0200 |
commit | 4dddda0dc6db5535f4d6427c7e0bb62832e942db (patch) | |
tree | 132719cb0c6178da10fca90b23d3bc92d7dc4c57 | |
parent | 3e399899ed7d5d9a30e7ec60f7d5406b81299b7e (diff) |
social is now an activitypub server
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
61 files changed, 528 insertions, 3829 deletions
@@ -2,5 +2,3 @@ \.idea/ vendor/ - -test\.json diff --git a/appinfo/app.php b/appinfo/app.php index bc36b6e8..b871207c 100644 --- a/appinfo/app.php +++ b/appinfo/app.php @@ -29,7 +29,6 @@ declare(strict_types=1); namespace OCA\Social\AppInfo; -require_once __DIR__ . '/autoload.php'; require_once(__DIR__ . '/../lib/autoload.php'); //$app = new Application(); diff --git a/appinfo/autoload.php b/appinfo/autoload.php deleted file mode 100644 index 586cecf3..00000000 --- a/appinfo/autoload.php +++ /dev/null @@ -1,38 +0,0 @@ -<?php -declare(strict_types=1); - - -/** - * Nextcloud - Social Support - * - * This file is licensed under the Affero General Public License version 3 or - * later. See the COPYING file. - * - * @author Maxence Lange <maxence@artificial-owl.com> - * @copyright 2018, Maxence Lange <maxence@artificial-owl.com> - * @license GNU AGPL version 3 or any later version - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU Affero General Public License as - * published by the Free Software Foundation, either version 3 of the - * License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Affero General Public License for more details. - * - * You should have received a copy of the GNU Affero General Public License - * along with this program. If not, see <http://www.gnu.org/licenses/>. - * - */ - - -namespace OCA\Social\AppInfo; - -$composerDir = __DIR__ . '/../vendor/'; - -if (is_dir($composerDir) && file_exists($composerDir . 'autoload.php')) { - require_once $composerDir . 'autoload.php'; -} - diff --git a/appinfo/database.xml b/appinfo/database.xml index fe39af89..5d750abb 100644 --- a/appinfo/database.xml +++ b/appinfo/database.xml @@ -6,51 +6,6 @@ <charset>utf8</charset> <table> - <name>*dbprefix*social_services</name> - <declaration> - <field> - <name>id</name> - <type>integer</type> - <length>7</length> - <unsigned>true</unsigned> - <notnull>true</notnull> - <autoincrement>true</autoincrement> - <primary>true</primary> - </field> - - <field> - <name>type</name> - <type>text</type> - <length>15</length> - </field> - - <field> - <name>address</name> - <type>text</type> - <length>128</length> - </field> - - <field> - <name>config</name> - <type>text</type> - <length>3000</length> - </field> - - <field> - <name>status</name> - <type>integer</type> - <length>1</length> - </field> - - <field> - <name>creation</name> - <type>timestamp</type> - </field> - - </declaration> - </table> - - <table> <name>*dbprefix*social_accounts</name> <declaration> @@ -64,14 +19,6 @@ <primary>true</primary> </field> - // @deprecated - <field> - <name>service_id</name> - <type>integer</type> - <length>7</length> - <notnull>true</notnull> - </field> - <field> <name>user_id</name> <type>text</type> @@ -79,44 +26,9 @@ </field> <field> - <name>username</name> - <type>text</type> - <length>63</length> - </field> - - // @deprecated - <field> <name>account</name> <type>text</type> - <length>127</length> - </field> - - // @deprecated - <field> - <name>account_id</name> - <type>integer</type> - <length>7</length> - </field> - - // @deprecated - <field> - <name>status</name> - <type>integer</type> - <length>1</length> - </field> - - // @deprecated - <field> - <name>auth</name> - <type>text</type> - <length>2000</length> - </field> - - // @deprecated - <field> - <name>config</name> - <type>text</type> - <length>2000</length> + <length>63</length> </field> <field> @@ -340,48 +252,5 @@ </declaration> </table> - <table> - <name>*dbprefix*social_cache_actors</name> - <declaration> - - <field> - <name>id</name> - <type>integer</type> - <length>8</length> - <unsigned>true</unsigned> - <notnull>true</notnull> - <autoincrement>true</autoincrement> - <primary>true</primary> - </field> - - <field> - <name>account</name> - <type>text</type> - <length>127</length> - <notnull>true</notnull> - </field> - - <field> - <name>url</name> - <type>text</type> - <length>127</length> - <notnull>true</notnull> - </field> - - <field> - <name>actor</name> - <type>text</type> - <length>8000</length> - <notnull>true</notnull> - </field> - - <field> - <name>creation</name> - <type>timestamp</type> - </field> - - </declaration> - </table> - </database> diff --git a/appinfo/info.xml b/appinfo/info.xml index 058e8160..44c49921 100644 --- a/appinfo/info.xml +++ b/appinfo/info.xml @@ -5,7 +5,7 @@ <name>Social</name> <summary>🎉 Nextcloud becomes part of the federated social networks!</summary> <description><![CDATA[test]]></description> - <version>0.0.17</version> + <version>0.0.18</version> <licence>agpl</licence> <author mail="maxence@artificial-owl.com">Maxence Lange</author> <author mail="jus@bitgrid.net">Julius Härtl</author> diff --git a/appinfo/routes.php b/appinfo/routes.php index 20642577..4a7ef39d 100644 --- a/appinfo/routes.php +++ b/appinfo/routes.php @@ -11,37 +11,7 @@ return [ 'routes' => [ ['name' => 'Navigation#navigate', 'url' => '/', 'verb' => 'GET'], - [ - 'name' => 'ServiceAccounts#getAvailableAccounts', 'url' => '/user/accounts', - 'verb' => 'GET' - ], - [ - 'name' => 'ServiceAccounts#create', 'url' => '/user/account', - 'verb' => 'POST' - ], - [ - 'name' => 'ActivityStreams#test', 'url' => '/user/account/{accountId}/test', - 'verb' => 'GET' - ], - [ - 'name' => 'ActivityStreams#statuses', 'url' => '/user/account/{accountId}/statuses', - 'verb' => 'GET' - ], - [ - 'name' => 'ActivityStreams#follows', 'url' => '/user/account/{accountId}/follows', - 'verb' => 'GET' - ], - - // [ - // 'name' => 'OAuth2#getAuthUrl', 'url' => '/client/oauth2/auth/{serviceId}/', - // 'verb' => 'GET' - // ], - [ - 'name' => 'OAuth2#setCode', 'url' => '/client/oauth2/redirect/{serviceId}/', - 'verb' => 'GET' - ], - - ['name' => 'Account#create', 'url' => '/local/account/{username}', 'verb' => 'POST'], + ['name' => 'Account#create', 'url' => '/local/account/{username}', 'verb' => 'GET'], ['name' => 'ActivityPub#sharedInbox', 'url' => '/inbox', 'verb' => 'POST'], ['name' => 'ActivityPub#actor', 'url' => '/users/{username}', 'verb' => 'GET'], @@ -52,9 +22,9 @@ return [ ['name' => 'ActivityPub#following', 'url' => '/@{username}/following', 'verb' => 'GET'], ['name' => 'SocialPub#displayPost', 'url' => '/@{username}/{postId}', 'verb' => 'GET'] -, + , ['name' => 'ActivityPub#test', 'url' => '/inbox/{username}', 'verb' => 'POST'], -] + ] ]; diff --git a/composer.json b/composer.json deleted file mode 100644 index 4969f567..00000000 --- a/composer.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "name": "vendor_name/package_name", - "description": "description_text", - "minimum-stability": "stable", - "license": "proprietary", - "authors": [ - { - "name": "author's name", - "email": "email@example.com" - } - ], - "require": { - "league/oauth2-client": "2.3.0", - "lrf141/oauth2-mastodon": "1.0.1" - } -} diff --git a/composer.lock b/composer.lock deleted file mode 100644 index 10217eb8..00000000 --- a/composer.lock +++ /dev/null @@ -1,422 +0,0 @@ -{ - "_readme": [ - "This file locks the dependencies of your project to a known state", - "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", - "This file is @generated automatically" - ], - "content-hash": "61a7838c51e287d8fb6c226460fd4e2c", - "packages": [ - { - "name": "guzzlehttp/guzzle", - "version": "6.3.3", - "source": { - "type": "git", - "url": "https://github.com/guzzle/guzzle.git", - "reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/407b0cb880ace85c9b63c5f9551db498cb2d50ba", - "reference": "407b0cb880ace85c9b63c5f9551db498cb2d50ba", - "shasum": "" - }, - "require": { - "guzzlehttp/promises": "^1.0", - "guzzlehttp/psr7": "^1.4", - "php": ">=5.5" - }, - "require-dev": { - "ext-curl": "*", - "phpunit/phpunit": "^4.8.35 || ^5.7 || ^6.4 || ^7.0", - "psr/log": "^1.0" - }, - "suggest": { - "psr/log": "Required for using the Log middleware" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "6.3-dev" - } - }, - "autoload": { - "files": [ - "src/functions_include.php" - ], - "psr-4": { - "GuzzleHttp\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Michael Dowling", - "email": "mtdowling@gmail.com", - "homepage": "https://github.com/mtdowling" - } - ], - "description": "Guzzle is a PHP HTTP client library", - "homepage": "http://guzzlephp.org/", - "keywords": [ |