Skip to content

Commit 709568f

Browse files
committed
Regenerate repository using repo-config
Signed-off-by: Mathias L. Baumann <[email protected]>
1 parent 3d42558 commit 709568f

39 files changed

+1886
-1
lines changed

.cookiecutter-replay.json

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"cookiecutter": {
3+
"Introduction": "",
4+
"type": "lib",
5+
"name": "dispatch-client",
6+
"description": "Dispatch API client for Python",
7+
"title": "Frequenz Dispatch Client Library",
8+
"keywords": "dispatch, client, api, python",
9+
"github_org": "frequenz-floss",
10+
"license": "MIT",
11+
"author_name": "Frequenz Energy-as-a-Service GmbH",
12+
"author_email": "[email protected]",
13+
"python_package": "frequenz.client.dispatch",
14+
"pypi_package_name": "frequenz-dispatch-client",
15+
"github_repo_name": "frequenz-client-dispatch-python",
16+
"default_codeowners": "@frequenz-floss/api-dispatch-team",
17+
"_template": "gh:frequenz-floss/frequenz-repo-config-python",
18+
"_repo_dir": "/home/marenz/.cookiecutters/frequenz-repo-config-python/cookiecutter"
19+
},
20+
"_cookiecutter": {
21+
"Introduction": "]\n\n Welcome to repo-config Cookiecutter template!\n\n This template will help you to create a new repository for your project. You will be asked to provide some information about your project.\n\n Here is an explanation of what each variable is for and will be used for:\n\n * `type`: The type of repository. It must be chosen from the list.\n\n* `name`: The name of the project. This will be used to build defaults for\n other inputs, such as `title`, `python_package`, etc. It should be one word,\n using only alphanumeric characters (and starting with a letter). It can\n include also `_` and `-` which will be handled differently when building\n other variables from it (replaced by spaces in titles for example).\n\n* `description`: A short description of the project. It will be used as the\n description in the `README.md`, `pyproject.toml`, `mkdocs.yml`, etc.\n\n* `title`: A human-readable name or title for the project. It will be used in\n the `README.md`, `CONTRIBUTING.md`, and other files to refer to the project,\n as well as the site title in `mkdocs.yml`.\n\n* `keywords`: A comma-separated list of keywords that will be used in the\n `pyproject.toml` file. If left untouched, it will use only some predefined\n keywords. If anything else is entered, it will be **added** to the default\n keywords.\n\n* `github_org`: The GitHub handle of the organization where the project will\n reside. This will be used to generate links to the project on GitHub.\n\n* `license`: Currently, only two options are provided: `MIT`, which should be\n used for open-source projects, and `Proprietary`, which should be used for\n closed-source projects. This will be added to file headers and used as the\n license in `pyproject.toml`.\n\n* `author_name`, `author_email`: The name and email address of the author of\n the project. They will be used in the copyright notice in file headers and\n as the author in `pyproject.toml`.\n\n* `python_package`: The Python package in which this project will reside. All\n files provided by this project should be located in this package. This needs\n to be a list of valid Python identifiers separated by dots. The source file\n structure will be derived from this. For example, `frequenz.actor.example`\n will generate files in `src/frequenz/actor/example`.\n\n* `pypi_package_name`: The name of the PyPI/wheel/distribution package. This\n should be consistent with the `python_package`, usually replacing `.` with\n `-`. For example, `frequenz-actor-example`.\n\n* `github_repo_name`: The handle of the GitHub repository where the project\n will reside. This will be used to generate links to the project on GitHub and\n as the top-level directory name.\n\n* `default_codeowners`: A space-separated list of GitHub teams (`@org/team`) or\n users (`@user`) that will be the default code owners for this project. This\n will be used to build the `CODEOWNERS` file. Please refer to the [code owners\n documentation] for more details on the valid syntax.\n\n[code owners documentation]: https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners\n\n\n [Please press any key to continue",
22+
"type": "lib",
23+
"name": "dispatch-client",
24+
"description": "Dispatch API client for Python",
25+
"title": "Frequenz Dispatch Client Library",
26+
"keywords": "dispatch, client, api, python",
27+
"github_org": "frequenz-floss",
28+
"license": "MIT",
29+
"author_name": "Frequenz Energy-as-a-Service GmbH",
30+
"author_email": "[email protected]",
31+
"python_package": "frequenz.client.dispatch",
32+
"pypi_package_name": "frequenz-dispatch-client",
33+
"github_repo_name": "frequenz-client-dispatch-python",
34+
"default_codeowners": "@frequenz-floss/api-dispatch-team"
35+
}
36+
}

