Skip to content

Housekeeping git meta and tests, custom issue templates #972

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/.* export-ignore
/composer.lock export-ignore
/phpcs.xml.dist export-ignore
/phpunit.xml.dist export-ignore
/tests export-ignore
1 change: 0 additions & 1 deletion .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
github: noplanman, akalongman, jacklul
tidelift: packagist/longman%2Ftelegram-bot
patreon: phptelegrambot
liberapay: PHP-Telegram-Bot
Expand Down
26 changes: 0 additions & 26 deletions .github/ISSUE_TEMPLATE.md

This file was deleted.

55 changes: 55 additions & 0 deletions .github/ISSUE_TEMPLATE/BC_Break.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
---
name: 💥 BC Break
about: Have you encountered an issue during an upgrade? 💣
---

<!--
Before reporting a BC break, please consult the changelog and wiki entry for the particular version to make sure it's not an expected change:
- https://github.com/php-telegram-bot/core/blob/master/CHANGELOG.md
- https://github.com/php-telegram-bot/core/wiki/Breaking-backwards-compatibility
-->

### BC Break Report

<--
❗ NEVER put your Telegram API key or any other private details here. (like passwords, user IDs, etc.)
Substitute them like <API_KEY> or <USER_ID> etc.
-->

#### Required Information

<!-- Fill in the relevant information below to help triage your pull request. -->
<!-- Please enter exact version numbers, not just "latest" etc.! -->

| ? | !
| --- | ---
| Operating system | Name and version
| PHP Telegram Bot version | x.y.z
| PHP version | x.y.z
| MySQL version | x.y.z / none
| Update Method | Webhook / getUpdates
| Self-signed certificate | yes / no
| RAW update (if available) | `{...}`

#### Summary

<!-- Provide a summary describing the problem you are experiencing. -->

#### Previous behaviour

<!-- What was the previous (working) behaviour? -->

#### Current behaviour

<!-- What is the current (broken) behaviour? -->

#### How to reproduce

<!--
Provide steps to reproduce the bug.
If possible, also add any relevant code snippet.
-->

#### Expected behaviour

<!-- What was the expected (correct) behaviour? -->
45 changes: 45 additions & 0 deletions .github/ISSUE_TEMPLATE/Bug.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
---
name: 🐞 Bug Report
about: Something is broken? 🔨
---

### Bug Report

<--
❗ NEVER put your Telegram API key or any other private details here. (like passwords, user IDs, etc.)
Substitute them like <API_KEY> or <USER_ID> etc.
-->

#### Required Information

<!-- Fill in the relevant information below to help triage your pull request. -->
<!-- Please enter exact version numbers, not just "latest" etc.! -->

| ? | !
| --- | ---
| Operating system | Name and version
| PHP Telegram Bot version | x.y.z
| PHP version | x.y.z
| MySQL version | x.y.z / none
| Update Method | Webhook / getUpdates
| Self-signed certificate | yes / no
| RAW update (if available) | `{...}`

#### Summary

<!-- Provide a summary describing the problem you are experiencing. -->

### Current behaviour

<!-- What is the current (buggy) behaviour? -->

#### How to reproduce

<!--
Provide steps to reproduce the bug.
If possible, also add any relevant code snippet.
-->

#### Expected behaviour

<!-- What was the expected (correct) behaviour? -->
10 changes: 10 additions & 0 deletions .github/ISSUE_TEMPLATE/Feature_Request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: 🎉 Feature Request
about: You have a neat idea that should be implemented? 🎩
---

### Feature Request

#### Summary

<!-- Provide a summary of the feature you would like to see implemented. -->
37 changes: 37 additions & 0 deletions .github/ISSUE_TEMPLATE/Support_Question.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
name: ❓ Support Question
about: Have a problem that you can't figure out? 🤔
---

### Support Question

<!--
Before asking a question here, please try asking in the support group first.
https://telegram.me/PHP_Telegram_Bot_Support

Keep in mind that GitHub is primarily an issue tracker.
-->

<--
❗ NEVER put your Telegram API key or any other private details here. (like passwords, user IDs, etc.)
Substitute them like <API_KEY> or <USER_ID> etc.
-->

#### Required Information

<!-- Fill in the relevant information below to help triage your pull request. -->
<!-- Please enter exact version numbers, not just "latest" etc.! -->

