Sprint B.5: add-LICENSE action (MIT/Apache-2.0) in [m] menu + vulp repo license
- src/license/: embedded templates, holder resolution (config > git user.name > account username), write path shared by TUI and CLI - TUI: bulk-aware [m] entry over action_targets(), kind select + confirm, point-updates has_license/is_dirty, logs to activity (new License kind) - CLI: vulp repo license <repo>...|--all [--kind] [--holder] [--json], skips already-licensed repos, exit 2/4 contract kept - config: license_holder + default_license fields (TUI-editable) - never overwrites an existing license, never auto-commits
This commit is contained in:
1 parent
0468c032c6
commit
f1432d1cd3
15 files changed
+506
-7
No files matched your search
@@ -609,6 +609,12 @@ pub fn open_action_menu(state: &mut HubState) {
|
||||
entries.push(entry("Delete project", "Del", kc(KeyCode::Delete)));
|
||||
}
|
||||
|
||||
// Bulk-aware (multi-select > cursor repo > project): only shown when at
|
||||
// least one targeted repo is missing a license file.
|
||||
if state.action_targets().iter().any(|&ri| !state.repos[ri].has_license) {
|
||||
entries.push(entry("Add LICENSE (MIT/Apache)", "", MenuAction::AddLicense));
|
||||
}
|
||||
|
||||
match state.tab {
|
||||
Tab::Todos => {
|
||||
entries.push(entry("Cycle todo status", "Space", kc(KeyCode::Char(' '))));
|
||||
|
||||
Reference in new issue
Block a user