This repository has been archived by the owner on Aug 28, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from bitpay/master
Sync with Bitpay
Showing
19 changed files
with
911 additions
and
59 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 |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# The MIT License (MIT) | ||
# | ||
# Copyright (c) 2011-2014 BitPay | ||
# | ||
# Permission is hereby granted, free of charge, to any person obtaining a copy | ||
# of this software and associated documentation files (the "Software"), to deal | ||
# in the Software without restriction, including without limitation the rights | ||
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
# copies of the Software, and to permit persons to whom the Software is | ||
# furnished to do so, subject to the following conditions: | ||
# | ||
# The above copyright notice and this permission notice shall be included in | ||
# all copies or substantial portions of the Software. | ||
# | ||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
# THE SOFTWARE. | ||
|
||
# These files/directories are not included when making | ||
# an archive of this repository. | ||
/build export-ignore | ||
/tests export-ignore | ||
.gitattributes export-ignore | ||
.gitignore export-ignore | ||
.travis.yml export-ignore | ||
build.xml export-ignore | ||
composer.json export-ignore |
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,28 @@ | ||
# The MIT License (MIT) | ||
# | ||
# Copyright (c) 2011-2014 BitPay | ||
# | ||
# Permission is hereby granted, free of charge, to any person obtaining a copy | ||
# of this software and associated documentation files (the "Software"), to deal | ||
# in the Software without restriction, including without limitation the rights | ||
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
# copies of the Software, and to permit persons to whom the Software is | ||
# furnished to do so, subject to the following conditions: | ||
# | ||
# The above copyright notice and this permission notice shall be included in | ||
# all copies or substantial portions of the Software. | ||
# | ||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
# THE SOFTWARE. | ||
/bin/ | ||
/build/cache/ | ||
/build/docs/ | ||
/build/logs/ | ||
/vendor/ | ||
composer.lock | ||
composer.phar |
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,33 @@ | ||
# The MIT License (MIT) | ||
# | ||
# Copyright (c) 2011-2014 BitPay | ||
# | ||
# Permission is hereby granted, free of charge, to any person obtaining a copy | ||
# of this software and associated documentation files (the "Software"), to deal | ||
# in the Software without restriction, including without limitation the rights | ||
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
# copies of the Software, and to permit persons to whom the Software is | ||
# furnished to do so, subject to the following conditions: | ||
# | ||
# The above copyright notice and this permission notice shall be included in | ||
# all copies or substantial portions of the Software. | ||
# | ||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
# THE SOFTWARE. | ||
language: php | ||
php: | ||
- 5.5 | ||
- 5.4 | ||
- 5.3 | ||
install: | ||
- composer install | ||
script: ./bin/phing -propertyfile build/travis.properties build-travis | ||
cache: | ||
directories: | ||
- build/cache/ | ||
- 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,11 @@ | ||
Version 4 | ||
* Fix to use server error handling | ||
|
||
Version 3 | ||
* Added new HTTP header for version tracking | ||
|
||
Version 2 | ||
* Updated to support API key instead of SSL files. Tested against Zen Cart 1.5.1. | ||
|
||
Version 1 | ||
* Initial version, tested against Zen Cart 1.3.9h |
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,21 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) 2011-2014 BitPay | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in | ||
all copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
THE SOFTWARE. |
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
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,3 +1,23 @@ | ||
# The MIT License (MIT) | ||
# | ||
# Copyright (c) 2011-2014 BitPay | ||
# | ||
# Permission is hereby granted, free of charge, to any person obtaining a copy | ||
# of this software and associated documentation files (the "Software"), to deal | ||
# in the Software without restriction, including without limitation the rights | ||
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
# copies of the Software, and to permit persons to whom the Software is | ||
# furnished to do so, subject to the following conditions: | ||
# | ||
# The above copyright notice and this permission notice shall be included in | ||
# all copies or substantial portions of the Software. | ||
# | ||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
# THE SOFTWARE. | ||
Order deny,allow | ||
Deny from all | ||
|
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
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
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,3 +1,26 @@ | ||
<?php | ||
/** | ||
* The MIT License (MIT) | ||
* | ||
* Copyright (c) 2011-2014 BitPay | ||
* | ||
* Permission is hereby granted, free of charge, to any person obtaining a copy | ||
* of this software and associated documentation files (the "Software"), to deal | ||
* in the Software without restriction, including without limitation the rights | ||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
* copies of the Software, and to permit persons to whom the Software is | ||
* furnished to do so, subject to the following conditions: | ||
* | ||
* The above copyright notice and this permission notice shall be included in | ||
* all copies or substantial portions of the Software. | ||
* | ||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
* THE SOFTWARE. | ||
*/ | ||
ob_start(); | ||
header('Location: ' . $_SERVER['SERVER_NAME']); |
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
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,200 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
/** | ||
* The MIT License (MIT) | ||
* | ||
* Copyright (c) 2011-2014 BitPay | ||
* | ||
* Permission is hereby granted, free of charge, to any person obtaining a copy | ||
* of this software and associated documentation files (the "Software"), to deal | ||
* in the Software without restriction, including without limitation the rights | ||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
* copies of the Software, and to permit persons to whom the Software is | ||
* furnished to do so, subject to the following conditions: | ||
* | ||
* The above copyright notice and this permission notice shall be included in | ||
* all copies or substantial portions of the Software. | ||
* | ||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
* THE SOFTWARE. | ||
*/ | ||
--> | ||
<project name="bitpay/build-script" default="build"> | ||
<!-- | ||
Default properties | ||
--> | ||
<property file="${project.basedir}/build/build.properties" /> | ||
|
||
<!-- | ||
Default build for running a build locally | ||
--> | ||
<target name="build" depends="prepare" | ||
description="Runs a full build"> | ||
<phingcall target="lint" /> | ||
<phingcall target="phpunit" /> | ||
<parallel threadCount="5"> | ||
<phingcall target="phpcs" /> | ||
<phingcall target="phpmd" /> | ||
<phingcall target="phploc" /> | ||
<phingcall target="pdepend" /> | ||
<phingcall target="build-api-docs" /> | ||
</parallel> | ||
</target> | ||
|
||
<!-- | ||
Build API and other documentation | ||
--> | ||
<target name="build-api-docs" depends="prepare" | ||
description="Generates API docs for the project"> | ||
<delete dir="${phpdoc.target}" verbose="true" /> | ||
<exec executable="${project.bindir}/phpdoc" passthru="true"> | ||
<arg value="--directory=${phpdoc.directory}" /> | ||
<arg value="--target=${phpdoc.target}" /> | ||
<arg line="--ignore=${phpdoc.ignore}" /> | ||
</exec> | ||
</target> | ||
|
||
<!-- | ||
Used to run a build on Travis CI | ||
--> | ||
<target name="build-travis" hidden="true" | ||
description="Runs a build that is specific to the Travis CI environment"> | ||
<phingcall target="build" /> | ||
</target> | ||
|
||
<!-- | ||
Generates documentation that can be uploaded to a web site and is meant | ||
to be used elsewhere by the project. | ||
--> | ||
<target name="build-docs" | ||
description="Generates documentation"> | ||
<fail message="Needs to be configured" /> | ||
</target> | ||
|
||
<!-- | ||
Generates a distribution file that can then be used for uploading to | ||
various plugin specific sites for users to download. | ||
--> | ||
<target name="build-dist" | ||
description="Builds a distribution file"> | ||
<fail message="Needs to be configured" /> | ||
</target> | ||
|
||
<!-- | ||
Cleans up and makes sure that the build is | ||
clean | ||
--> | ||
<target name="clean" hidden="true"> | ||
<delete dir="build/docs" verbose="true" /> | ||
<delete dir="build/logs" verbose="true" /> | ||
</target> | ||
|
||
<!-- | ||
Prepares the project for a build | ||
--> | ||
<target name="prepare" depends="clean" hidden="true"> | ||
<mkdir dir="build/cache" /> | ||
<mkdir dir="build/logs" /> | ||
</target> | ||
|
||
<!-- | ||
Lint check all php files, this task should be updated for each | ||
project so it only lint checks files specific for that project | ||
--> | ||
<target name="lint" | ||
description="Check the syntax of PHP files"> | ||
<phplint cachefile="${project.basedir}/build/cache/phplint.cache"> | ||
<fileset dir="${project.basedir}/"> | ||
<include name="**/*.php"/> | ||
<exclude name="**/build/**"/> | ||
<exclude name="**/bin/**"/> | ||
<exclude name="**/vendor/**"/> | ||
</fileset> | ||
</phplint> | ||
</target> | ||
|
||
<!-- | ||
phpunit - Runs phpunit with the phpunit.xml.dist file | ||
http://phpunit.de/ | ||
--> | ||
<target name="phpunit" | ||
description="Runs unit tests"> | ||
<exec executable="${project.bindir}/phpunit" passthru="true"> | ||
<arg value="-c" /> | ||
<arg path="${phpunit.configuration}" /> | ||
</exec> | ||
</target> | ||
|
||
<!-- | ||
PHP Mess Detector | ||
http://phpmd.org | ||
--> | ||
<target name="phpmd" | ||
description="Runs PHP Mess Detector"> | ||
<delete file="${phpmd.report.file}" /> | ||
<exec executable="${project.bindir}/phpmd" passthru="true"> | ||
<arg path="${phpmd.source}" /> | ||
<arg value="${phpmd.report.format}" /> | ||
<arg value="${phpmd.ruleset}" /> | ||
<arg line="--reportfile ${phpmd.report.file}" /> | ||
<arg line="--exclude ${phpmd.exclude}" /> | ||
</exec> | ||
</target> | ||
|
||
<!-- | ||
PHP Lines of Code - Generates a CSV and XML log of how many lines | ||
the project is. | ||
https://github.com/sebastianbergmann/phploc | ||
--> | ||
<target name="phploc" | ||
description="Calculates the size of the code base"> | ||
<delete file="${phploc.log.csv}" /> | ||
<delete file="${phploc.log.xml}" /> | ||
<exec executable="${project.basedir}/bin/phploc" passthru="true"> | ||
<arg line="--exclude=${phploc.exclude}" /> | ||
<arg value="--log-csv=${phploc.log.csv}" /> | ||
<arg value="--log-xml=${phploc.log.xml}" /> | ||
<arg path="${phploc.source}" /> | ||
</exec> | ||
</target> | ||
|
||
<!-- | ||
PHP Depend | ||
http://pdepend.org/ | ||
--> | ||
<target name="pdepend" | ||
description="Generates some code metrics and pretty pictures"> | ||
<delete file="${pdepend.jdepend.xml}" /> | ||
<delete file="${pdepend.summary.xml}" /> | ||
<exec executable="${project.bindir}/pdepend" passthru="true"> | ||
<arg value="--jdepend-chart=${pdepend.jdepend.chart}" /> | ||
<arg value="--jdepend-xml=${pdepend.jdepend.xml}" /> | ||
<arg value="--overview-pyramid=${pdepend.overview.pyramid}" /> | ||
<arg value="--summary-xml=${pdepend.summary.xml}" /> | ||
<arg value="--ignore=${pdepend.ignore}" /> | ||
<arg path="${pdepend.source}" /> | ||
</exec> | ||
</target> | ||
|
||
<!-- | ||
PHP Code Sniffer - Makes sure the code meets standards, this | ||
needs to be updated for each project | ||
https://github.com/squizlabs/PHP_CodeSniffer | ||
--> | ||
<target name="phpcs" | ||
description="Runs PHP Code Sniffer to make sure your code doesn't smell"> | ||
<delete file="${phpcs.report.xml}" /> | ||
<exec executable="${project.bindir}/phpcs" passthru="true"> | ||
<arg value="-p" /> <!-- Show progress of run --> | ||
<arg value="--report-xml=${phpcs.report.xml}" /> | ||
<arg line="--standard=${phpcs.standard}" /> | ||
<arg line="--ignore=${phpcs.ignore}" /> | ||
<arg path="${phpcs.source}" /> | ||
</exec> | ||
</target> | ||
</project> |
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,145 @@ | ||
# The MIT License (MIT) | ||
# | ||
# Copyright (c) 2011-2014 BitPay | ||
# | ||
# Permission is hereby granted, free of charge, to any person obtaining a copy | ||
# of this software and associated documentation files (the "Software"), to deal | ||
# in the Software without restriction, including without limitation the rights | ||
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
# copies of the Software, and to permit persons to whom the Software is | ||
# furnished to do so, subject to the following conditions: | ||
# | ||
# The above copyright notice and this permission notice shall be included in | ||
# all copies or substantial portions of the Software. | ||
# | ||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
# THE SOFTWARE. | ||
|
||
#### | ||
# | ||
# This properties file is used to configure the entire build. The purpose of | ||
# this file is so that it is easy to drop it into a project and change a few | ||
# of these settings and have a build run successfully. | ||
# | ||
# NOTE: You may still need to take a look at and edit `phpunit.xml.dist`. | ||
# | ||
|
||
#### | ||
# | ||
# Directory Configuration | ||
# | ||
|
||
# The main location of all the projects source code, this should be the only | ||
# property that you need to change. Code can live in the root directory or it | ||
# can live inside of it's own directory. | ||
project.source=${project.basedir} | ||
#project.source=${project.basedir}/src | ||
|
||
# --- You shouldn't need to edit any of the below value --- | ||
|
||
# Location of all executables, this is the location on the `bin-dir` that you | ||
# have configured in `composer.json`. If you have not configured this in | ||
# 1composer.json` the default is to put it in the `vendor` directory. | ||
project.bindir=${project.basedir}/bin | ||
#project.bindir=${project.basedir}/vendor/bin | ||
|
||
# Where to put the build artifacts, cache, logs, docs, etc. | ||
project.builddir=${project.basedir}/build | ||
|
||
# Location of vendor directory created by composer. | ||
project.vendordir=${project.basedir}/vendor | ||
|
||
# build artifacts for code analysis | ||
project.logsdir=${project.builddir}/logs | ||
|
||
# Build artifacts that can be reused or updated, they do not need to be deleted | ||
# every build. These would include charts and images. | ||
project.cachedir=${project.builddir}/cache | ||
|
||
# Location of generated documentation such as API and code coverage | ||
project.docsdir=${project.builddir}/docs | ||
#### directory #### | ||
|
||
#### | ||
# | ||
# phpunit configuration | ||
# | ||
|
||
# Directory that contains phpunit.xml or the phpunit.xml file itself | ||
phpunit.configuration=${project.builddir}/phpunit.xml.dist | ||
#### phpunit #### | ||
|
||
#### | ||
# | ||
# phpmd configuration | ||
# | ||
|
||
# php source code filename or directory. Can be a comma-separated string | ||
phpmd.source=${project.source} | ||
|
||
# report format, text, xml, or html | ||
phpmd.report.format=xml | ||
|
||
# ruleset filename or a comma-separated string of rulesetfilenames | ||
phpmd.ruleset=${project.builddir}/rulesets/phpmd.xml | ||
|
||
# send report output to this file | ||
phpmd.report.file=${project.logsdir}/phpmd.xml | ||
|
||
# comma-separated string of patterns that are used to ignore directories | ||
phpmd.exclude=${project.bindir},${project.builddir},${project.vendordir},${project.basedir}/tests | ||
#### phpmd #### | ||
|
||
#### | ||
# | ||
# phploc Configuration | ||
# | ||
|
||
# Source directory of project | ||
phploc.source=${project.source}/ | ||
|
||
# Where to put the csv log | ||
phploc.log.csv=${project.logsdir}/phploc.csv | ||
|
||
# Location of xml log | ||
phploc.log.xml=${project.logsdir}/phploc.xml | ||
|
||
# Small hack to exclude multiple directories | ||
phploc.exclude=vendor --exclude=build --exclude=bin --exclude=tests | ||
#### phploc #### | ||
|
||
#### | ||
# | ||
# pdepend configuration | ||
# | ||
pdepend.source=${project.source} | ||
pdepend.jdepend.chart=${project.cachedir}/jdepend_chart.svg | ||
pdepend.jdepend.xml=${project.logsdir}/jdepend.xml | ||
pdepend.overview.pyramid=${project.cachedir}/pyramid.svg | ||
pdepend.summary.xml=${project.logsdir}/jdepend_summary.xml | ||
pdepend.ignore=bin,build,vendor,tests | ||
#### pdepend #### | ||
|
||
#### | ||
# | ||
# phpcs configuration | ||
# | ||
phpcs.source=${project.source} | ||
phpcs.report.xml=${project.logsdir}/phpcs.xml | ||
phpcs.standard=PSR1 --standard=PSR2 | ||
phpcs.ignore=vendor --ignore=bin --ignore=build --ignore=tests | ||
#### phpcs #### | ||
|
||
#### | ||
# | ||
# phpdoc configuration | ||
# | ||
phpdoc.directory=${project.source}/ | ||
phpdoc.target=${project.docsdir}/api | ||
phpdoc.ignore=vendor/,bin/,tests/ | ||
#### phpdoc #### |
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,50 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
/** | ||
* The MIT License (MIT) | ||
* | ||
* Copyright (c) 2011-2014 BitPay | ||
* | ||
* Permission is hereby granted, free of charge, to any person obtaining a copy | ||
* of this software and associated documentation files (the "Software"), to deal | ||
* in the Software without restriction, including without limitation the rights | ||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
* copies of the Software, and to permit persons to whom the Software is | ||
* furnished to do so, subject to the following conditions: | ||
* | ||
* The above copyright notice and this permission notice shall be included in | ||
* all copies or substantial portions of the Software. | ||
* | ||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
* THE SOFTWARE. | ||
*/ | ||
--> | ||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/4.1/phpunit.xsd" | ||
backupGlobals = "false" | ||
colors = "true" | ||
verbose = "true" | ||
> | ||
|
||
<testsuites> | ||
<testsuite name="BitPay Project Test Suite"> | ||
<directory>../tests/*Test.php</directory> | ||
</testsuite> | ||
</testsuites> | ||
|
||
<filter> | ||
<blacklist> | ||
<directory>../build</directory> | ||
</blacklist> | ||
</filter> | ||
|
||
<logging> | ||
<log type="coverage-html" target="../build/docs/code-coverage" /> | ||
<log type="coverage-clover" target="../build/logs/clover.xml" /> | ||
</logging> | ||
</phpunit> |
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,43 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
/** | ||
* The MIT License (MIT) | ||
* | ||
* Copyright (c) 2011-2014 BitPay | ||
* | ||
* Permission is hereby granted, free of charge, to any person obtaining a copy | ||
* of this software and associated documentation files (the "Software"), to deal | ||
* in the Software without restriction, including without limitation the rights | ||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
* copies of the Software, and to permit persons to whom the Software is | ||
* furnished to do so, subject to the following conditions: | ||
* | ||
* The above copyright notice and this permission notice shall be included in | ||
* all copies or substantial portions of the Software. | ||
* | ||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
* THE SOFTWARE. | ||
*/ | ||
--> | ||
<ruleset name="PHPMD Ruleset" | ||
xmlns="http://pmd.sf.net/ruleset/1.0.0" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://pmd.sf.net/ruleset/1.0.0 http://pmd.sf.net/ruleset_xml_schema.xsd" | ||
xsi:noNamespaceSchemaLocation="http://pmd.sf.net/ruleset_xml_schema.xsd"> | ||
<description> | ||
Custom phpmd ruleset to be used with BitPay projects. | ||
</description> | ||
|
||
<!-- Import --> | ||
<!--<rule ref="rulesets/cleancode.xml" />--> | ||
<rule ref="rulesets/codesize.xml" /> | ||
<!--<rule ref="rulesets/controversial.xml" />--> | ||
<rule ref="rulesets/design.xml" /> | ||
<rule ref="rulesets/naming.xml" /> | ||
<rule ref="rulesets/unusedcode.xml" /> | ||
</ruleset> |
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,145 @@ | ||
# The MIT License (MIT) | ||
# | ||
# Copyright (c) 2011-2014 BitPay | ||
# | ||
# Permission is hereby granted, free of charge, to any person obtaining a copy | ||
# of this software and associated documentation files (the "Software"), to deal | ||
# in the Software without restriction, including without limitation the rights | ||
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
# copies of the Software, and to permit persons to whom the Software is | ||
# furnished to do so, subject to the following conditions: | ||
# | ||
# The above copyright notice and this permission notice shall be included in | ||
# all copies or substantial portions of the Software. | ||
# | ||
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
# THE SOFTWARE. | ||
|
||
#### | ||
# | ||
# This properties file is used to configure the entire build. The purpose of | ||
# this file is so that it is easy to drop it into a project and change a few | ||
# of these settings and have a build run successfully. | ||
# | ||
# NOTE: You may still need to take a look at and edit `phpunit.xml.dist`. | ||
# | ||
|
||
#### | ||
# | ||
# Directory Configuration | ||
# | ||
|
||
# The main location of all the projects source code, this should be the only | ||
# property that you need to change. Code can live in the root directory or it | ||
# can live inside of it's own directory. | ||
project.source=${project.basedir} | ||
#project.source=${project.basedir}/src | ||
|
||
# --- You shouldn't need to edit any of the below value --- | ||
|
||
# Location of all executables, this is the location on the `bin-dir` that you | ||
# have configured in `composer.json`. If you have not configured this in | ||
# 1composer.json` the default is to put it in the `vendor` directory. | ||
project.bindir=${project.basedir}/bin | ||
#project.bindir=${project.basedir}/vendor/bin | ||
|
||
# Where to put the build artifacts, cache, logs, docs, etc. | ||
project.builddir=${project.basedir}/build | ||
|
||
# Location of vendor directory created by composer. | ||
project.vendordir=${project.basedir}/vendor | ||
|
||
# build artifacts for code analysis | ||
project.logsdir=${project.builddir}/logs | ||
|
||
# Build artifacts that can be reused or updated, they do not need to be deleted | ||
# every build. These would include charts and images. | ||
project.cachedir=${project.builddir}/cache | ||
|
||
# Location of generated documentation such as API and code coverage | ||
project.docsdir=${project.builddir}/docs | ||
#### directory #### | ||
|
||
#### | ||
# | ||
# phpunit configuration | ||
# | ||
|
||
# Directory that contains phpunit.xml or the phpunit.xml file itself | ||
phpunit.configuration=${project.builddir}/phpunit.xml.dist | ||
#### phpunit #### | ||
|
||
#### | ||
# | ||
# phpmd configuration | ||
# | ||
|
||
# php source code filename or directory. Can be a comma-separated string | ||
phpmd.source=${project.source} | ||
|
||
# report format, text, xml, or html | ||
phpmd.report.format=xml | ||
|
||
# ruleset filename or a comma-separated string of rulesetfilenames | ||
phpmd.ruleset=${project.builddir}/rulesets/phpmd.xml | ||
|
||
# send report output to this file | ||
phpmd.report.file=${project.logsdir}/phpmd.xml | ||
|
||
# comma-separated string of patterns that are used to ignore directories | ||
phpmd.exclude=${project.bindir},${project.builddir},${project.vendordir},${project.basedir}/tests | ||
#### phpmd #### | ||
|
||
#### | ||
# | ||
# phploc Configuration | ||
# | ||
|
||
# Source directory of project | ||
phploc.source=${project.source}/ | ||
|
||
# Where to put the csv log | ||
phploc.log.csv=${project.logsdir}/phploc.csv | ||
|
||
# Location of xml log | ||
phploc.log.xml=${project.logsdir}/phploc.xml | ||
|
||
# Small hack to exclude multiple directories | ||
phploc.exclude=vendor --exclude=build --exclude=bin --exclude=tests | ||
#### phploc #### | ||
|
||
#### | ||
# | ||
# pdepend configuration | ||
# | ||
pdepend.source=${project.source} | ||
pdepend.jdepend.chart=${project.cachedir}/jdepend_chart.svg | ||
pdepend.jdepend.xml=${project.logsdir}/jdepend.xml | ||
pdepend.overview.pyramid=${project.cachedir}/pyramid.svg | ||
pdepend.summary.xml=${project.logsdir}/jdepend_summary.xml | ||
pdepend.ignore=bin,build,vendor,tests | ||
#### pdepend #### | ||
|
||
#### | ||
# | ||
# phpcs configuration | ||
# | ||
phpcs.source=${project.source} | ||
phpcs.report.xml=${project.logsdir}/phpcs.xml | ||
phpcs.standard=PSR1 --standard=PSR2 | ||
phpcs.ignore=vendor --ignore=bin --ignore=build --ignore=tests | ||
#### phpcs #### | ||
|
||
#### | ||
# | ||
# phpdoc configuration | ||
# | ||
phpdoc.directory=${project.source}/ | ||
phpdoc.target=${project.docsdir}/api | ||
phpdoc.ignore=vendor/,bin/,tests/ | ||
#### phpdoc #### |
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,28 @@ | ||
{ | ||
"name": "bitpay/zencart-plugin", | ||
"description": "", | ||
"type": "zencart-plugin", | ||
"keywords": [], | ||
"homepage": "https://github.com/bitpay/zencart-plugin", | ||
"license": "MIT", | ||
"support": { | ||
"email": "support@bitpay.com", | ||
"issues": "https://github.com/bitpay/zencart-plugin/issues", | ||
"source": "https://github.com/bitpay/zencart-plugin" | ||
}, | ||
"minimum-stability": "stable", | ||
"require": {}, | ||
"require-dev": { | ||
"phpmd/phpmd": "*", | ||
"phpdocumentor/phpdocumentor": "*", | ||
"phing/phing": "*", | ||
"pdepend/pdepend" : "1.1.0", | ||
"squizlabs/php_codesniffer": "*", | ||
"phpunit/phpunit": "*", | ||
"phploc/phploc": "*", | ||
"phpunit/phpunit-skeleton-generator": "*" | ||
}, | ||
"config": { | ||
"bin-dir": "bin" | ||
} | ||
} |
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
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