Skip to content
This repository was archived by the owner on Jan 17, 2021. It is now read-only.

Conversation

@eargollo
Copy link
Contributor

@eargollo eargollo commented Jun 14, 2019

Copy link
Member

@deansheather deansheather left a comment

Choose a reason for hiding this comment

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

I don't have Windows so I'm unable to test the code, but it looks OK other than this.

// Downloads the latest code-server and allows it to be executed.
sshCmdStr := fmt.Sprintf("ssh %v %v '/usr/bin/env bash'", o.sshFlags, host)
// sshCmdStr := fmt.Sprintf("ssh %v %v /bin/bash -l", o.sshFlags, host)
sshCmdStr := fmt.Sprintf("ssh %v %v '/usr/bin/env bash -l'", o.sshFlags, host)
Copy link
Member

Choose a reason for hiding this comment

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

The login shell stuff should be in a separate PR as it's unrelated to Git Bash for Windows support.

sshCmdStr := fmt.Sprintf("ssh %v %v '/usr/bin/env bash -l'", o.sshFlags, host)

sshCmd := exec.Command("sh", "-c", sshCmdStr)
sshCmd := exec.Command("sh", "-l", "-c", sshCmdStr)
Copy link
Member

Choose a reason for hiding this comment

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

SSH is called from more places than just this, so if we're going to change sh to a login shell so it reads the profile we should also do this every else.

@eargollo
Copy link
Contributor Author

Closing this one to submit two separate PR's. Thanks for comments.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants