-
Notifications
You must be signed in to change notification settings - Fork 0
Analyze remaining shell functions for potential migration to devforge #36
Copy link
Copy link
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Context
During the shell-to-devforge migration (dotfiles PR #75), several shell functions were successfully ported:
git-sync-repos→dev repo syncdip/dreset→dev docker ips/dev docker reset_vm_use_go/_vm_use_node/_vm_use_python→dev project use
However, two groups of functions were left behind. This issue tracks analyzing whether and how they could be migrated.
Keep in Shell (cannot migrate today)
These were skipped because they mutate the parent shell environment (env vars, cd) or are trivial one-liners. The core blocker is that a subprocess cannot export variables or change the working directory of the parent shell — but the same eval "$(dev ...)" pattern used for dev project use could potentially be applied here.
| Function | What it does | Blocker |
|---|---|---|
aws-prof() |
Sets AWS_PROFILE env var |
Subprocess can't export to parent shell |
azm-subs() |
Wraps az account set --subscription |
Trivial one-liner |
reload-credentials() / _op_load_references() |
Loads secrets from 1Password into env vars | Subprocess can't export to parent shell |
| Kubernetes kubeconfig merging | Auto-detects and sets KUBECONFIG from ~/.kube/config-files/ |
Subprocess can't export to parent shell |
pyenv() wrapper / _vm_cleanup_pyenv_locks() |
Handles noclobber and stale lock file issues | Shell-level workaround for pyenv bugs |
ls/ll/la/lt/t eza aliases |
Modern file listing with eza | Personal shell preferences |
Questions to investigate
- Could
aws-prof,reload-credentials, and kubeconfig merging use theevalpattern (printexportstatements to stdout)? - Is there value in centralizing 1Password credential loading into devforge, or does it belong in dotfiles?
- Should the pyenv workarounds be upstreamed to pyenv itself rather than maintained in either devforge or dotfiles?
- Are eza aliases worth managing in a CLI tool, or are they purely shell configuration?
Out of Scope (not development-related)
These are utility functions unrelated to software development workflows. They likely don't belong in devforge but are listed here for completeness.
| Function | What it does |
|---|---|
clear-h() |
Clears shell history files |
clear-logs() |
Clears system log files older than 5 days |
pdf-join() |
Joins two PDFs with pdftk |
pdf-to-jpg() |
Converts PDF to JPG with ImageMagick |
jpg-to-pdf() |
Converts JPGs to PDF with ImageMagick |
video-to-mp4() |
Converts video to MP4 with ffmpeg |
References
- Dotfiles repo: rios0rios0/dotfiles
- Migration PR: dotfiles#75
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request