summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2023-04-10 14:14:18 +0000
committerCoprDistGit <infra@openeuler.org>2023-04-10 14:14:18 +0000
commite34bb1441c3c628fbdf941c01f43c5c512bc950d (patch)
tree73da0d866d4e7573887d976fa970e875368b8a41
parent99b924ddea24bacb43a55b80030c8374aee132ff (diff)
automatic import of python-azure-functions-devops-build
-rw-r--r--.gitignore1
-rw-r--r--python-azure-functions-devops-build.spec282
-rw-r--r--sources1
3 files changed, 284 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..a1b96f8 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/azure-functions-devops-build-0.0.22.tar.gz
diff --git a/python-azure-functions-devops-build.spec b/python-azure-functions-devops-build.spec
new file mode 100644
index 0000000..279284f
--- /dev/null
+++ b/python-azure-functions-devops-build.spec
@@ -0,0 +1,282 @@
+%global _empty_manifest_terminate_build 0
+Name: python-azure-functions-devops-build
+Version: 0.0.22
+Release: 1
+Summary: Python package for integrating Azure Functions with Azure DevOps. Specifically made for the Azure CLI
+License: MIT
+URL: https://github.com/Azure/azure-functions-devops-build
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/d5/96/59ca26c8d9985df8a092cf5974e54b6c3e11208833ea1c0163d7fb763c94/azure-functions-devops-build-0.0.22.tar.gz
+BuildArch: noarch
+
+Requires: python3-msrest
+Requires: python3-vsts
+Requires: python3-jinja2
+
+%description
+# Azure Devops Build Manager For Azure Functions
+
+> :construction: The project is currently **work in progress**. Please **do not use in production** as we expect developments over time. :construction:
+
+This project provides the class AzureDevopsBuildManager and supporting classes. This manager class allows
+the caller to manage Azure Devops pipelines that are maintained within an Azure Devops account. This project was created to be able to support command line tooling for the AZ Cli.
+
+## Install
+To install the package from pip:
+```
+pip install azure-functions-devops-build
+```
+## Get started
+To use the API, you need to first establish a connection to azure by loging into your azure account using `az login`. You can then follow the example as below. Firstly we get the token from login and use this to authenticate the different python function calls.
+
+```python
+from azure.cli.core import get_default_cli
+from azure.cli.core._profile import Profile
+from azure_functions_devops_build.organization.organization_manager import OrganizationManager
+import pprint
+
+# Get your token from the az login cache
+cli_ctx = get_default_cli()
+profile = Profile(cli_ctx=cli_ctx)
+creds, _, _ = profile.get_login_credentials(subscription_id=None)
+
+# Create an organization manager using your credentials
+organization_manager = OrganizationManager(creds=creds)
+
+# Get the list of organizations for your user
+organizations = organization_manager.list_organizations()
+
+# Show details about each organization in the console
+for organization in organizations.value:
+ pprint.pprint(organization.__dict__)
+```
+
+## API documentation
+
+This Python library extensively uses the Azure DevOps REST APIs and Azure Devops Python API. See the [Azure DevOps REST API reference](https://docs.microsoft.com/en-us/rest/api/vsts/?view=vsts-rest-5.0) for details on calling different APIs and [Azure DevOps Python SDK](https://github.com/Microsoft/azure-devops-python-api) for details on the azure-devops-python-api.
+
+## Samples
+
+See samples by looking at tests or viewing the [az-cli functionapp devops-build module](https://github.com/Azure/azure-cli/tree/dev/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice).
+
+## Testing
+
+Several things need to be setup before you can run the tests:
+1. Signed into the az cli. You can do this by using `az login`.
+2. Since this directly deploys to azure functions, [create an azure functions functionapp using the azure portal](https://docs.microsoft.com/en-us/azure/azure-functions/functions-create-first-azure-function). You need to make a functionapp for these tests to successfully run and make sure you record the details of the subscription name, project name, application type and storage name.
+3. Follow the tests/_config_example.py file, create a tests/_config.py with your own testing environment.
+4. Run the full test suite using `python -m tests.suite`
+5. To run specific manager tests run `python -m tests.{NAME_OF_MANAGER}` eg. `python -m tests.test_builder_manager`
+
+## Contributing
+
+This project welcomes contributions and suggestions. Most contributions require you to agree to a
+Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us
+the rights to use your contribution. For details, visit https://cla.microsoft.com.
+
+When you submit a pull request, a CLA-bot will automatically determine whether you need to provide
+a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions
+provided by the bot. You will only need to do this once across all repos using our CLA.
+
+This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
+For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or
+contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
+
+
+
+
+%package -n python3-azure-functions-devops-build
+Summary: Python package for integrating Azure Functions with Azure DevOps. Specifically made for the Azure CLI
+Provides: python-azure-functions-devops-build
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-azure-functions-devops-build
+# Azure Devops Build Manager For Azure Functions
+
+> :construction: The project is currently **work in progress**. Please **do not use in production** as we expect developments over time. :construction:
+
+This project provides the class AzureDevopsBuildManager and supporting classes. This manager class allows
+the caller to manage Azure Devops pipelines that are maintained within an Azure Devops account. This project was created to be able to support command line tooling for the AZ Cli.
+
+## Install
+To install the package from pip:
+```
+pip install azure-functions-devops-build
+```
+## Get started
+To use the API, you need to first establish a connection to azure by loging into your azure account using `az login`. You can then follow the example as below. Firstly we get the token from login and use this to authenticate the different python function calls.
+
+```python
+from azure.cli.core import get_default_cli
+from azure.cli.core._profile import Profile
+from azure_functions_devops_build.organization.organization_manager import OrganizationManager
+import pprint
+
+# Get your token from the az login cache
+cli_ctx = get_default_cli()
+profile = Profile(cli_ctx=cli_ctx)
+creds, _, _ = profile.get_login_credentials(subscription_id=None)
+
+# Create an organization manager using your credentials
+organization_manager = OrganizationManager(creds=creds)
+
+# Get the list of organizations for your user
+organizations = organization_manager.list_organizations()
+
+# Show details about each organization in the console
+for organization in organizations.value:
+ pprint.pprint(organization.__dict__)
+```
+
+## API documentation
+
+This Python library extensively uses the Azure DevOps REST APIs and Azure Devops Python API. See the [Azure DevOps REST API reference](https://docs.microsoft.com/en-us/rest/api/vsts/?view=vsts-rest-5.0) for details on calling different APIs and [Azure DevOps Python SDK](https://github.com/Microsoft/azure-devops-python-api) for details on the azure-devops-python-api.
+
+## Samples
+
+See samples by looking at tests or viewing the [az-cli functionapp devops-build module](https://github.com/Azure/azure-cli/tree/dev/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice).
+
+## Testing
+
+Several things need to be setup before you can run the tests:
+1. Signed into the az cli. You can do this by using `az login`.
+2. Since this directly deploys to azure functions, [create an azure functions functionapp using the azure portal](https://docs.microsoft.com/en-us/azure/azure-functions/functions-create-first-azure-function). You need to make a functionapp for these tests to successfully run and make sure you record the details of the subscription name, project name, application type and storage name.
+3. Follow the tests/_config_example.py file, create a tests/_config.py with your own testing environment.
+4. Run the full test suite using `python -m tests.suite`
+5. To run specific manager tests run `python -m tests.{NAME_OF_MANAGER}` eg. `python -m tests.test_builder_manager`
+
+## Contributing
+
+This project welcomes contributions and suggestions. Most contributions require you to agree to a
+Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us
+the rights to use your contribution. For details, visit https://cla.microsoft.com.
+
+When you submit a pull request, a CLA-bot will automatically determine whether you need to provide
+a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions
+provided by the bot. You will only need to do this once across all repos using our CLA.
+
+This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
+For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or
+contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
+
+
+
+
+%package help
+Summary: Development documents and examples for azure-functions-devops-build
+Provides: python3-azure-functions-devops-build-doc
+%description help
+# Azure Devops Build Manager For Azure Functions
+
+> :construction: The project is currently **work in progress**. Please **do not use in production** as we expect developments over time. :construction:
+
+This project provides the class AzureDevopsBuildManager and supporting classes. This manager class allows
+the caller to manage Azure Devops pipelines that are maintained within an Azure Devops account. This project was created to be able to support command line tooling for the AZ Cli.
+
+## Install
+To install the package from pip:
+```
+pip install azure-functions-devops-build
+```
+## Get started
+To use the API, you need to first establish a connection to azure by loging into your azure account using `az login`. You can then follow the example as below. Firstly we get the token from login and use this to authenticate the different python function calls.
+
+```python
+from azure.cli.core import get_default_cli
+from azure.cli.core._profile import Profile
+from azure_functions_devops_build.organization.organization_manager import OrganizationManager
+import pprint
+
+# Get your token from the az login cache
+cli_ctx = get_default_cli()
+profile = Profile(cli_ctx=cli_ctx)
+creds, _, _ = profile.get_login_credentials(subscription_id=None)
+
+# Create an organization manager using your credentials
+organization_manager = OrganizationManager(creds=creds)
+
+# Get the list of organizations for your user
+organizations = organization_manager.list_organizations()
+
+# Show details about each organization in the console
+for organization in organizations.value:
+ pprint.pprint(organization.__dict__)
+```
+
+## API documentation
+
+This Python library extensively uses the Azure DevOps REST APIs and Azure Devops Python API. See the [Azure DevOps REST API reference](https://docs.microsoft.com/en-us/rest/api/vsts/?view=vsts-rest-5.0) for details on calling different APIs and [Azure DevOps Python SDK](https://github.com/Microsoft/azure-devops-python-api) for details on the azure-devops-python-api.
+
+## Samples
+
+See samples by looking at tests or viewing the [az-cli functionapp devops-build module](https://github.com/Azure/azure-cli/tree/dev/src/command_modules/azure-cli-appservice/azure/cli/command_modules/appservice).
+
+## Testing
+
+Several things need to be setup before you can run the tests:
+1. Signed into the az cli. You can do this by using `az login`.
+2. Since this directly deploys to azure functions, [create an azure functions functionapp using the azure portal](https://docs.microsoft.com/en-us/azure/azure-functions/functions-create-first-azure-function). You need to make a functionapp for these tests to successfully run and make sure you record the details of the subscription name, project name, application type and storage name.
+3. Follow the tests/_config_example.py file, create a tests/_config.py with your own testing environment.
+4. Run the full test suite using `python -m tests.suite`
+5. To run specific manager tests run `python -m tests.{NAME_OF_MANAGER}` eg. `python -m tests.test_builder_manager`
+
+## Contributing
+
+This project welcomes contributions and suggestions. Most contributions require you to agree to a
+Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us
+the rights to use your contribution. For details, visit https://cla.microsoft.com.
+
+When you submit a pull request, a CLA-bot will automatically determine whether you need to provide
+a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions
+provided by the bot. You will only need to do this once across all repos using our CLA.
+
+This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
+For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or
+contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
+
+
+
+
+%prep
+%autosetup -n azure-functions-devops-build-0.0.22
+
+%build
+%py3_build
+
+%install
+%py3_install
+install -d -m755 %{buildroot}/%{_pkgdocdir}
+if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
+if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
+if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
+if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
+pushd %{buildroot}
+if [ -d usr/lib ]; then
+ find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/lib64 ]; then
+ find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/bin ]; then
+ find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+if [ -d usr/sbin ]; then
+ find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
+fi
+touch doclist.lst
+if [ -d usr/share/man ]; then
+ find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
+fi
+popd
+mv %{buildroot}/filelist.lst .
+mv %{buildroot}/doclist.lst .
+
+%files -n python3-azure-functions-devops-build -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Mon Apr 10 2023 Python_Bot <Python_Bot@openeuler.org> - 0.0.22-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..e862324
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+a76c85de8cd66b35d25d382de515feaa azure-functions-devops-build-0.0.22.tar.gz