p2me 0.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- p2me-0.0.0/.changenote/README.md +1 -0
- p2me-0.0.0/.changenote/config.json +18 -0
- p2me-0.0.0/.changenote/rename-to-p2me.md +5 -0
- p2me-0.0.0/.github/workflows/ci.yml +26 -0
- p2me-0.0.0/.github/workflows/release.yml +28 -0
- p2me-0.0.0/.gitignore +68 -0
- p2me-0.0.0/AGENTS.md +20 -0
- p2me-0.0.0/Cargo.lock +7 -0
- p2me-0.0.0/Cargo.toml +9 -0
- p2me-0.0.0/LICENSE +21 -0
- p2me-0.0.0/PKG-INFO +30 -0
- p2me-0.0.0/README.md +19 -0
- p2me-0.0.0/prek.toml +58 -0
- p2me-0.0.0/pyproject.toml +28 -0
- p2me-0.0.0/src/main.rs +3 -0
- p2me-0.0.0/tests/main.rs +11 -0
- p2me-0.0.0/uv.lock +7 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
# Change notes
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/changenote/changenote/main/schema.json",
|
|
3
|
+
"base_branch": "origin/main",
|
|
4
|
+
"changed_file_patterns": [
|
|
5
|
+
"src/**",
|
|
6
|
+
"Cargo.toml",
|
|
7
|
+
"Cargo.lock",
|
|
8
|
+
"pyproject.toml",
|
|
9
|
+
"uv.lock"
|
|
10
|
+
],
|
|
11
|
+
"packages": {
|
|
12
|
+
"p2me": {
|
|
13
|
+
"path": ".",
|
|
14
|
+
"version_file": "Cargo.toml",
|
|
15
|
+
"tag_prefix": "v"
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
name: Checks
|
|
2
|
+
on:
|
|
3
|
+
push:
|
|
4
|
+
branches: [main]
|
|
5
|
+
pull_request:
|
|
6
|
+
|
|
7
|
+
permissions:
|
|
8
|
+
contents: read
|
|
9
|
+
|
|
10
|
+
concurrency:
|
|
11
|
+
group: checks-${{ github.ref }}
|
|
12
|
+
cancel-in-progress: true
|
|
13
|
+
|
|
14
|
+
jobs:
|
|
15
|
+
rust:
|
|
16
|
+
name: ci
|
|
17
|
+
runs-on: ubuntu-latest
|
|
18
|
+
steps:
|
|
19
|
+
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
|
|
20
|
+
with:
|
|
21
|
+
persist-credentials: false
|
|
22
|
+
- name: Check Rust
|
|
23
|
+
run: |
|
|
24
|
+
cargo fmt --all -- --check
|
|
25
|
+
cargo clippy --locked --all-targets -- -D warnings
|
|
26
|
+
cargo test --locked --all-targets
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main]
|
|
6
|
+
workflow_dispatch:
|
|
7
|
+
|
|
8
|
+
permissions: {}
|
|
9
|
+
|
|
10
|
+
concurrency:
|
|
11
|
+
group: changenote-release-main
|
|
12
|
+
cancel-in-progress: false
|
|
13
|
+
|
|
14
|
+
jobs:
|
|
15
|
+
release:
|
|
16
|
+
name: release
|
|
17
|
+
if: github.ref == 'refs/heads/main'
|
|
18
|
+
runs-on: ubuntu-latest
|
|
19
|
+
permissions:
|
|
20
|
+
contents: write # Push the release branch and tags, and create GitHub Releases.
|
|
21
|
+
pull-requests: write # Open and update the managed release pull request.
|
|
22
|
+
steps:
|
|
23
|
+
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
|
|
24
|
+
with:
|
|
25
|
+
persist-credentials: false
|
|
26
|
+
- uses: changenote/action@339f86c81883cb39f3003a38534ca87c97d1d7c2
|
|
27
|
+
with:
|
|
28
|
+
operation: auto
|
p2me-0.0.0/.gitignore
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# macOS
|
|
2
|
+
.DS_Store
|
|
3
|
+
.AppleDouble
|
|
4
|
+
.LSOverride
|
|
5
|
+
._*
|
|
6
|
+
__MACOSX/
|
|
7
|
+
.Spotlight-V100/
|
|
8
|
+
.Trashes/
|
|
9
|
+
|
|
10
|
+
# Linux
|
|
11
|
+
*~
|
|
12
|
+
.fuse_hidden*
|
|
13
|
+
.directory
|
|
14
|
+
.Trash-*/
|
|
15
|
+
.nfs*
|
|
16
|
+
nohup.out
|
|
17
|
+
|
|
18
|
+
# Python environments
|
|
19
|
+
.venv/
|
|
20
|
+
venv/
|
|
21
|
+
.env
|
|
22
|
+
.pypirc
|
|
23
|
+
|
|
24
|
+
# Python bytecode and packages
|
|
25
|
+
__pycache__/
|
|
26
|
+
*.py[codz]
|
|
27
|
+
*$py.class
|
|
28
|
+
/build/
|
|
29
|
+
dist/
|
|
30
|
+
.eggs/
|
|
31
|
+
*.egg-info/
|
|
32
|
+
*.egg
|
|
33
|
+
*.whl
|
|
34
|
+
|
|
35
|
+
# Python tests and tooling
|
|
36
|
+
.pytest_cache/
|
|
37
|
+
.mypy_cache/
|
|
38
|
+
.ruff_cache/
|
|
39
|
+
.tox/
|
|
40
|
+
.nox/
|
|
41
|
+
.coverage
|
|
42
|
+
.coverage.*
|
|
43
|
+
htmlcov/
|
|
44
|
+
|
|
45
|
+
# Generated by Cargo
|
|
46
|
+
# will have compiled files and executables
|
|
47
|
+
debug
|
|
48
|
+
target
|
|
49
|
+
|
|
50
|
+
# These are backup files generated by rustfmt
|
|
51
|
+
**/*.rs.bk
|
|
52
|
+
|
|
53
|
+
# MSVC Windows builds of rustc generate these, which store debugging information
|
|
54
|
+
*.pdb
|
|
55
|
+
|
|
56
|
+
# Generated by cargo mutants
|
|
57
|
+
# Contains mutation testing data
|
|
58
|
+
**/mutants.out*/
|
|
59
|
+
|
|
60
|
+
# rustc will dump stack traces when hitting an internal compiler error to PWD
|
|
61
|
+
rustc-ice-*.txt
|
|
62
|
+
|
|
63
|
+
# RustRover
|
|
64
|
+
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
|
65
|
+
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
|
66
|
+
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
|
67
|
+
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
|
68
|
+
#.idea/
|
p2me-0.0.0/AGENTS.md
ADDED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# p2me guidelines
|
|
2
|
+
|
|
3
|
+
## Commands
|
|
4
|
+
|
|
5
|
+
- From the repository root, run `cargo fmt --all -- --check`, `cargo clippy --locked --all-targets -- -D warnings`, and `cargo test --locked --all-targets` to match [CI](.github/workflows/ci.yml).
|
|
6
|
+
- Run `prek run --all-files` to check repository hygiene and workflow security.
|
|
7
|
+
- Run `uv lock --check` after changing Python package metadata.
|
|
8
|
+
|
|
9
|
+
## Boundaries
|
|
10
|
+
|
|
11
|
+
- Run `changenote version` or `changenote tag`, trigger the release workflow, push tags, create GitHub Releases, or upload packages only when the user explicitly requests that action.
|
|
12
|
+
|
|
13
|
+
## Testing
|
|
14
|
+
|
|
15
|
+
- Test CLI behavior by running the built executable in integration tests under `tests/`.
|
|
16
|
+
|
|
17
|
+
## Git and commits
|
|
18
|
+
|
|
19
|
+
- Before committing a release-relevant change, add or update a note in `.changenote/` for the package in [`.changenote/config.json`](.changenote/config.json) and verify it with `changenote status`.
|
|
20
|
+
- Omit a change note when no release is needed and state the reason in the completion report.
|
p2me-0.0.0/Cargo.lock
ADDED
p2me-0.0.0/Cargo.toml
ADDED
p2me-0.0.0/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 なるみ
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
p2me-0.0.0/PKG-INFO
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: p2me
|
|
3
|
+
Version: 0.0.0
|
|
4
|
+
License-File: LICENSE
|
|
5
|
+
Summary: A minimal command-line tool written in Rust.
|
|
6
|
+
License-Expression: MIT
|
|
7
|
+
Requires-Python: >=3.10
|
|
8
|
+
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
9
|
+
Project-URL: Repository, https://github.com/narumiruna/p2me
|
|
10
|
+
|
|
11
|
+
# p2me
|
|
12
|
+
|
|
13
|
+
GitHub Actions checks formatting, runs Clippy, and runs tests on Linux for pull requests and pushes to `main`.
|
|
14
|
+
|
|
15
|
+
[Changenote](https://github.com/changenote/changenote) uses [`.changenote/`](.changenote/) to manage a release pull request. On pushes to `main`, it also publishes tags and GitHub Releases for verified releases. Manual runs only manage the release pull request. In the repository's Actions settings, allow GitHub Actions to create pull requests. The GitHub release workflow needs no custom secrets and does not upload packages to registries.
|
|
16
|
+
|
|
17
|
+
## Build for PyPI
|
|
18
|
+
|
|
19
|
+
A plain `uv build` on Linux can produce a wheel tagged `linux_x86_64`, which PyPI rejects. Ask Maturin to check PyPI compatibility and write the upload files to a separate directory:
|
|
20
|
+
|
|
21
|
+
```sh
|
|
22
|
+
uv build --clear --out-dir dist/pypi --config-setting 'build-args=--compatibility pypi'
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
When ready to publish, pass only those files to `uv publish` so it does not pick up an older wheel from `dist/`:
|
|
26
|
+
|
|
27
|
+
```sh
|
|
28
|
+
uv publish dist/pypi/*.whl dist/pypi/*.tar.gz
|
|
29
|
+
```
|
|
30
|
+
|
p2me-0.0.0/README.md
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# p2me
|
|
2
|
+
|
|
3
|
+
GitHub Actions checks formatting, runs Clippy, and runs tests on Linux for pull requests and pushes to `main`.
|
|
4
|
+
|
|
5
|
+
[Changenote](https://github.com/changenote/changenote) uses [`.changenote/`](.changenote/) to manage a release pull request. On pushes to `main`, it also publishes tags and GitHub Releases for verified releases. Manual runs only manage the release pull request. In the repository's Actions settings, allow GitHub Actions to create pull requests. The GitHub release workflow needs no custom secrets and does not upload packages to registries.
|
|
6
|
+
|
|
7
|
+
## Build for PyPI
|
|
8
|
+
|
|
9
|
+
A plain `uv build` on Linux can produce a wheel tagged `linux_x86_64`, which PyPI rejects. Ask Maturin to check PyPI compatibility and write the upload files to a separate directory:
|
|
10
|
+
|
|
11
|
+
```sh
|
|
12
|
+
uv build --clear --out-dir dist/pypi --config-setting 'build-args=--compatibility pypi'
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
When ready to publish, pass only those files to `uv publish` so it does not pick up an older wheel from `dist/`:
|
|
16
|
+
|
|
17
|
+
```sh
|
|
18
|
+
uv publish dist/pypi/*.whl dist/pypi/*.tar.gz
|
|
19
|
+
```
|
p2me-0.0.0/prek.toml
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
#:schema https://www.schemastore.org/prek.json
|
|
2
|
+
|
|
3
|
+
# Changenote owns the exact format of the generated changelog.
|
|
4
|
+
exclude = '^CHANGELOG\.md$'
|
|
5
|
+
|
|
6
|
+
[[repos]]
|
|
7
|
+
repo = "https://github.com/pre-commit/pre-commit-hooks"
|
|
8
|
+
rev = "v6.0.0"
|
|
9
|
+
|
|
10
|
+
[[repos.hooks]]
|
|
11
|
+
id = "check-yaml"
|
|
12
|
+
|
|
13
|
+
[[repos.hooks]]
|
|
14
|
+
id = "end-of-file-fixer"
|
|
15
|
+
|
|
16
|
+
[[repos.hooks]]
|
|
17
|
+
id = "mixed-line-ending"
|
|
18
|
+
args = ["--fix=lf"]
|
|
19
|
+
|
|
20
|
+
[[repos.hooks]]
|
|
21
|
+
id = "trailing-whitespace"
|
|
22
|
+
|
|
23
|
+
[[repos]]
|
|
24
|
+
repo = "local"
|
|
25
|
+
|
|
26
|
+
[[repos.hooks]]
|
|
27
|
+
id = "rustfmt"
|
|
28
|
+
name = "Rust format"
|
|
29
|
+
entry = "cargo fmt --check"
|
|
30
|
+
language = "system"
|
|
31
|
+
pass_filenames = false
|
|
32
|
+
types = ["rust"]
|
|
33
|
+
|
|
34
|
+
[[repos.hooks]]
|
|
35
|
+
id = "clippy"
|
|
36
|
+
name = "Rust lint"
|
|
37
|
+
entry = "cargo clippy --locked --all-targets -- -D warnings"
|
|
38
|
+
language = "system"
|
|
39
|
+
pass_filenames = false
|
|
40
|
+
types = ["rust"]
|
|
41
|
+
|
|
42
|
+
[[repos.hooks]]
|
|
43
|
+
id = "clippy-fix"
|
|
44
|
+
name = "Rust lint fix"
|
|
45
|
+
entry = "cargo clippy --fix --allow-dirty --locked --all-targets -- -D warnings"
|
|
46
|
+
language = "system"
|
|
47
|
+
pass_filenames = false
|
|
48
|
+
types = ["rust"]
|
|
49
|
+
stages = ["manual"]
|
|
50
|
+
|
|
51
|
+
[[repos]]
|
|
52
|
+
repo = "https://github.com/zizmorcore/zizmor-pre-commit"
|
|
53
|
+
rev = "v1.30.1"
|
|
54
|
+
|
|
55
|
+
[[repos.hooks]]
|
|
56
|
+
id = "zizmor"
|
|
57
|
+
args = ["--pedantic", "."]
|
|
58
|
+
pass_filenames = false
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "p2me"
|
|
3
|
+
description = "A minimal command-line tool written in Rust."
|
|
4
|
+
readme = "README.md"
|
|
5
|
+
requires-python = ">=3.10"
|
|
6
|
+
license = "MIT"
|
|
7
|
+
dependencies = []
|
|
8
|
+
dynamic = ["version"]
|
|
9
|
+
|
|
10
|
+
[project.urls]
|
|
11
|
+
Repository = "https://github.com/narumiruna/p2me"
|
|
12
|
+
|
|
13
|
+
[build-system]
|
|
14
|
+
requires = ["maturin>=1.9,<2"]
|
|
15
|
+
build-backend = "maturin"
|
|
16
|
+
|
|
17
|
+
[tool.maturin]
|
|
18
|
+
bindings = "bin"
|
|
19
|
+
manifest-path = "Cargo.toml"
|
|
20
|
+
strip = true
|
|
21
|
+
|
|
22
|
+
[tool.uv]
|
|
23
|
+
cache-keys = [
|
|
24
|
+
{ file = "pyproject.toml" },
|
|
25
|
+
{ file = "Cargo.toml" },
|
|
26
|
+
{ file = "Cargo.lock" },
|
|
27
|
+
{ file = "src/**/*.rs" },
|
|
28
|
+
]
|
p2me-0.0.0/src/main.rs
ADDED
p2me-0.0.0/tests/main.rs
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
use std::process::Command;
|
|
2
|
+
|
|
3
|
+
#[test]
|
|
4
|
+
fn prints_greeting() {
|
|
5
|
+
let output = Command::new(env!("CARGO_BIN_EXE_p2me"))
|
|
6
|
+
.output()
|
|
7
|
+
.expect("failed to run the CLI");
|
|
8
|
+
|
|
9
|
+
assert!(output.status.success());
|
|
10
|
+
assert_eq!(output.stdout, b"Hello, world!\n");
|
|
11
|
+
}
|