This repository has been archived by the owner on Oct 15, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Releasing refs/heads/release/2.0.0 into master (#18)
* add migrator console * Add but more documentation * fix up readme * schema should not depend on development packages * develop to require develop versions * fix alter field * add drop field * add comment * add changelog * fix version requirement * Update composer.json * Update composer.json * Update composer.json * Update BasicTest.php * Update SchemaTestcaseTest.php * Update phpunit.xml * Update .travis.yml * Update phpunit.xml * Update SchemaTestcaseTest.php * Update phpunit.xml * Update SchemaTestcaseTest.php * Update .travis.yml * Update .travis.yml * Update .travis.yml * Update SchemaTestcaseTest.php * move abstract testcase to tests * Apply fixes from StyleCI * enable debug * Apply fixes from StyleCI * move * fix dsn * proper dsn * Update README.md * globals * Apply fixes from StyleCI * work on dsn * Apply fixes from StyleCI * ouch * include both tests - sqlite and mysql * fix * fix types * disable unsupported test * add comment * remove debug * fix codeclimate config * fix escape_char * debug * Apply fixes from StyleCI * crap * PostGre suppport * set max_connections * support PostGreSQL starting from v.10 only * get rid of connection * Update .codeclimate.yml * add support for changing field name * Apply fixes from StyleCI * Update Migration.php * add rename table support * Extend to all DataType options with PHPUnit Tests * add transcode table for field type => datatype database * tested on SQLite and MySQL * Change default Type from VARCHAR256 to TEXT more space is better than less, this class is very useful during development, after that will be disabled and database must be optimized with other tools. i changed because i had a problem storing serialized EXIF in array datatype * drop php 5.6 support * Add transcoding for Field Reference_One climate error correction * Reformatting and change variables name switch to codeformatting PSR-1,PSR-2 add hasOne in Test * add creation of file models class via console to "reverse engineering" DB fixed mysql float was mistyped uppercase * Add Doc for function createModelFromTable * Adjust naming for transcodes on SQLite * add hasOne detect field type * Remove some editor autoadd - f... phpstorm * format code in ->getTranscodeTypeKeyFromField * compatibility with new data namespace * Apply fixes from StyleCI * better handling of text, array and object fields. also fix few others. * Apply fixes from StyleCI * add type options * added changelog * working on version dependencies * for development branch we need development dependencies * make types easier to extend and improve PgSQL types support * Apply fixes from StyleCI * more dependencies and easier to extend migrator console * oops * no need for this anymore * implements factory method getMigration, uses connection->driver, few changes in phpunit test suite, more tests * Apply fixes from StyleCI * change docs * Better PostgreSQL support * fix datetime mess * typo * use getFields() in Model rather than hack through elements * Composer - Drop PHP < 7.2 * Big refactor * Merge remote-tracking branch 'remotes/atk4/develop' into add-type-transcoding * StyleCi * StyleCi 1 * remove php < 7.2 from travis * Removed function for creation of Model File * Refactor variable names and removed extra line * Refactor 1 comment to be consistent with the others below * Add support for GitHub actions (#17) * Add GitHub Action support * disable travis * tweak bundler * wip * wip * wip * Setting current dependencies
- Loading branch information
1 parent
5d0065a
commit 2d39d8f
Showing
27 changed files
with
1,063 additions
and
340 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 |
---|---|---|
@@ -1,48 +1,53 @@ | ||
engines: | ||
duplication: | ||
enabled: true | ||
config: | ||
languages: | ||
- php | ||
fixme: | ||
enabled: true | ||
version: "2" | ||
plugins: | ||
# Disabling plugins until there is a reasonable way to sanitize their output | ||
phpcodesniffer: | ||
enabled: false | ||
config: | ||
standard: "PSR1,PSR2" | ||
ignore_warnings: true | ||
encoding: utf-8 | ||
phpmd: | ||
enabled: true | ||
exclude_fingerprints: | ||
checks: | ||
CyclomaticComplexity: | ||
enabled: false | ||
Design/TooManyPublicMethods: | ||
enabled: false | ||
Design/TooManyMethods: | ||
enabled: false | ||
Design/NpathComplexity: | ||
enabled: false | ||
Design/WeightedMethodCount: | ||
enabled: false | ||
Design/LongClass: | ||
enabled: false | ||
Controversial/CamelCaseMethodName: | ||
enabled: false | ||
Controversial/CamelCaseParameterName: | ||
enabled: false | ||
Controversial/CamelCasePropertyName: | ||
enabled: false | ||
Controversial/CamelCaseVariableName: | ||
enabled: false | ||
Controversial/CamelCaseClassName: | ||
enabled: false | ||
Naming/ShortVariable: | ||
enabled: false | ||
CleanCode/ElseExpression: | ||
enabled: false | ||
enabled: false | ||
sonar-php: | ||
enabled: false | ||
|
||
checks: | ||
argument-count: | ||
config: | ||
threshold: 4 | ||
complex-logic: | ||
config: | ||
threshold: 4 | ||
file-lines: | ||
config: | ||
threshold: 1000 | ||
method-complexity: | ||
config: | ||
threshold: 40 | ||
method-count: | ||
config: | ||
threshold: 40 | ||
method-lines: | ||
config: | ||
threshold: 100 | ||
nested-control-flow: | ||
config: | ||
threshold: 4 | ||
return-statements: | ||
config: | ||
threshold: 4 | ||
similar-code: | ||
config: | ||
threshold: 100 | ||
identical-code: | ||
config: | ||
threshold: 150 | ||
|
||
radon: | ||
enabled: true | ||
ratings: | ||
paths: | ||
- src/** | ||
exclude_paths: | ||
- docs/**/* | ||
- tests/**/* | ||
- vendor/**/* | ||
- src/**/* | ||
exclude_patterns: | ||
- docs/**/* | ||
- tests/**/* | ||
- 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,9 @@ | ||
# See https://github.com/release-drafter/release-drafter#configuration | ||
categories: | ||
- title: 'Enhancements' | ||
labels: | ||
- enhancement | ||
template: | | ||
## What’s Changed | ||
$CHANGES |
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,45 @@ | ||
name: Bundler | ||
|
||
on: create | ||
|
||
jobs: | ||
autocommit: | ||
name: Update to stable dependencies | ||
if: startsWith(github.ref, 'refs/heads/release/') | ||
runs-on: ubuntu-latest | ||
container: | ||
image: atk4/image:latest # https://github.com/atk4/image | ||
steps: | ||
- uses: actions/checkout@master | ||
- run: echo ${{ github.ref }} | ||
- name: Update to stable dependencies | ||
run: | | ||
jq 'del(.require["atk4/dsql"]) | del(.["require-dev"]["atk4/ui"]) | del(.["require-dev"]["atk4/data"])' < composer.json > tmp && mv tmp composer.json | ||
composer require --no-progress --no-suggest --prefer-dist --optimize-autoloader atk4/dsql | ||
#composer require --dev atk4/data # atk4/ui - removed temporarily until atk4/ui is released | ||
composer update --no-suggest --prefer-dist --optimize-autoloader | ||
- uses: teaminkling/autocommit@master | ||
with: | ||
commit-message: Setting current dependencies | ||
- uses: ad-m/github-push-action@master | ||
with: | ||
branch: ${{ github.ref }} | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: pull-request | ||
uses: repo-sync/pull-request@v2 | ||
with: | ||
source_branch: "" # If blank, default: triggered branch | ||
destination_branch: "master" # If blank, default: master | ||
pr_title: "Releasing ${{ github.ref }} into master" | ||
pr_body: | | ||
- [ ] Review changes (must include stable dependencies) | ||
- [ ] Merge this PR into master (will delete ${{ github.ref }}) | ||
- [ ] Go to Releases and create TAG from master | ||
Do not merge master into develop | ||
pr_reviewer: "romaninsh" | ||
pr_assignee: "romaninsh" | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
|
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,16 @@ | ||
name: Release Drafter | ||
|
||
on: | ||
push: | ||
# branches to consider in the event; optional, defaults to all | ||
branches: | ||
- develop | ||
|
||
jobs: | ||
update_release_draft: | ||
runs-on: ubuntu-latest | ||
steps: | ||
# Drafts your next Release notes as Pull Requests are merged into "master" | ||
- uses: toolmantim/[email protected] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
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,59 @@ | ||
name: Unit Testing | ||
|
||
on: | ||
pull_request: | ||
branches: '*' | ||
push: | ||
branches: | ||
- master | ||
- develop | ||
|
||
jobs: | ||
unit-test: | ||
name: Unit Testing | ||
runs-on: ubuntu-latest | ||
container: | ||
image: atk4/image:${{ matrix.php }} # https://github.com/atk4/image | ||
strategy: | ||
matrix: | ||
php: ['7.2', '7.3', 'latest'] | ||
services: | ||
mysql: | ||
image: mysql:5.7 | ||
env: | ||
MYSQL_ROOT_PASSWORD: password | ||
DB_DATABASE: dsql_test | ||
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=5 | ||
steps: | ||
- uses: actions/checkout@v1 | ||
- run: php --version | ||
- name: Get Composer Cache Directory | ||
id: composer-cache | ||
run: | | ||
echo "::set-output name=dir::$(composer config cache-files-dir)" | ||
- uses: actions/cache@v1 | ||
with: | ||
path: ${{ steps.composer-cache.outputs.dir }} | ||
key: ${{ runner.os }}-composer-${{ hashFiles('composer.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-composer- | ||
- run: composer install --no-progress --no-suggest --prefer-dist --optimize-autoloader | ||
|
||
- name: Run Tests | ||
run: | | ||
mkdir -p build/logs | ||
mysql -uroot -ppassword -h mysql -e 'CREATE DATABASE dsql_test;' | ||
- name: SQLite Testing | ||
run: vendor/bin/phpunit --configuration phpunit.xml --coverage-text --exclude-group dns | ||
|
||
- name: MySQL Testing | ||
run: vendor/bin/phpunit --configuration phpunit-mysql.xml --exclude-group dns | ||
|
||
- name: Merge coverage logs | ||
run: vendor/bin/phpcov merge build/logs/ --clover build/logs/cc.xml; | ||
|
||
- uses: codecov/codecov-action@v1 | ||
with: | ||
token: ${{ secrets.CODECOV_TOKEN }} | ||
file: build/logs/cc.xml |
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 |
---|---|---|
|
@@ -3,3 +3,4 @@ docs/build | |
/build | ||
/vendor | ||
.DS_Store | ||
/.idea/ |
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,51 @@ | ||
language: php | ||
|
||
php: | ||
- '7.2' | ||
- '7.3' | ||
|
||
cache: | ||
directories: | ||
- $HOME/.composer/cache | ||
|
||
services: | ||
- mysql | ||
|
||
before_script: | ||
- composer self-update | ||
- composer install --no-ansi | ||
- mysql -e 'create database dsql_test;' | ||
- mysql -e 'SET GLOBAL max_connections = 1000;' | ||
- mkdir -p build/logs | ||
|
||
script: | ||
- if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.2" ]]; then CM=""; NC=""; else CM=""; NC="--no-coverage"; fi | ||
- $CM ./vendor/bin/phpunit --configuration phpunit.xml $NC | ||
- $CM ./vendor/bin/phpunit --configuration phpunit-mysql.xml $NC | ||
|
||
after_script: | ||
- if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.2" ]]; then | ||
echo "Merging coverage reports:"; | ||
vendor/bin/phpcov merge build/logs/ --clover build/logs/cc.xml; | ||
echo "We now have these coverage files:"; | ||
ls -l build/logs; | ||
echo "Sending codeclimate report:"; | ||
vendor/bin/test-reporter --coverage-report build/logs/cc.xml; | ||
echo "Sending codecov report:"; | ||
TRAVIS_CMD="" bash <(curl -s https://codecov.io/bash) -f build/logs/cc.xml; | ||
fi | ||
|
||
notifications: | ||
slack: | ||
rooms: | ||
- agiletoolkit:bjrKuPBf1h4cYiNxPBQ1kF6c#dsql | ||
on_success: change | ||
|
||
urls: | ||
- https://webhooks.gitter.im/e/b33a2db0c636f34bafa9 | ||
|
||
on_success: change # options: [always|never|change] default: always | ||
on_failure: always # options: [always|never|change] default: always | ||
on_start: never # options: [always|never|change] default: always | ||
|
||
email: false |
This file was deleted.
Oops, something went wrong.
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
Oops, something went wrong.