.editorconfig

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# EditorConfig is awesome: https://EditorConfig.org
2+
3+
# top-most EditorConfig file
4+
root = true
5+
6+
# Unix-style newlines with a newline ending every file
7+
[*]
8+
end_of_line = lf
9+
insert_final_newline = true
10+
11+
# Set default charset, indent style and trimming of whitespace
12+
[{.editorconfig,CODEOWNERS,LICENSE,*.{in,json,md,proto,py,pyi,toml,yaml,yml}}]
13+
charset = utf-8
14+
indent_style = space
15+
trim_trailing_whitespace = true
16+
17+
# 4 space indentation
18+
[*.{py,pyi}]
19+
indent_size = 4
20+
21+
# 2 space indentation
22+
[{.editorconfig,CODEOWNERS,LICENSE,*.{in,json,proto,toml,yaml,yml}}]
23+
indent_size = 2
24+
25+
# No indentation size specified for *.md because different blocks have
26+
# different indentation rules

.github/ISSUE_TEMPLATE/bug.yml

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
# GitHub issue form. For more information see:
2+
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms
3+
4+
name: Report something is not working properly 🐛
5+
description:
6+
Use this if there is something that is not working properly. If you are not
7+
sure or you need help making something work, please ask a question instead.
8+
labels:
9+
- "priority:❓"
10+
- "type:bug"
11+
body:
12+
- type: markdown
13+
attributes:
14+
value:
15+
Thanks for taking the time to fill out this bug report!
16+
- type: textarea
17+
id: what-happened
18+
attributes:
19+
label: What happened?
20+
description: Please tell us what happened that shouldn't have.
21+
placeholder: What happened that shouldn't have.
22+
validations:
23+
required: true
24+
- type: textarea
25+
id: what-expected
26+
attributes:
27+
label: What did you expect instead?
28+
description: Please tell us what did you expect to happen.
29+
placeholder: What did you expect to happen.
30+
validations:
31+
required: true
32+
- type: input
33+
id: version
34+
attributes:
35+
label: Affected version(s)
36+
description:
37+
Please add a comma-separated list of the versions affected by this
38+
issue.
39+
placeholder: 'Example: v0.11.0, v0.12.0'
40+
- type: dropdown
41+
id: part
42+
attributes:
43+
label: Affected part(s)
44+
description:
45+
Which parts of the repo are affected by this issue? Select all that
46+
apply.
47+
multiple: true
48+
options:
49+
- I don't know (part:❓)
50+
- Documentation (part:docs)
51+
- Unit, integration and performance tests (part:tests)
52+
- Build script, CI, dependencies, etc. (part:tooling)
53+
# TODO(cookiecutter): Add other parts
54+
# Please have in mind that that the part:xxx labels need to
55+
# be created in the GitHub repository.
56+
validations:
57+
required: true
58+
- type: textarea
59+
id: extra
60+
attributes:
61+
label: Extra information
62+
description:
63+
Please write here any extra information you think it might be relevant,
64+
e.g., if this didn't happen before, or if you suspect where the problem
65+
might be.
66+
placeholder: Any extra information you think it might be relevant.

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# GitHub issue template chooser. For more information see:
2+
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/configuring-issue-templates-for-your-repository#configuring-the-template-chooser
3+
4+
blank_issues_enabled: true
5+
contact_links:
6+
- name: Ask a question ❓
7+
url: https://github.com/frequenz-floss/frequenz-client-dispatch-python/discussions/new?category=support
8+
# TODO(cookiecutter): Make sure the GitHub repository has a discussion category "Support"
9+
# Rename the "Q&A" category to "Support" and change the emoji to 🆘 (SOS)
10+
about: Use this if you are not sure how to do something, have installation problems, etc.

