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

Add support for ~ home folder expansion #284

Merged
merged 1 commit into from
Apr 27, 2016
Merged

Conversation

maxpoulin64
Copy link
Member

No description provided.

@maxpoulin64 maxpoulin64 added Type: Feature Tickets that describe a desired feature or PRs that add them to the project. second review needed labels Apr 27, 2016
@xPaw xPaw merged commit 8380fc3 into thelounge:master Apr 27, 2016
@maxpoulin64 maxpoulin64 deleted the tilde branch April 27, 2016 08:31
home = process.env.HOME || "";
}

home = home.replace("$", "$$$$");
Copy link
Member

@astorije astorije Apr 29, 2016

Choose a reason for hiding this comment

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

Why is this necessary? Escaping? Why 4 of them lol? Would have \$ worked too (fairly common when escaping stuff)?

Copy link
Member

Choose a reason for hiding this comment

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

Because $$$$ escapes into $$, which is required for the next replace to keep the final $.

See https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/String/replace#Specifying_a_string_as_a_parameter

Copy link
Member

Choose a reason for hiding this comment

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

Right, I missed that part, thanks a lot for the details @xPaw :-)

@astorije astorije added this to the ★ Next Release milestone May 15, 2016
matburnham pushed a commit to matburnham/lounge that referenced this pull request Sep 6, 2017
Add support for ~ home folder expansion
@xPaw xPaw removed their assignment Mar 12, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature Tickets that describe a desired feature or PRs that add them to the project.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants