Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ssh: made the ssh config file path modular #3852

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

Neon-44
Copy link

@Neon-44 Neon-44 commented Apr 7, 2023

made a new option programs.ssh.userConfigFile with default ".ssh/config" and replaced home.file.".ssh/config".text with home.file.${cfg.userConfigFile}.text

Description

adds an Option programs.ssh.userConfigFile which expects a String returned (default .ssh/config).
replaces home.file.".ssh/config".txt with home.file.${cfg.userConfigFile}.txt
can be used together with an Alias (ssh = ssh -F /path/to/file) to declutter the home directory
default option for userConfigFile is still ".ssh/config"

Checklist

  • Change is backwards compatible.

  • Code formatted with ./format.

  • Code tested through nix-shell --pure tests -A run.all.

  • Test cases updated/added. See example.

  • Commit messages are formatted like

    {component}: {description}
    
    {long description}
    

    See CONTRIBUTING for more information and recent commit messages for examples.

  • If this PR adds a new module

this PR doesn't add a new Module.

made a new option programs.ssh.userConfigFile with default ".ssh/config" and
replaced home.file.".ssh/config".text with home.file.${cfg.userConfigFile}.text
@Neon-44 Neon-44 requested a review from rycee as a code owner April 7, 2023 16:08
@stale
Copy link

stale bot commented Jul 9, 2023

Thank you for your contribution! I marked this pull request as stale due to inactivity. Please read the relevant sections below before commenting.

If you are the original author of the PR

  • GitHub sometimes doesn't notify people who commented / reviewed a PR previously when you (force) push commits. If you have addressed the reviews you can officially ask for a review from those who commented to you or anyone else.
  • If it is unfinished but you plan to finish it, please mark it as a draft.
  • If you don't expect to work on it any time soon, please consider closing it with a short comment encouraging someone else to pick up your work.
  • To get things rolling again, rebase the PR against the target branch and address valid comments.

If you are not the original author of the PR

  • If you want to pick up the work on this PR, please create a new PR and indicate that it supercedes and closes this PR.

@stale stale bot added the status: stale label Jul 9, 2023
@nechtarg
Copy link

nechtarg commented Jul 9, 2023

Shouldn't the generation of the alias be another option included with this?

@stale stale bot removed the status: stale label Jul 9, 2023
@stale
Copy link

stale bot commented Oct 8, 2023

Thank you for your contribution! I marked this pull request as stale due to inactivity. Please read the relevant sections below before commenting.

If you are the original author of the PR

  • GitHub sometimes doesn't notify people who commented / reviewed a PR previously when you (force) push commits. If you have addressed the reviews you can officially ask for a review from those who commented to you or anyone else.
  • If it is unfinished but you plan to finish it, please mark it as a draft.
  • If you don't expect to work on it any time soon, please consider closing it with a short comment encouraging someone else to pick up your work.
  • To get things rolling again, rebase the PR against the target branch and address valid comments.

If you are not the original author of the PR

  • If you want to pick up the work on this PR, please create a new PR and indicate that it supercedes and closes this PR.

@stale stale bot added the status: stale label Oct 8, 2023
@nechtarg
Copy link

Okay, I think that can be put aside for another pr. Having this here merged would be huge

@stale stale bot removed the status: stale label Oct 11, 2023
Copy link

stale bot commented Jan 18, 2024

Thank you for your contribution! I marked this pull request as stale due to inactivity. Please read the relevant sections below before commenting.

If you are the original author of the PR

  • GitHub sometimes doesn't notify people who commented / reviewed a PR previously when you (force) push commits. If you have addressed the reviews you can officially ask for a review from those who commented to you or anyone else.
  • If it is unfinished but you plan to finish it, please mark it as a draft.
  • If you don't expect to work on it any time soon, please consider closing it with a short comment encouraging someone else to pick up your work.
  • To get things rolling again, rebase the PR against the target branch and address valid comments.

If you are not the original author of the PR

  • If you want to pick up the work on this PR, please create a new PR and indicate that it supercedes and closes this PR.

@stale stale bot added the status: stale label Jan 18, 2024
@Aleksanaa
Copy link
Contributor

Still important

@teto
Copy link
Collaborator

teto commented Feb 23, 2025

rather than adding yet another config item, you could disable the writing of the file (e.g. xdg.configFile."nix/nix.conf".enable = false;) and write its output somewhere else. I am not absolutely sure you can copy the content of the file but worth a try, it should still be available even when disabled.
`

Neon-44 and others added 3 commits March 4, 2025 23:00
Co-authored-by: Austin Horstman <[email protected]>
Co-authored-by: Austin Horstman <[email protected]>
Co-authored-by: Austin Horstman <[email protected]>
@Neon-44
Copy link
Author

Neon-44 commented Mar 4, 2025

the wording @khaneliman suggested is more intuitive, let's go with that instead ^^

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

Successfully merging this pull request may close these issues.

6 participants