Compose is a part of the Docker project, and follows the same rules and principles. Take a read of Docker's contributing guidelines to get an overview.
Pull requests will need:
If you're looking contribute to Compose but you're new to the project or maybe even to Python, here are the steps that should get you started.
git clone git@github.com:yourusername/compose.git
.cd compose
.python setup.py develop
. This
will install the dependencies and set up a symlink from your docker-compose
executable to the checkout of the repository. When you now run
docker-compose
from anywhere on your machine, it will run your development
version of Compose.This step is optional, but recommended. Pre-commit hooks will run style checks and in some cases fix style issues for you, when you commit code.
Install the git pre-commit hooks using tox by
running tox -e pre-commit
or by following the
pre-commit install guide.
To run the style checks at any time run tox -e pre-commit
.
See Docker's basic contribution workflow for a guide on how to submit a pull request for code.
Issues and pull requests to update the documentation should be submitted to the docs repo. You can learn more about contributing to the documentation here.
Use the test script to run linting checks and then the full test suite against different Python interpreters:
$ script/test/default
Tests are run against a Docker daemon inside a container, so that we can test
against multiple Docker versions. By default they'll run against only the latest
Docker version - set the DOCKER_VERSIONS
environment variable to "all" to run
against all supported versions:
$ DOCKER_VERSIONS=all script/test/default
Arguments to script/test/default
are passed through to the tox
executable, so
you can specify a test directory, file, module, class or method:
$ script/test/default tests/unit
$ script/test/default tests/unit/cli_test.py
$ script/test/default tests/unit/config/config_test.py::ConfigTest
$ script/test/default tests/unit/config/config_test.py::ConfigTest::test_load
Issues marked with the exp/beginner
label are a good starting point for people looking to make their first contribution to the project.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。