| ? | !
| --- | ---
| Operating system | Name and version
| PHP Telegram Bot version | x.y.z
| PHP version | x.y.z
| MySQL version | x.y.z / none
| Update Method | Webhook / getUpdates
| Self-signed certificate | yes / no
| RAW update (if available) | `{...}`

#### Summary

<!-- Describe the issue you are facing here. -->
20 changes: 17 additions & 3 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
<!-- Important: If this pull request is not related to any issue and contains a new feature, please create an issue first for discussion. -->
<!--
Important:
If this pull request is not related to any issue and contains a new feature, please create an issue first for discussion.
https://github.com/php-telegram-bot/core/issues/new?template=Feature_Request.md

<!-- Make sure this pull request is pointed towards the "develop" branch and refers to any issue that it's related to! -->
Make sure this pull request is pointed towards the "develop" branch and refers to any issue that it's related to!
-->

<!-- Explain in detail what this pull request contains. -->
<!-- Fill in the relevant information below to help triage your pull request. -->

| ? | !
|--- | ---
| Type | bug / feature / improvement
| BC Break | yes / no
| Fixed issues | <!-- use #NUM format to reference an issue -->

#### Summary

<!-- Provide a summary of your change. -->
24 changes: 8 additions & 16 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,20 @@
.DS_Store
.idea
.phpintel
composer.phar

# Local System Files (i.e. cache, logs, etc.) #
/cache
/build/logs
/build/coverage
/tmp

# Test Related Files #
/phpunit.xml

#Exception output
TelegramException.log

# Composer
vendor/
/composer.phar
/vendor

# Test-Related Files
/clover.xml
/phpcs.xml
/phpunit.xml

# phpDocumentor Logs #
# phpDocumentor Logs
phpdoc-*

# OSX #
# OSX
._*
.Spotlight-V100
.Trashes
2 changes: 1 addition & 1 deletion .scrutinizer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,4 @@ checks:

tools:
external_code_coverage:
timeout: 120
timeout: 300
21 changes: 11 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,22 @@
dist: trusty
sudo: required
language: php
sudo: required
dist: trusty

addons:
mariadb: 10.1

cache:
directories:
- "$HOME/.composer/cache"
- vendor
- $HOME/.composer/cache

php:
- 5.5
- 5.6
- 7.0
- 7.1
- 7.2
- 7.3
- 7.2
- 7.1
- 7.0
- 5.6
- 5.5
- nightly
- hhvm

Expand Down Expand Up @@ -44,7 +45,7 @@ before_script:

script:
- composer check-code
- if [ "$TRAVIS_PHP_VERSION" == "7.2" ] ; then composer test-cov; else composer test; fi
- if [ "$TRAVIS_PHP_VERSION" == "7.3" ]; then composer test-cov; else composer test; fi

after_script:
- if [ "$TRAVIS_PHP_VERSION" == "7.2" ]; then composer test-cov-upload; fi
- if [ "$TRAVIS_PHP_VERSION" == "7.3" ]; then composer test-cov-upload; fi
26 changes: 13 additions & 13 deletions .github/CONTRIBUTING.md → CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,37 +1,37 @@
Contributing
-------------
# Contributing

The easiest way to contribute is to work on a checkout of your own fork.
When working on the `core` repository, it makes sense to rename your fork to `php-telegram-bot`.

Before you contribute code, please make sure it conforms to the PSR-2 coding standard and that the unit tests still pass.
Before you contribute code, please make sure it conforms to the PSR-12 coding standard and that the unit tests still pass.
You can run the following commands to check if everything is ready to submit:

cd php-telegram-bot
composer install
composer check-code
```bash
cd php-telegram-bot
composer install
composer check-code
```

Which should give you no output, indicating that there are no coding standard errors.
And then (remember to set up your test database!):

composer test
```bash
composer test
```

Which should give you no failures or errors. You can ignore any skipped tests as these are for external tools.

Pushing
-------
## Pushing

Development is based on the git flow branching model (see http://nvie.com/posts/a-successful-git-branching-model/)
If you fix a bug please push in hotfix branch.
If you develop a new feature please create a new branch.

Version
-------
## Version

Version number: 0.#version.#hotfix

Further code convention adopted
-------------------------------
## Further code convention adopted

- Each method and class is documented with a docblock

Expand Down
Loading