diff --git a/.php_cs.dist b/.php_cs.dist index 3a6104c..9c4a372 100644 --- a/.php_cs.dist +++ b/.php_cs.dist @@ -35,6 +35,6 @@ return PhpCsFixer\Config::create() ->setFinder( PhpCsFixer\Finder::create() ->in(__DIR__ . "/examples") - ->in(__DIR__ . "/lib") + ->in(__DIR__ . "/src") ->in(__DIR__ . "/test") ); diff --git a/Makefile b/Makefile index 6c3291b..b9cf1b7 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ PHP_BIN := php COMPOSER_BIN := composer COVERAGE = coverage -SRCS = lib test +SRCS = src test find_php_files = $(shell find $(1) -type f -name "*.php") src = $(foreach d,$(SRCS),$(call find_php_files,$(d))) diff --git a/composer.json b/composer.json index 542bdcd..32c3478 100644 --- a/composer.json +++ b/composer.json @@ -29,11 +29,11 @@ }, "autoload": { "psr-4": { - "Amp\\Postgres\\": "lib" + "Amp\\Postgres\\": "src" }, "files": [ - "lib/functions.php", - "lib/Internal/functions.php" + "src/functions.php", + "src/Internal/functions.php" ] }, "autoload-dev": { diff --git a/phpunit.xml.dist b/phpunit.xml.dist index d34da9e..15350a0 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -19,10 +19,10 @@ - lib + src - \ No newline at end of file + diff --git a/lib/CommandResult.php b/src/CommandResult.php similarity index 100% rename from lib/CommandResult.php rename to src/CommandResult.php diff --git a/lib/Connection.php b/src/Connection.php similarity index 100% rename from lib/Connection.php rename to src/Connection.php diff --git a/lib/ConnectionException.php b/src/ConnectionException.php similarity index 100% rename from lib/ConnectionException.php rename to src/ConnectionException.php diff --git a/lib/Connector.php b/src/Connector.php similarity index 100% rename from lib/Connector.php rename to src/Connector.php diff --git a/lib/DefaultConnector.php b/src/DefaultConnector.php similarity index 100% rename from lib/DefaultConnector.php rename to src/DefaultConnector.php diff --git a/lib/Executor.php b/src/Executor.php similarity index 100% rename from lib/Executor.php rename to src/Executor.php diff --git a/lib/FailureException.php b/src/FailureException.php similarity index 100% rename from lib/FailureException.php rename to src/FailureException.php diff --git a/lib/Handle.php b/src/Handle.php similarity index 100% rename from lib/Handle.php rename to src/Handle.php diff --git a/lib/Internal/ArrayParser.php b/src/Internal/ArrayParser.php similarity index 100% rename from lib/Internal/ArrayParser.php rename to src/Internal/ArrayParser.php diff --git a/lib/Internal/PqStatementStorage.php b/src/Internal/PqStatementStorage.php similarity index 100% rename from lib/Internal/PqStatementStorage.php rename to src/Internal/PqStatementStorage.php diff --git a/lib/Internal/ReferenceQueue.php b/src/Internal/ReferenceQueue.php similarity index 100% rename from lib/Internal/ReferenceQueue.php rename to src/Internal/ReferenceQueue.php diff --git a/lib/Internal/StatementStorage.php b/src/Internal/StatementStorage.php similarity index 100% rename from lib/Internal/StatementStorage.php rename to src/Internal/StatementStorage.php diff --git a/lib/Internal/functions.php b/src/Internal/functions.php similarity index 100% rename from lib/Internal/functions.php rename to src/Internal/functions.php diff --git a/lib/Link.php b/src/Link.php similarity index 100% rename from lib/Link.php rename to src/Link.php diff --git a/lib/Listener.php b/src/Listener.php similarity index 100% rename from lib/Listener.php rename to src/Listener.php diff --git a/lib/Notification.php b/src/Notification.php similarity index 100% rename from lib/Notification.php rename to src/Notification.php diff --git a/lib/Operation.php b/src/Operation.php similarity index 100% rename from lib/Operation.php rename to src/Operation.php diff --git a/lib/ParseException.php b/src/ParseException.php similarity index 100% rename from lib/ParseException.php rename to src/ParseException.php diff --git a/lib/PgSqlCommandResult.php b/src/PgSqlCommandResult.php similarity index 100% rename from lib/PgSqlCommandResult.php rename to src/PgSqlCommandResult.php diff --git a/lib/PgSqlConnection.php b/src/PgSqlConnection.php similarity index 100% rename from lib/PgSqlConnection.php rename to src/PgSqlConnection.php diff --git a/lib/PgSqlHandle.php b/src/PgSqlHandle.php similarity index 100% rename from lib/PgSqlHandle.php rename to src/PgSqlHandle.php diff --git a/lib/PgSqlResultSet.php b/src/PgSqlResultSet.php similarity index 100% rename from lib/PgSqlResultSet.php rename to src/PgSqlResultSet.php diff --git a/lib/PgSqlStatement.php b/src/PgSqlStatement.php similarity index 100% rename from lib/PgSqlStatement.php rename to src/PgSqlStatement.php diff --git a/lib/Pool.php b/src/Pool.php similarity index 100% rename from lib/Pool.php rename to src/Pool.php diff --git a/lib/PoolError.php b/src/PoolError.php similarity index 100% rename from lib/PoolError.php rename to src/PoolError.php diff --git a/lib/PooledStatement.php b/src/PooledStatement.php similarity index 100% rename from lib/PooledStatement.php rename to src/PooledStatement.php diff --git a/lib/PqBufferedResultSet.php b/src/PqBufferedResultSet.php similarity index 100% rename from lib/PqBufferedResultSet.php rename to src/PqBufferedResultSet.php diff --git a/lib/PqCommandResult.php b/src/PqCommandResult.php similarity index 100% rename from lib/PqCommandResult.php rename to src/PqCommandResult.php diff --git a/lib/PqConnection.php b/src/PqConnection.php similarity index 100% rename from lib/PqConnection.php rename to src/PqConnection.php diff --git a/lib/PqHandle.php b/src/PqHandle.php similarity index 100% rename from lib/PqHandle.php rename to src/PqHandle.php diff --git a/lib/PqStatement.php b/src/PqStatement.php similarity index 100% rename from lib/PqStatement.php rename to src/PqStatement.php diff --git a/lib/PqUnbufferedResultSet.php b/src/PqUnbufferedResultSet.php similarity index 100% rename from lib/PqUnbufferedResultSet.php rename to src/PqUnbufferedResultSet.php diff --git a/lib/QueryError.php b/src/QueryError.php similarity index 100% rename from lib/QueryError.php rename to src/QueryError.php diff --git a/lib/QueryExecutionError.php b/src/QueryExecutionError.php similarity index 100% rename from lib/QueryExecutionError.php rename to src/QueryExecutionError.php diff --git a/lib/ResultSet.php b/src/ResultSet.php similarity index 100% rename from lib/ResultSet.php rename to src/ResultSet.php diff --git a/lib/Statement.php b/src/Statement.php similarity index 100% rename from lib/Statement.php rename to src/Statement.php diff --git a/lib/Transaction.php b/src/Transaction.php similarity index 100% rename from lib/Transaction.php rename to src/Transaction.php diff --git a/lib/TransactionError.php b/src/TransactionError.php similarity index 100% rename from lib/TransactionError.php rename to src/TransactionError.php diff --git a/lib/functions.php b/src/functions.php similarity index 100% rename from lib/functions.php rename to src/functions.php