summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore1
-rw-r--r--python-appcenter.spec227
-rw-r--r--sources1
3 files changed, 229 insertions, 0 deletions
diff --git a/.gitignore b/.gitignore
index e69de29..fce3573 100644
--- a/.gitignore
+++ b/.gitignore
@@ -0,0 +1 @@
+/appcenter-3.2.1.tar.gz
diff --git a/python-appcenter.spec b/python-appcenter.spec
new file mode 100644
index 0000000..a5eeda4
--- /dev/null
+++ b/python-appcenter.spec
@@ -0,0 +1,227 @@
+%global _empty_manifest_terminate_build 0
+Name: python-appcenter
+Version: 3.2.1
+Release: 1
+Summary: A Python wrapper around the App Center REST API.
+License: MIT
+URL: https://github.com/Microsoft/appcenter-rest-python
+Source0: https://mirrors.nju.edu.cn/pypi/web/packages/28/ec/9858aea5714539eb87cd2209c162dcc488d188185abe8bb7584b3840c8c6/appcenter-3.2.1.tar.gz
+BuildArch: noarch
+
+Requires: python3-azure-storage-blob
+Requires: python3-deserialize
+Requires: python3-requests
+Requires: python3-tenacity
+Requires: python3-types-requests
+
+%description
+This is a minimal Python wrapper around the App Center REST APIs to get you up and running. If you are looking for something more substantial, please refer to the REST API documentation: https://openapi.appcenter.ms/
+
+You can install with `pip install appcenter`
+
+## Usage
+
+```python
+# 1. Import the library
+import appcenter
+
+# 2. Create a new client
+client = appcenter.AppCenterClient(access_token="abc123def456")
+
+# 3. Check some error groups
+start = datetime.datetime.now() - datetime.timedelta(days=10)
+for group in client.crashes.get_error_groups(owner_name="owner", app_name="myapp", start_time=start):
+ print(group.errorGroupId)
+
+# 4. Get recent versions
+for version in client.versions.all(owner_name="owner", app_name="myapp"):
+ print(version)
+
+# 5. Create a new release
+client.versions.upload_and_release(
+ owner_name="owner",
+ app_name="myapp",
+ version="0.1",
+ build_number="123",
+ binary_path="/path/to/some.ipa",
+ group_id="12345678-abcd-9012-efgh-345678901234",
+ release_notes="These are some release notes",
+ branch_name="test_branch",
+ commit_hash="1234567890123456789012345678901234567890",
+ commit_message="This is a commit message"
+)
+```
+
+## 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.opensource.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., status check, 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-appcenter
+Summary: A Python wrapper around the App Center REST API.
+Provides: python-appcenter
+BuildRequires: python3-devel
+BuildRequires: python3-setuptools
+BuildRequires: python3-pip
+%description -n python3-appcenter
+This is a minimal Python wrapper around the App Center REST APIs to get you up and running. If you are looking for something more substantial, please refer to the REST API documentation: https://openapi.appcenter.ms/
+
+You can install with `pip install appcenter`
+
+## Usage
+
+```python
+# 1. Import the library
+import appcenter
+
+# 2. Create a new client
+client = appcenter.AppCenterClient(access_token="abc123def456")
+
+# 3. Check some error groups
+start = datetime.datetime.now() - datetime.timedelta(days=10)
+for group in client.crashes.get_error_groups(owner_name="owner", app_name="myapp", start_time=start):
+ print(group.errorGroupId)
+
+# 4. Get recent versions
+for version in client.versions.all(owner_name="owner", app_name="myapp"):
+ print(version)
+
+# 5. Create a new release
+client.versions.upload_and_release(
+ owner_name="owner",
+ app_name="myapp",
+ version="0.1",
+ build_number="123",
+ binary_path="/path/to/some.ipa",
+ group_id="12345678-abcd-9012-efgh-345678901234",
+ release_notes="These are some release notes",
+ branch_name="test_branch",
+ commit_hash="1234567890123456789012345678901234567890",
+ commit_message="This is a commit message"
+)
+```
+
+## 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.opensource.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., status check, 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 appcenter
+Provides: python3-appcenter-doc
+%description help
+This is a minimal Python wrapper around the App Center REST APIs to get you up and running. If you are looking for something more substantial, please refer to the REST API documentation: https://openapi.appcenter.ms/
+
+You can install with `pip install appcenter`
+
+## Usage
+
+```python
+# 1. Import the library
+import appcenter
+
+# 2. Create a new client
+client = appcenter.AppCenterClient(access_token="abc123def456")
+
+# 3. Check some error groups
+start = datetime.datetime.now() - datetime.timedelta(days=10)
+for group in client.crashes.get_error_groups(owner_name="owner", app_name="myapp", start_time=start):
+ print(group.errorGroupId)
+
+# 4. Get recent versions
+for version in client.versions.all(owner_name="owner", app_name="myapp"):
+ print(version)
+
+# 5. Create a new release
+client.versions.upload_and_release(
+ owner_name="owner",
+ app_name="myapp",
+ version="0.1",
+ build_number="123",
+ binary_path="/path/to/some.ipa",
+ group_id="12345678-abcd-9012-efgh-345678901234",
+ release_notes="These are some release notes",
+ branch_name="test_branch",
+ commit_hash="1234567890123456789012345678901234567890",
+ commit_message="This is a commit message"
+)
+```
+
+## 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.opensource.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., status check, 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 appcenter-3.2.1
+
+%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-appcenter -f filelist.lst
+%dir %{python3_sitelib}/*
+
+%files help -f doclist.lst
+%{_docdir}/*
+
+%changelog
+* Mon May 15 2023 Python_Bot <Python_Bot@openeuler.org> - 3.2.1-1
+- Package Spec generated
diff --git a/sources b/sources
new file mode 100644
index 0000000..9932073
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+844fd1e04fe75e93bf0fb8a07bac655b appcenter-3.2.1.tar.gz