Skip to content

Commit

Permalink
Start the app
Browse files Browse the repository at this point in the history
Signed-off-by: Joas Schilling <coding@schilljs.com>
  • Loading branch information
nickvergessen committed Apr 11, 2018
0 parents commit 1027a35
Show file tree
Hide file tree
Showing 15 changed files with 1,375 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .drone.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
clone:
git:
image: plugins/git
depth: 1

pipeline:
signed-off-check:
image: nextcloudci/php7.0:php7.0-2
environment:
- APP_NAME=twofactor_nextcloud_notification
- CORE_BRANCH=master
- DB=sqlite
commands:
- wget https://raw.githubusercontent.com/nextcloud/travis_ci/master/before_install.sh
- bash ./before_install.sh $APP_NAME $CORE_BRANCH $DB
- cd ../server
- php ./build/signed-off-checker.php
when:
matrix:
TESTS: signed-off-check
matrix:
include:
- TESTS: signed-off-check
25 changes: 25 additions & 0 deletions .github/contributing.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
## Submitting issues

If you have questions about how to install or use Nextcloud, please direct these to our [forum][forum]. We are also available on [IRC][irc].

### Short version

* The [**issue template can be found here**][template]. Please always use the issue template when reporting issues.

### Guidelines
* Please search the existing issues first, it's likely that your issue was already reported or even fixed.
- Go to one of the repositories, click "issues" and type any word in the top search/command bar.
- You can also filter by appending e. g. "state:open" to the search string.
- More info on [search syntax within github](https://help.github.com/articles/searching-issues)
* This repository ([TwoFactor nextcloud notification](https://github.com/nickv-nextcloud/twofactor_nextcloud_notification/issues)) is *only* for issues within the TwoFactor nextcloud notification code.
* __SECURITY__: Report any potential security bug to us via [our HackerOne page](https://hackerone.com/nextcloud) or security@nextcloud.com following our [security policy](https://nextcloud.com/security/) instead of filing an issue in our bug tracker.
* Report the issue using our [template][template], it includes all the information we need to track down the issue.

Help us to maximize the effort we can spend fixing issues and adding new features, by not reporting duplicate issues.

[template]: https://raw.github.com/nextcloud/server/master/issue_template.md
[forum]: https://help.nextcloud.com/
[irc]: https://webchat.freenode.net/?channels=nextcloud

### Contribute Code and translations
Please check [server's contribution guidelines](https://github.com/nextcloud/server/blob/master/CONTRIBUTING.md#contributing-to-source-code) for further information about contributing code and translations.
71 changes: 71 additions & 0 deletions .github/issue_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
<!--
Thanks for reporting issues back to Nextcloud! This is the issue tracker of the TwoFactor nextcloud notification App, if you have any support question please check out https://help.nextcloud.com/. Find other components at https://github.com/nextcloud/core/blob/master/CONTRIBUTING.md#guidelines
To make it possible for us to help you please fill out below information carefully.
-->
### Steps to reproduce
1.
2.
3.

### Expected behaviour
Tell us what should happen

### Actual behaviour
Tell us what happens instead

### Server configuration
<!--
You can use the Issue Template application to prefill most of the required information: https://apps.nextcloud.com/apps/issuetemplate
-->

**Operating system**:

**Web server:**

**Database:**

**PHP version:**

**Nextcloud version:** (see Nextcloud admin page)

**Where did you install Nextcloud from:**

**List of activated apps:**

```
If you have access to your command line run e.g.:
sudo -u www-data php occ app:list
from within your Nextcloud installation folder
```

**Nextcloud configuration:**

```
If you have access to your command line run e.g.:
sudo -u www-data php occ config:list system
from within your Nextcloud installation folder
```

**Are you using an external user-backend, if yes which one:** LDAP/ActiveDirectory/Webdav/...

### Client configuration
**Browser:**

**Operating system:**

### Logs

#### Nextcloud log (data/nextcloud.log)
```
Insert your Nextcloud log here
```

#### Browser log
```
Insert your browser log here, this could for example include:
a) The javascript console log
b) The network log
c) ...
```
60 changes: 60 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# just sane ignores
.*.sw[po]
*.bak
*.BAK
*~
*.orig
*.class
.cvsignore
Thumbs.db
*.py[co]
_darcs/*
CVS/*
.svn/*
RCS/*
*.backup*

# kdevelop
.kdev
*.kdev4
*.kate-swp

# Lokalize
*lokalize*

# eclipse
.project
.settings

# netbeans
nbproject

# phpStorm
.idea
*.iml

# geany
*.geany

# Cloud9IDE
.settings.xml
.c9revisions

# vim ex mode
.vimrc

# Mac OS
.DS_Store

# WebFinger
.well-known
/.buildpath

# Tests - auto-generated files
/tests/Unit/coverage*
/tests/Unit/clover.xml
/tests/Unit/js/node_modules

/tests/Integration/composer.lock
/tests/Integration/output
/tests/Integration/vendor
12 changes: 12 additions & 0 deletions .scrutinizer.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
filter:
excluded_paths:
- 'l10n/*'
- 'tests/*'

imports:
- javascript
- php

tools:
external_code_coverage:
timeout: 7200 # Timeout in seconds: 2 hours
93 changes: 93 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
dist: trusty
sudo: required
language: php
php:
- 5.6
- 7.0
- 7.1

services:
- docker

addons:
apt:
packages:
- alien
- libaio1

cache:
directories:
- docker
apt: true

env:
global:
- CORE_BRANCH=master
- APP_NAME=twofactor_nextcloud_notification
matrix:
- DB=sqlite

branches:
only:
- master
- /^stable\d+(\.\d+)?$/

before_install:
- wget https://raw.githubusercontent.com/nextcloud/travis_ci/master/before_install.sh
- . ./before_install.sh $APP_NAME $CORE_BRANCH $DB

# Add some output debugging information
- cd ../server
- ./occ check
- ./occ status
- ./occ app:list
- ./occ app:enable $APP_NAME
- ./occ app:list

# Setup behat for integration tests
- cd apps/$APP_NAME/
- cd tests/Integration/
- sh -c "if [ '$INTEGRATION' = '1' ]; then composer install; fi"
- cd ../../

script:
# Test the app
- sh -c "if [ '$CODECHECK' = '1' ]; then find . -name \*.php -exec php -l \"{}\" \;; fi"
- cd ../../
- sh -c "if [ '$CODECHECK' = '1' ]; then ./occ app:check-code $APP_NAME -c private -c strong-comparison; fi"
- sh -c "if [ '$CODECHECK' = '2' ]; then ./occ app:check-code $APP_NAME -c deprecation; fi"
- cd apps/$APP_NAME/

# Run phpunit tests
- cd tests/Unit
- sh -c "if [ '$INTEGRATION' != '1' -a '$JSTESTS' != '1' -a '$CODECHECK' != '1' -a '$CODECHECK' != '2' ]; then phpunit --configuration phpunit.xml; fi"
- cd ../..

# Integration tests
- cd tests/Integration
- sh -c "if [ '$INTEGRATION' = '1' ]; then bash run.sh; fi"
- cd ../..

# Create coverage report
- cd tests/Unit
- sh -c "if [ '$INTEGRATION' != '1' -a '$JSTESTS' != '1' -a '$CODECHECK' != '1' -a '$CODECHECK' != '2' -a '$TRAVIS_PHP_VERSION' != 'hhvm' ]; then wget https://scrutinizer-ci.com/ocular.phar; fi"
- sh -c "if [ '$INTEGRATION' != '1' -a '$JSTESTS' != '1' -a '$CODECHECK' != '1' -a '$CODECHECK' != '2' -a '$TRAVIS_PHP_VERSION' != 'hhvm' ]; then php ocular.phar code-coverage:upload --format=php-clover clover.xml; fi"
- cd ../..

matrix:
include:
- php: 7.0
env: DB=mysql
- php: 7.0
env: DB=pgsql
- php: 7.0
env: DB=oracle
- php: 7.0
env: DB=mysql;CODECHECK=1
- php: 7.0
env: DB=mysql;CODECHECK=2
- php: 7.0
env: DB=mysql;INTEGRATION=1
allow_failures:
- env: DB=mysql;CODECHECK=2
fast_finish: true
Loading

0 comments on commit 1027a35

Please sign in to comment.