Parser: switch true/false to yes/no

This commit is contained in:
Akemi Izuko 2024-07-17 21:57:55 -06:00
parent a6b3732cd3
commit 2f1959a28b
Signed by: akemi
GPG key ID: 8DE0764E1809E9FC
5 changed files with 13 additions and 13 deletions

View file

@ -132,7 +132,7 @@ Will generate:
```sshconfig
Host ohaton:
ForwardX11 false
ForwardX11 no
Hostname ohaton.cs.ualberta.ca
IdentitiesOnly yes
IdentityFile ~/.ssh/id_ed25519
@ -140,7 +140,7 @@ Host ohaton:
User emiliko
Host coronation:
ForwardX11 false
ForwardX11 no
Hostname coronation.cs.ualberta.ca
IdentitiesOnly yes
IdentityFile ~/.ssh/id_ed25519

View file

@ -132,7 +132,7 @@ def to_ssh_config_string(parse):
for key, values in keys.items():
for value in values:
if isinstance(value, bool):
lines.append(f"\t{key} {'true' if value else 'false'}")
lines.append(f"\t{key} {'yes' if value else 'no'}")
else:
lines.append(f"\t{key} {value}")

View file

@ -1,15 +1,15 @@
Host ohaton
ForwardX11 false
ForwardX11 no
Hostname ohaton.cs.ualberta.ca
IdentitiesOnly true
IdentitiesOnly yes
IdentityFile ~/.ssh/id_ed25519
Port 22
User emiliko
Host coronation
ForwardX11 false
ForwardX11 no
Hostname coronation.cs.ualberta.ca
IdentitiesOnly true
IdentitiesOnly yes
IdentityFile ~/.ssh/id_ed25519
Port 22
User emiliko

View file

@ -1,4 +1,4 @@
Host ohaton
forwardx11 false
identitiesonly true
forwardx11 no
identitiesonly yes
port 22

View file

@ -1,15 +1,15 @@
Host ohaton
ForwardX11 false
ForwardX11 no
Hostname ohaton.cs.ualberta.ca
IdentitiesOnly true
IdentitiesOnly yes
IdentityFile ~/.ssh/id_ed25519
Port 22
User emiliko
Host coronation
ForwardX11 false
ForwardX11 no
Hostname coronation.cs.ualberta.ca
IdentitiesOnly true
IdentitiesOnly yes
IdentityFile ~/.ssh/id_ed25519
Port 22
User emiliko