.github/ISSUE_TEMPLATE/feature.yml

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# GitHub issue form. For more information see:
2+
# https://docs.github.com/en/communities/using-templates-to-encourage-useful-issues-and-pull-requests/syntax-for-issue-forms
3+
4+
name: Request a feature or enhancement ✨
5+
description: Use this if something is missing or could be done better or more easily.
6+
labels:
7+
- "part:❓"
8+
- "priority:❓"
9+
- "type:enhancement"
10+
body:
11+
- type: markdown
12+
attributes:
13+
value:
14+
Thanks for taking the time to fill out this feature or enhancement
15+
request!
16+
- type: textarea
17+
id: whats-needed
18+
attributes:
19+
label: What's needed?
20+
description:
21+
Please tell us what's missing or what could be done better or more easily.
22+
placeholder: What's missing or what could be done better or more easily.
23+
validations:
24+
required: true
25+
- type: textarea
26+
id: solution
27+
attributes:
28+
label: Proposed solution
29+
description:
30+
Please tell us how you think the needs above can be fulfilled. Only
31+
fill this field if it wasn't described above.
32+
placeholder:
33+
How do you think the needs above can be fulfilled. Only fill this field
34+
if it wasn't described above.
35+
- type: textarea
36+
id: use-cases
37+
attributes:
38+
label: Use cases
39+
description:
40+
Please tell us about the main use cases you see for this new feature or
41+
enhancement to help us understand more.
42+
placeholder:
43+
The main use cases you see for this new feature or enhancement to help
44+
us understand more.
45+
- type: textarea
46+
id: alternatives
47+
attributes:
48+
label: Alternatives and workarounds
49+
description:
50+
Please tell us if you tried any alternatives or workarounds for these
51+
use cases and how (un)useful they were.
52+
placeholder:
53+
Any alternatives or workarounds for these use cases and how (un)useful
54+
they were.
55+
- type: textarea
56+
id: additional-context
57+
attributes:
58+
label: Additional context
59+
description:
60+
Please add any additional information here - screenshots, diagrams, etc.
61+
placeholder: Any additional information here - screenshots, diagrams, etc.

