stalecontext/forgejo-cli-plus
2
4
Fork
You've already forked forgejo-cli-plus
1

repo edit: add command to update repo description, visibility, and other settings #27

Open
opened 2026年03月29日 18:49:40 +02:00 by okdas · 2 comments

Summary

There's no repo edit command to update repository settings (description, visibility, etc.) after creation.

Current behavior

$ fj repo --help
Commands:
 create, fork, migrate, view, readme, clone, star, unstar, delete, browse, labels

No edit or update subcommand for repos.

Expected behavior

A repo edit command, similar to how issue edit, release edit, and org edit already work:

fj repo edit owner/repo --description "New description"
fj repo edit owner/repo --private false

Context

The edit pattern is well-established in the codebase:

  • issue edit uses EditIssueOption + api.issue_edit_issue()
  • release edit uses EditReleaseOption + api.repo_edit_release()
  • org edit uses EditOrgOption + api.org_edit()

For repos, neither EditRepoOption nor a repo_edit() API method appear to be used. The Forgejo API does support PATCH /api/v1/repos/{owner}/{repo} — the forgejo-api crate may need to expose this type first.

Use case

After creating a repo (especially via CLI), there's no way to set/update the description without going to the web UI.

## Summary There's no `repo edit` command to update repository settings (description, visibility, etc.) after creation. ## Current behavior ``` $ fj repo --help Commands: create, fork, migrate, view, readme, clone, star, unstar, delete, browse, labels ``` No `edit` or `update` subcommand for repos. ## Expected behavior A `repo edit` command, similar to how `issue edit`, `release edit`, and `org edit` already work: ``` fj repo edit owner/repo --description "New description" fj repo edit owner/repo --private false ``` ## Context The edit pattern is well-established in the codebase: - `issue edit` uses `EditIssueOption` + `api.issue_edit_issue()` - `release edit` uses `EditReleaseOption` + `api.repo_edit_release()` - `org edit` uses `EditOrgOption` + `api.org_edit()` For repos, neither `EditRepoOption` nor a `repo_edit()` API method appear to be used. The Forgejo API does support `PATCH /api/v1/repos/{owner}/{repo}` — the forgejo-api crate may need to expose this type first. ## Use case After creating a repo (especially via CLI), there's no way to set/update the description without going to the web UI.
Author
Copy link

Confirmed: the Forgejo API fully supports this via PATCH /api/v1/repos/{owner}/{repo} (operationId: repoEdit).

The EditRepoOption schema includes: description, name, private, archived, default_branch, has_issues, has_wiki, has_pull_requests, has_projects, has_packages, has_actions, has_releases, website, template, and many merge-related settings.

The forgejo-api Rust crate would need to expose this type (or it may already under a different name).

Confirmed: the Forgejo API fully supports this via `PATCH /api/v1/repos/{owner}/{repo}` (operationId: `repoEdit`). The `EditRepoOption` schema includes: `description`, `name`, `private`, `archived`, `default_branch`, `has_issues`, `has_wiki`, `has_pull_requests`, `has_projects`, `has_packages`, `has_actions`, `has_releases`, `website`, `template`, and many merge-related settings. The forgejo-api Rust crate would need to expose this type (or it may already under a different name).

Going to do automated test suite before handling this, but will get to it after the next release

Going to do automated test suite before handling this, but will get to it after the next release
Sign in to join this conversation.
No Branch/Tag specified
main
feature/issue-batch-2026-07
upstream-sync/2026-07-02
feat/repo-create-org
projects
v2.0.0
upstream-reviewed/2026-07-02
v1.1.0
upstream-reviewed/2026-03-31
v1.0.0
upstream-reviewed/2026-03-16
v0.4.0
v0.3.0
v0.2.0
v0.1.1
v0.1.0
v0.0.4
v0.0.3
v0.0.2
v0.0.1
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
stalecontext/forgejo-cli-plus#27
Reference in a new issue
stalecontext/forgejo-cli-plus
No description provided.
Delete branch "%!s()"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?