Skip to content
This repository has been archived by the owner on Jun 28, 2021. It is now read-only.

Commit

Permalink
Documentation done!
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexandre-T committed Mar 17, 2020
1 parent 0e81268 commit 5daea7a
Show file tree
Hide file tree
Showing 12 changed files with 79 additions and 426 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ script:
else
./vendor/bin/phpunit -v --configuration ./tests/travis/$DB.travis.xml
fi
# Code shall respect rules
- composer check-quality-code

after_script:
- |
Expand All @@ -34,8 +36,6 @@ after_script:
fi
#Push code climate coverage
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
# Code should respect rules
- composer check-quality-code

notifications:
webhooks: https://coveralls.io/webhook?repo_token=$COVERALLS_WEBHOOK
Expand Down
7 changes: 4 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,15 @@
All notable changes to this project will be documented in this file using the [Keep a CHANGELOG](https://keepachangelog.com/) principles.
This project adheres to [Semantic Versioning](https://semver.org/).

## [Unreleased]
### Work in progress
- New file to help contributors to pull request a new spatial function and test it.
## [2.0.0-RC0] Release candidat - 2020-03-18

### Added
- A new documentation hosted on ReadTheDocs.
- Adding support of PHP7.2, PHP7.3, PHP7.4,
- Needed PHP extension added in composer.json,
- Spatial function implementing the ISO/IEC 13249-3:2016 or [OGC Standard](https://www.ogc.org/standards/sfs) are now stored in the [Standard](./lib/CrEOF/Spatial/ORM/Query/AST/Functions/Standard) directory.
- Specific spatial function of the PostgreSql server are now store in the [PostgreSql](./lib/CrEOF/Spatial/ORM/Query/AST/Functions/PostgreSql) directory.
- Specific spatial function of the PostgreSql server are now store in the [MySql](./lib/CrEOF/Spatial/ORM/Query/AST/Functions/MySql) directory.
- Code coverage is now really at 90 percent. (CreOf code coverage was not valid because of AST functions which contained only properties),
- AST Functions updated to avoid misconfiguration (some properties was missing),
- AST Functions updated to detect which function was not tested,
Expand Down
87 changes: 0 additions & 87 deletions CONTRIBUTING.md

This file was deleted.

63 changes: 27 additions & 36 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,57 +3,48 @@ Doctrine2 multi-platform support for spatial types and functions.
Currently MySQL and PostgreSQL with PostGIS are supported.
Could potentially add support for other platforms if an interest is expressed.

## Current status
[![Build Status](https://travis-ci.org/Alexandre-T/doctrine2-spatial.svg?branch=master)](https://travis-ci.org/Alexandre-T/doctrine2-spatial)
[![Code Climate](https://codeclimate.com/github/Alexandre-T/doctrine2-spatial/badges/gpa.svg)](https://codeclimate.com/github/Alexandre-T/doctrine2-spatial)
[![Coverage Status](https://coveralls.io/repos/Alexandre-T/doctrine2-spatial/badge.svg?branch=master&service=github)](https://coveralls.io/github/Alexandre-T/doctrine2-spatial?branch=master)
[![Downloads](https://img.shields.io/packagist/dm/Alexandre-T/doctrine2-spatial.svg)](https://packagist.org/packages/Alexandre-T/doctrine2-spatial)
[![Documentation Status](https://readthedocs.org/projects/doctrine2-spatial/badge/?version=latest)](https://doctrine2-spatial.readthedocs.io/en/latest/?badge=latest)

Documentation
-------------

The [new documentation](https://doctrine2-spatial.readthedocs.io) explain how to:

* install this doctrine extension,
* configure this extension,
* create spatial entities,
* use spatial functions into your repositories,
* contribute (and test)

The documentation contains a glossary of all available types and all available spatial functions.

## Project origins
This useful project was created by Derek J. Lambert.
Alexandre Tranchant forked it from [creof/doctrine2-spatial](https://github.com/creof/doctrine2-spatial)
because project seems to be unactive since 2017.
because project seems to be non-active since 2017.

The master release can be used, but be careful of backward incompatibility.

## Developments in progress
This fork will upgrade this package to the last doctrine version and the [PHP supported versions](https://www.php.net/supported-versions.php).
I would like to release the 2.0.0 version at the end of March.

The major update concerns the directories where functions are now stored.
* Spatial function implementing the ISO/IEC 13249-3:2016 or [OGC Standard](https://www.ogc.org/standards/sfs) are now
stored in the [Standard](./lib/CrEOF/Spatial/ORM/Query/AST/Functions/Standard) directory.
* Specific spatial function of the PostgreSql server are now store in the
[PostgreSql](./lib/CrEOF/Spatial/ORM/Query/AST/Functions/PostgreSql) directory.
* Specific spatial function of the PostgreSql server are now store in the
[MySql](./lib/CrEOF/Spatial/ORM/Query/AST/Functions/MySql) directory.

## Current status
[![Build Status](https://travis-ci.org/Alexandre-T/doctrine2-spatial.svg?branch=master)](https://travis-ci.org/Alexandre-T/doctrine2-spatial)
[![Code Climate](https://codeclimate.com/github/Alexandre-T/doctrine2-spatial/badges/gpa.svg)](https://codeclimate.com/github/Alexandre-T/doctrine2-spatial)
[![Coverage Status](https://coveralls.io/repos/Alexandre-T/doctrine2-spatial/badge.svg?branch=master&service=github)](https://coveralls.io/github/Alexandre-T/doctrine2-spatial?branch=master)
[![Downloads](https://img.shields.io/packagist/dm/Alexandre-T/doctrine2-spatial.svg)](https://packagist.org/packages/Alexandre-T/doctrine2-spatial)

### Documentation

*Documentation is already improved, but I'm working on a new documentation using sphinx and hosted on [ReadTheDocs](https://www.readthedocs.io/)
I will provide a lot of example, essentialy with a symfony project. Feel free to [contribute](./CONTRIBUTING.md)!*

Currently, the documentation is splitted into some files.
1. the [core of documentation](./doc/index.md),
2. the [needed installation steps](./doc/install.md),
3. if your using symfony framework, the [configuration page](./doc/configuration.md) explains how to configure your
symfony application, and how to configure the types and the spatial functions that you want to use in your application.
Do not forget, that it is not optimal to declare every types and every functions if you do not need them.
4. the [entity page](./doc/entity.md) describes how to create an ORM entity with spatial columns
5. the standard, postgresql and mysql contains a description of some of the implementable method

Compatibility
-------------
### PHP
This package to the last doctrine version and the [PHP supported versions](https://www.php.net/supported-versions.php).
This doctrine extension is compatible with PHP 7.2, 7.3 and 7.4
Security fixes will follow the [PHP Roadmap](https://www.php.net/supported-versions.php).

### Doctrine dev version
This version should be used with the actual doctrine stable version: 2.7
Continuous integration tests libraries does not implements the 2.8.x-dev version. It should change very soon.
I try to be compatible with this version.

Continuous integration tests libraries with 2.8.x-dev version. We **DO NOT* try to be compatible with this version,
currently. There is too much difference between interface declarations.
This extension should be used with the actual doctrine stable version: 2.7
Continuous integration tests libraries with 2.8.x-dev version. We **ONLY** try to stay compatible with this version,
currently.

### MySQL 5.7 and 8.0
A lot of functions change their names between this two versions. The [MySQL 5.7 deprecated functions](https://stackoverflow.com/questions/60377271/why-some-spatial-functions-does-not-exists-on-my-mysql-server)
Expand All @@ -62,7 +53,7 @@ are not implemented.
### MariaDB 10
This version is **NOT** compatible with MariaDB version. Some spatial functions seems to work but their results are
different from MySQL version (StContains function is a good example). You can contribute, but I suggest to avoid
MySql and MariaDb servers.
MySql and MariaDb servers, because of [their shortcomings and vulnerabilities](https://sqlpro.developpez.com/tutoriel/dangers-mysql-mariadb/).

### PostgreSQL
You should use PostgreSql server. This is a most powerful server and this is a "true" database server. It preserves data
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,13 @@
"php-cs-fixer fix --dry-run --config=.php_cs.dist --allow-risky=yes -vvv",
"phpcs --standard=phpcs.xml.dist -s",
"phpmd lib text ./phpmd.lib.xml",
"phpmd tests xml ./phpmd.test.xml --exclude OrmTestCase.php"
"phpmd tests text ./phpmd.test.xml --exclude OrmTestCase.php"
],
"phpcs": "phpcs --standard=phpcs.xml.dist -s",
"phpcsfixer": "php-cs-fixer --config=.php_cs.dist fix --allow-risky=yes -vvv",
"phpmd": [
"phpmd lib text ./phpmd.lib.xml",
"phpmd tests xml ./phpmd.test.xml --exclude OrmTestCase.php"
"phpmd tests text ./phpmd.test.xml --exclude OrmTestCase.php"
],
"test-mysql": "phpunit --configuration phpunit.mysql.xml",
"test-pgsql": "phpunit --configuration phpunit.pgsql.xml"
Expand Down
42 changes: 0 additions & 42 deletions doc/configuration.md

This file was deleted.

90 changes: 0 additions & 90 deletions doc/entity.md

This file was deleted.

Loading

0 comments on commit 5daea7a

Please sign in to comment.