-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2769ec9
commit ac6cdf2
Showing
27 changed files
with
1,751 additions
and
112 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
|
||
\.idea/ | ||
|
||
vendor/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Changelog | ||
All notable changes to this project will be documented in this file. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
app_name=files_frommail | ||
|
||
project_dir=$(CURDIR)/../$(app_name) | ||
build_dir=$(CURDIR)/build/artifacts | ||
appstore_dir=$(build_dir)/appstore | ||
source_dir=$(build_dir)/source | ||
sign_dir=$(build_dir)/sign | ||
package_name=$(app_name) | ||
cert_dir=$(HOME)/.nextcloud/certificates | ||
codecov_token_dir=$(HOME)/.nextcloud/codecov_token | ||
version+=0.1.0 | ||
|
||
all: appstore | ||
|
||
release: appstore create-tag | ||
|
||
create-tag: | ||
git tag -s -a v$(version) -m "Tagging the $(version) release." | ||
git push origin v$(version) | ||
|
||
clean: | ||
rm -rf $(build_dir) | ||
rm -rf node_modules | ||
|
||
composer: | ||
composer install | ||
|
||
test: SHELL:=/bin/bash | ||
test: composer | ||
phpunit --coverage-clover=coverage.xml --configuration=tests/phpunit.xml tests | ||
@if [ -f $(codecov_token_dir)/$(app_name) ]; then \ | ||
bash <(curl -s https://codecov.io/bash) -t @$(codecov_token_dir)/$(app_name) ; \ | ||
fi | ||
|
||
|
||
appstore: composer clean | ||
mkdir -p $(sign_dir) | ||
rsync -a \ | ||
--exclude=/build \ | ||
--exclude=/docs \ | ||
--exclude=/l10n/templates \ | ||
--exclude=/l10n/.tx \ | ||
--exclude=/tests \ | ||
--exclude=/.git \ | ||
--exclude=/.github \ | ||
--exclude=/composer.json \ | ||
--exclude=/composer.lock \ | ||
--exclude=/l10n/l10n.pl \ | ||
--exclude=/CONTRIBUTING.md \ | ||
--exclude=/issue_template.md \ | ||
--exclude=/README.md \ | ||
--exclude=/.gitattributes \ | ||
--exclude=.gitignore \ | ||
--exclude=/.scrutinizer.yml \ | ||
--exclude=/.travis.yml \ | ||
--exclude=/Makefile \ | ||
--exclude=/vendor/picocms/pico/index.php \ | ||
$(project_dir)/ $(sign_dir)/$(app_name) | ||
tar -czf $(build_dir)/$(app_name)-$(version).tar.gz \ | ||
-C $(sign_dir) $(app_name) | ||
@if [ -f $(cert_dir)/$(app_name).key ]; then \ | ||
echo "Signing package…"; \ | ||
openssl dgst -sha512 -sign $(cert_dir)/$(app_name).key $(build_dir)/$(app_name)-$(version).tar.gz | openssl base64; \ | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,47 @@ | ||
# files_frommail | ||
### installation | ||
|
||
- need mailparse | ||
|
||
``` | ||
pecl install mailparse | ||
``` | ||
|
||
if fail: | ||
|
||
``` | ||
pecl download mailparse | ||
tar -zxvf mailparse-3.0.2.tgz | ||
cd mailparse-3.0.2/ | ||
phpize | ||
edit mailparse.c | ||
``` | ||
|
||
remove lines 34-37: | ||
> #if !HAVE_MBSTRING | ||
> #error The mailparse extension requires the mbstring extension! | ||
> #endif | ||
``` | ||
./configure --with-php-config=/usr/bin/php-config | ||
make | ||
make install | ||
echo "extension=mailparse.so" > /etc/php/7.0/mods-available/mailparse.ini | ||
cd /etc/php/7.0/apache2/conf.d/ | ||
ln -s /etc/php/7.0/mods-available/mailparse.ini ./20-mailparse.ini | ||
apachectl restart | ||
``` | ||
|
||
|
||
|
||
### configuration MTA: | ||
|
||
new entry in /etc/aliases: | ||
|
||
> files-artificial: "|/usr/bin/php -f /path/to/NextcloudMailCatcher.php" | ||
- execute _newaliases_ | ||
|
||
- if virtual alias, create a new alias: [email protected] -> [email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<?php | ||
/** | ||
* Files_FromMail - Recover your email attachments from your cloud. | ||
* | ||
* This file is licensed under the Affero General Public License version 3 or | ||
* later. See the COPYING file. | ||
* | ||
* @author Maxence Lange <[email protected]> | ||
* @copyright 2017 | ||
* @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\Files_FromMail\AppInfo; | ||
|
||
require_once __DIR__ . '/autoload.php'; | ||
|
||
new Application(); | ||
|
Oops, something went wrong.