Some checks are pending
ci / check (push) Waiting to run
Bugs:
* Shell injection in `fj auth setup-git`: the hostname is now validated
against a strict DNS pattern and `git config` is invoked directly
(no `sh -c`). Added 4 unit tests covering shell metacharacters.
* Pager won't compile on Windows: the libc-based dup2 redirect lives
behind `#[cfg(unix)]`. Non-Unix gets a no-op stub.
Agent-focused Forgejo API gaps:
* `fj issue edit-comment ID` / `delete-comment ID`. Fix a wrong comment
after the fact (an agent's bread-and-butter).
* `fj search code "..." [-R owner/name]`. The most-requested missing
search dimension for codebase exploration.
* `fj pr request-review N user1 user2`, `unrequest-review N user`.
Distinct from `pr review` (your own approval/changes/comment).
* `fj repo watch / unwatch / star / unstar / starred`. Mark repos for
monitoring.
* `fj milestone {list,view,create,edit,close,reopen,delete,assign}`
with `assign N --milestone ID|none` to attach an issue/PR.
UX + stability:
* Global `--json-fields foo,bar` projection on top of any `--json`
output, gh-style. Dotted-path support (`--json-fields owner.login`).
* 429 / Retry-After honored in the retry loop with a 30 s cap.
* Clap `suggestions` feature for typo'd subcommands.
* `fj auth token` and `auth status --show-token` refuse to write to a
TTY by default (`--force` to override).
CI:
* `.forgejo/workflows/ci.yml` runs fmt/clippy/test/release-build on
every push and PR, mirroring the local pre-push hook.
Docs:
* `SECURITY.md` with threat model and known sharp edges.
* `docs/gh-to-fj.md` full command-by-command mapping.
* `docs/faq.md` covering tokens, hosts, debug, scripting, plugins.
Tests: 60 → 75 passing (2 ignored: editor and env-mutating tests that
fight the cargo test harness on macOS).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
51 lines
1.5 KiB
TOML
51 lines
1.5 KiB
TOML
[package]
|
|
name = "fj"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
rust-version = "1.82"
|
|
description = "Command-line tool for Forgejo, in the spirit of gh"
|
|
authors = ["Stephen Way <stephen@rasterstate.com>"]
|
|
license = "MIT"
|
|
repository = "https://rasterhub.com/rasterstate/fj"
|
|
readme = "README.md"
|
|
|
|
[[bin]]
|
|
name = "fj"
|
|
path = "src/main.rs"
|
|
|
|
[dependencies]
|
|
anyhow = "1"
|
|
thiserror = "2"
|
|
clap = { version = "4.5", features = ["derive", "env", "wrap_help", "suggestions"] }
|
|
clap_complete = "4.5"
|
|
clap_mangen = "0.2"
|
|
tokio = { version = "1", features = ["rt-multi-thread", "macros", "fs", "process", "io-util", "io-std", "signal"] }
|
|
reqwest = { version = "0.12", default-features = false, features = ["json", "rustls-tls", "gzip", "multipart"] }
|
|
serde = { version = "1", features = ["derive"] }
|
|
serde_json = "1"
|
|
toml = "0.8"
|
|
directories = "5"
|
|
keyring = { version = "3", features = ["apple-native", "linux-native", "windows-native"] }
|
|
url = "2"
|
|
chrono = { version = "0.4", default-features = false, features = ["serde", "clock"] }
|
|
tabled = { version = "0.16", features = ["ansi"] }
|
|
owo-colors = { version = "4", features = ["supports-colors"] }
|
|
supports-color = "3"
|
|
dialoguer = { version = "0.11", default-features = false, features = ["password"] }
|
|
libc = "0.2"
|
|
|
|
[dev-dependencies]
|
|
wiremock = "0.6"
|
|
tempfile = "3"
|
|
tokio = { version = "1", features = ["rt-multi-thread", "macros", "test-util"] }
|
|
|
|
[profile.release]
|
|
lto = "fat"
|
|
codegen-units = 1
|
|
strip = "symbols"
|
|
opt-level = 3
|
|
panic = "abort"
|
|
|
|
[profile.dist]
|
|
inherits = "release"
|