.github/RELEASE_NOTES.template.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Frequenz Dispatch Client Library Release Notes
2+
3+
## Summary
4+
5+
<!-- Here goes a general summary of what this release is about -->
6+
7+
## Upgrading
8+
9+
<!-- Here goes notes on how to upgrade from previous versions, including deprecations and what they should be replaced with -->
10+
11+
## New Features
12+
13+
<!-- Here goes the main new features and examples or instructions on how to use them -->
14+
15+
## Bug Fixes
16+
17+
<!-- Here goes notable bug fixes that are worth a special mention or explanation -->
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# License: MIT
2+
# Copyright © 2024 Frequenz Energy-as-a-Service GmbH
3+
# This Dockerfile is used to run the tests in arm64, which is not supported by
4+
# GitHub Actions at the moment.
5+
6+
FROM docker.io/library/ubuntu:20.04
7+
8+
ENV DEBIAN_FRONTEND=noninteractive
9+
10+
# Install Python 3.11 and curl to install pip later
11+
RUN apt-get update -y && \
12+
apt-get install --no-install-recommends -y \
13+
software-properties-common && \
14+
add-apt-repository ppa:deadsnakes/ppa && \
15+
apt-get install --no-install-recommends -y \
16+
ca-certificates \
17+
curl \
18+
git \
19+
python3.11 \
20+
python3.11-distutils && \
21+
apt-get clean && \
22+
rm -rf /var/lib/apt/lists/*
23+
24+
# Install pip
25+
RUN curl -sS https://bootstrap.pypa.io/get-pip.py | python3.11
26+
27+
RUN update-alternatives --install \
28+
/usr/local/bin/python python /usr/bin/python3.11 1 && \
29+
python -m pip install --upgrade --no-cache-dir pip
30+
31+
COPY entrypoint.bash /usr/bin/entrypoint.bash
32+
33+
ENTRYPOINT ["/usr/bin/entrypoint.bash"]
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#!/bin/bash
2+
# License: MIT
3+
# Copyright © 2024 Frequenz Energy-as-a-Service GmbH
4+
set -e
5+
6+
echo "System details:" $(uname -a)
7+
echo "Machine:" $(uname -m)
8+
9+
exec "$@"
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# License: MIT
2+
# Copyright © 2024 Frequenz Energy-as-a-Service GmbH
3+
# This Dockerfile is used to test the installation of the python package in
4+
# multiple platforms in the CI. It is not used to build the package itself.
5+
6+
FROM --platform=${TARGETPLATFORM} python:3.11-slim
7+
8+
RUN python -m pip install --upgrade --no-cache-dir pip
9+
10+
COPY dist dist
11+
RUN pip install dist/*.whl && \
12+
rm -rf dist

.github/dependabot.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "pip"
4+
directory: "/"
5+
schedule:
6+
interval: "monthly"
7+
day: "monday"
8+
labels:
9+
- "part:tooling"
10+
- "type:tech-debt"
11+
# Default versioning-strategy. For other versioning-strategy see:
12+
# https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file#versioning-strategy
13+
versioning-strategy: auto
14+
# Allow up to 10 open pull requests for updates to dependency versions
15+
open-pull-requests-limit: 10
16+
# We group production and development ("optional" in the context of
17+
# pyproject.toml) dependency updates when they are patch and minor updates,
18+
# so we end up with less PRs being generated.
19+
# Major updates are still managed, but they'll create one PR per
20+
# dependency, as major updates are expected to be breaking, it is better to
21+
# manage them individually.
22+
groups:
23+
required:
24+
dependency-type: "production"
25+
update-types:
26+
- "minor"
27+
- "patch"
28+
optional:
29+
dependency-type: "development"
30+
update-types:
31+
- "minor"
32+
- "patch"
33+
34+
- package-ecosystem: "github-actions"
35+
directory: "/"
36+
schedule:
37+
interval: "monthly"
38+
day: "monday"
39+
labels:
40+
- "part:tooling"
41+
- "type:tech-debt"

.github/keylabeler.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# KeywordLabeler app configuration. For more information check:
2+
# https://github.com/ZeWaka/KeywordLabeler#readme
3+
4+
# Determines if we search the title (optional). Defaults to true.
5+
matchTitle: true
6+
7+
# Determines if we search the body (optional). Defaults to true.
8+
matchBody: true
9+
10+
# Determines if label matching is case sensitive (optional). Defaults to true.
11+
caseSensitive: true
12+
13+
# Explicit keyword mappings to labels. Form of match:label. Required.
14+
labelMappings:
15+
"part:docs": "part:docs"
16+
"part:tests": "part:tests"
17+
"part:tooling": "part:tooling"
18+
"part:❓": "part:❓"
19+
# TODO(cookiecutter): Add other parts
20+
# Please have in mind that that the part:xxx labels need to
21+
# be created in the GitHub repository.

.github/labeler.yml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# Configuration for the Labeler GitHub action, executed by
2+
# .github/workflows/labeler.yml.
3+
#
4+
# The basic syntax is [label]: [path patterns].
5+
#
6+
# For more details on the configuration please see:
7+
# https://github.com/marketplace/actions/labeler
8+
9+
# TODO(cookiecutter): Add different parts of the source
10+
# For example:
11+
#
12+
# "part:module":
13+
# - "src/frequenz/lib/dispatch_client/module/**"
14+
#
15+
# "part:other":
16+
# - "src/frequenz/lib/dispatch_client/other/**"
17+
#
18+
# # For excluding some files (in this example, label "part:complicated"
19+
# # everything inside src/ with a .py suffix, except for src/__init__.py)
20+
# "part:complicated":
21+
# - any:
22+
# - "src/**/*.py"
23+
# - all:
24+
# - "!src/__init__.py"
25+
#
26+
# Please have in mind that that the part:xxx labels need to
27+
# be created in the GitHub repository.
28+
29+
"part:docs":
30+
- "**/*.md"
31+
- "docs/**"
32+
- "examples/**"
33+
- LICENSE
34+
35+
"part:tests":
36+
- "**/conftest.py"
37+
- "tests/**"
38+
39+
"part:tooling":
40+
- "**/*.ini"
41+
- "**/*.toml"
42+
- "**/*.yaml"
43+
- "**/*.yml"
44+
- "**/conftest.py"
45+
- ".editorconfig"
46+
- ".git*"
47+
- ".git*/**"
48+
- "docs/*.py"
49+
- CODEOWNERS
50+
- MANIFEST.in
51+
- noxfile.py

0 commit comments

Comments
 (0)