# PR Description
* Adds/updates the following files to all toolkits:
- `.pre-commit-config.yaml`
- `.ruff.toml`
- `LICENSE`
- `Makefile`
- `pyproject.toml`
* Lint all toolkits such that they pass `make check` and `make test` (a
total doozy). This includes adding some unit tests and evals.
* Github workflow for testing toolkits before merge into main (courtesy
of @sdreyer)
* Added a QOL improvement for tool developers for when they need to get
the context's auth token.
* Minor updates to `arcade new` template.
99 lines
2 KiB
Python
99 lines
2 KiB
Python
from enum import Enum
|
|
|
|
|
|
# Pull Request specific
|
|
class PRSortProperty(str, Enum):
|
|
CREATED = "created"
|
|
UPDATED = "updated"
|
|
POPULARITY = "popularity"
|
|
LONG_RUNNING = "long-running"
|
|
|
|
|
|
class PRState(str, Enum):
|
|
OPEN = "open"
|
|
CLOSED = "closed"
|
|
ALL = "all"
|
|
|
|
|
|
class ReviewCommentSortProperty(str, Enum):
|
|
CREATED = "created"
|
|
UPDATED = "updated"
|
|
|
|
|
|
class ReviewCommentSubjectType(str, Enum):
|
|
FILE = "file"
|
|
LINE = "line"
|
|
|
|
|
|
class DiffSide(str, Enum):
|
|
"""
|
|
The side of the diff that the pull request's changes appear on.
|
|
Use LEFT for deletions that appear in red.
|
|
Use RIGHT for additions that appear in green or unchanged
|
|
lines that appear in white and are shown for context
|
|
"""
|
|
|
|
LEFT = "LEFT"
|
|
RIGHT = "RIGHT"
|
|
|
|
|
|
# Repo specific
|
|
class RepoType(str, Enum):
|
|
"""
|
|
The types of repositories you want returned when listing organization repositories.
|
|
Default is all repositories.
|
|
"""
|
|
|
|
ALL = "all"
|
|
PUBLIC = "public"
|
|
PRIVATE = "private"
|
|
FORKS = "forks"
|
|
SOURCES = "sources"
|
|
MEMBER = "member"
|
|
|
|
|
|
class RepoSortProperty(str, Enum):
|
|
"""
|
|
The property to sort the results by when listing organization repositories.
|
|
Default is created.
|
|
"""
|
|
|
|
CREATED = "created"
|
|
UPDATED = "updated"
|
|
PUSHED = "pushed"
|
|
FULL_NAME = "full_name"
|
|
|
|
|
|
class RepoTimePeriod(str, Enum):
|
|
"""
|
|
The time period to filter by when listing repository activities.
|
|
"""
|
|
|
|
DAY = "day"
|
|
WEEK = "week"
|
|
MONTH = "month"
|
|
QUARTER = "quarter"
|
|
YEAR = "year"
|
|
|
|
|
|
class ActivityType(str, Enum):
|
|
"""
|
|
The activity type to filter by when listing repository activities.
|
|
"""
|
|
|
|
PUSH = "push"
|
|
FORCE_PUSH = "force_push"
|
|
BRANCH_CREATION = "branch_creation"
|
|
BRANCH_DELETION = "branch_deletion"
|
|
PR_MERGE = "pr_merge"
|
|
MERGE_QUEUE_MERGE = "merge_queue_merge"
|
|
|
|
|
|
class SortDirection(str, Enum):
|
|
"""
|
|
The order to sort by when listing organization repositories.
|
|
Default is asc.
|
|
"""
|
|
|
|
ASC = "asc"
|
|
DESC = "desc"
|