Skip to content

fix: respect CORTEX_HOME in alias command#261

Open
mi6886 wants to merge 1 commit into
CortexLM:mainfrom
mi6886:codex-fix-alias-cortex-home-51514
Open

fix: respect CORTEX_HOME in alias command#261
mi6886 wants to merge 1 commit into
CortexLM:mainfrom
mi6886:codex-fix-alias-cortex-home-51514

Conversation

@mi6886
Copy link
Copy Markdown

@mi6886 mi6886 commented May 12, 2026

Fixes PlatformNetwork/bounty-challenge#51514.

This updates the alias command to use the shared Cortex home resolver before appending aliases.toml, so alias reads and writes honor the active CORTEX_HOME.

Changes:

  • Uses cortex_common::get_cortex_home() for alias config path resolution.
  • Preserves the existing ~/.cortex/aliases.toml fallback when common directory resolution is unavailable.
  • Adds regression coverage that verifies CORTEX_HOME is respected.

Verification:

  • git diff --check

Note: I could not run the focused Rust tests locally because this environment does not currently have cargo or rustfmt installed in PATH.

Copy link
Copy Markdown

@greptile-apps greptile-apps Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] [v0.0.7] cortex alias set ignores CORTEX_HOME and always writes to ~/.cortex/aliases.toml

1 participant