Skip to content

Commit

Permalink
Merge pull request #3 from MinatoAquaCrews/dev
Browse files Browse the repository at this point in the history
🔖 v0.2.3
  • Loading branch information
KafCoppelia authored Oct 18, 2023
2 parents 583229a + 1e1b57f commit 92508dd
Show file tree
Hide file tree
Showing 12 changed files with 1,250 additions and 708 deletions.
37 changes: 37 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
categories:
- title: 💥 Breaking changes
label: "breaking-change"
- title: "🚀 Features"
labels:
- "feature"
- "enhancement"
- title: "🐛 Bug Fixes"
labels:
- "fix"
- "bugfix"
- "bug"
- title: "🧰 Maintenance"
label: "chore"

name-template: "v$RESOLVED_VERSION"
tag-template: "v$RESOLVED_VERSION"
change-template: "- $TITLE [@$AUTHOR](https://github.com/$AUTHOR) ([#$NUMBER]($URL))"
change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks.
version-resolver:
major:
labels:
- "major"
minor:
labels:
- "minor"
patch:
labels:
- "patch"
default: patch

template: |
## What’s Changed
$CHANGES
Changelog: [`$PREVIOUS_TAG...v$RESOLVED_VERSION`](https://github.com/MinatoAquaCrews/nonebot_plugin_roll/compare/$PREVIOUS_TAG...v$RESOLVED_VERSION)
13 changes: 13 additions & 0 deletions .github/workflows/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"

target-branch: "master"
33 changes: 33 additions & 0 deletions .github/workflows/poetry-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# This workflow will upload a Python Package using Twine when a release is created
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python#publishing-to-package-registries

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.

name: Upload Python Package

on:
release:
types: [published]

permissions:
contents: read

jobs:
publish:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
with:
ref: ${{ env.TAG_NAME }}

- name: Publish python poetry package
uses: JRubics/poetry-publish@v1.17
with:
python_version: "3.10"
pypi_token: ${{ secrets.PYPI_API_TOKEN }}
build_format: "wheel"
ignore_dev_requirements: "yes"
42 changes: 42 additions & 0 deletions .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Release Drafter

on:
push:
tags:
- v*
pull_request_target:
branches:
- master
types:
- closed

permissions:
contents: read

jobs:
update_release_draft:
permissions:
# write permission is required to create a github release
contents: write
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
with:
ref: master

- name: Setup Poetry
uses: Gr1N/setup-poetry@v8

- name: Update poetry.lock
run: poetry update --lock

- run: echo "TAG_NAME=v$(poetry version -s)" >> $GITHUB_ENV

- uses: release-drafter/release-drafter@v5
with:
name: ${{ env.TAG_NAME }}
tag: ${{ env.TAG_NAME }}
publish: true
env:
GITHUB_TOKEN: ${{ secrets.ORG_TOKEN }}
42 changes: 42 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
default_install_hook_types: [pre-commit, prepare-commit-msg]
ci:
autofix_commit_msg: ":rotating_light: auto fix by pre-commit hooks"
autofix_prs: true
autoupdate_branch: master
autoupdate_schedule: monthly
autoupdate_commit_msg: ":arrow_up: auto update by pre-commit hooks"
repos:
- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
- id: isort
stages: [commit]

- repo: https://github.com/psf/black
rev: 23.9.1
hooks:
- id: black
stages: [commit]

- repo: https://github.com/pre-commit/mirrors-prettier
rev: v3.0.3
hooks:
- id: prettier
types_or: [markdown, yaml, json]
stages: [commit]

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- id: mixed-line-ending
- id: check-json

- repo: https://github.com/python-poetry/poetry
rev: 1.6.1
hooks:
- id: poetry-check
- id: poetry-lock
39 changes: 23 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,42 +2,47 @@

# Roll

<!-- prettier-ignore-start -->
<!-- markdownlint-disable-next-line MD036 -->
_🎲 掷骰子 🎲_
<!-- prettier-ignore-end -->

</div>

<p align="center">
<a href="https://github.com/KafCoppelia/nonebot_plugin_roll/blob/beta/LICENSE">
<img src="https://img.shields.io/badge/license-MIT-informational">

<a href="https://github.com/KafCoppelia/nonebot_plugin_roll/blob/master/LICENSE">
<img src="https://img.shields.io/github/license/MinatoAquaCrews/nonebot_plugin_roll?color=blue">
</a>

<a href="https://github.com/nonebot/nonebot2">
<img src="https://img.shields.io/badge/nonebot2-2.0.0b3+-green">
<img src="https://img.shields.io/badge/nonebot2-2.0.0+-green">
</a>

<a href="https://github.com/MinatoAquaCrews/nonebot_plugin_roll/releases/tag/v0.2.2">
<a href="https://github.com/MinatoAquaCrews/nonebot_plugin_roll/releases/tag/v0.2.3">
<img src="https://img.shields.io/github/v/release/MinatoAquaCrews/nonebot_plugin_roll?color=orange">
</a>

<a href="https://www.codefactor.io/repository/github/MinatoAquaCrews/nonebot_plugin_roll">
<img src="https://img.shields.io/codefactor/grade/github/MinatoAquaCrews/nonebot_plugin_roll/beta?color=red">
<img src="https://img.shields.io/codefactor/grade/github/MinatoAquaCrews/nonebot_plugin_roll/master?color=red">
</a>

<a href="https://github.com/MinatoAquaCrews/nonebot_plugin_roll">
<img src="https://img.shields.io/pypi/dm/nonebot_plugin_roll">
</a>


<a href="https://results.pre-commit.ci/latest/github/MinatoAquaCrews/nonebot_plugin_roll/master">
<img src="https://results.pre-commit.ci/badge/github/MinatoAquaCrews/nonebot_plugin_roll/master.svg" alt="pre-commit.ci status">
</a>

</p>

## 版本

v0.2.2
[v0.2.3](https://github.com/MinatoAquaCrews/nonebot_plugin_roll/releases/tag/v0.2.3)

⚠ 适配nonebot2-2.0.0b3+
⚠ 适配nonebot2-2.0.0+

## 安装

通过`pip``nb`安装。
通过 `pip``nb-cli` 安装。

## 功能

Expand All @@ -47,6 +52,8 @@ v0.2.2

掷骰子:[rd/roll/掷骰] [x]d[y],掷出x个y面的骰子,并返回点数。

🎉 掷出特定骰子或特定点数可能有彩蛋!

## 本插件改自

[Omega Miya-roll](https://github.com/Ailitonia/omega-miya)
[Omega Miya-roll](https://github.com/Ailitonia/omega-miya)
Loading

0 comments on commit 92508dd

Please sign in to comment.