Skip to content

fix(dotfiles): alias import with init output#1970

Merged
ellie merged 1 commit intomainfrom
ellie/alias-fix
Apr 22, 2024
Merged

fix(dotfiles): alias import with init output#1970
ellie merged 1 commit intomainfrom
ellie/alias-fix

Conversation

@ellie
Copy link
Copy Markdown
Member

@ellie ellie commented Apr 22, 2024

Ref #1953

Added a test case and fix

cc @rigrig, does this resolve the issue for you?

Checks

  • I am happy for maintainers to push small adjustments to this PR, to speed up the review cycle
  • I have checked that there are no existing pull requests for the same thing

@ellie ellie merged commit d239a67 into main Apr 22, 2024
@ellie ellie deleted the ellie/alias-fix branch April 22, 2024 09:32
@rigrig
Copy link
Copy Markdown
Contributor

rigrig commented Apr 22, 2024

Actually...
I didn't pay a lot of attention when reporting that: I just deleted all aliases from my db to fix the problem, and the fortune was the obvious breakage.
But looking at the code now, it looks broken in another way: Fish alias output doesn't include a = sign, so it would just be e.g.:

alias emacs 'TERM=xterm-24bits emacs -nw --foo=bar'
alias k kubectl

(Fish allows setting them both ways though: both alias k=kubectl and alias k kubectl work)

@ellie
Copy link
Copy Markdown
Member Author

ellie commented Apr 22, 2024

Ah I see! Well that needed fixing anyway, glad it's done.

#1972 should sort that

@rigrig
Copy link
Copy Markdown
Contributor

rigrig commented Apr 22, 2024

Urgh, it's still sometimes broken now: some ASCII art contains =...
I guess maybe it could redirect the alias output to a file and read that? But that seems like a lot of effort 😞

I don't really mind having to turn off the script for the initial import, and I (only just) figured out I can just atuin dotfiles alias delete those stray "aliases", instead of messing with the database.

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.

2 participants