Skip to content

Conversation

@bitcrazed
Copy link
Contributor

@bitcrazed bitcrazed commented Oct 15, 2019

Summary of the Pull Request

Expands any environment variables in background image file paths so that users can specify location of background images relative to, for example, %USERPROFILE%

References

PR Checklist

Validation Steps Performed

Thoroughly debugged with previous failing case, now working case, empty strings, etc. Also added basic regression tests that will fail if icon or backgroundImage paths contain env-vars and the path expansion mechanisms are ever removed/subverted.

bitcrazed and others added 6 commits October 8, 2019 13:54
Co-Authored-By: Dustin L. Howett (MSFT) <duhowett@microsoft.com>
* Set Terminal Settings' Background Iamge Path to expanded Profile's
Background Image Path
* Removed Profile's superfluous Background Image Path setter
* Tidied up some loose ends and comments
@@ -1,33 +1,40 @@
# Welcome

This repository contains the source code for:
Copy link
Contributor

Choose a reason for hiding this comment

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

ABSOLUTELY NOT my man, you've gotta make sure your branches are clean before starting ;)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Damnit! Just saw. Apologies. Will kill and re-create. Seems my home dev box is unclean.

@bitcrazed bitcrazed closed this Oct 15, 2019
Copy link
Contributor

@DHowett-MSFT DHowett-MSFT left a comment

Choose a reason for hiding this comment

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

Other than the tests not testing anything, I'm doing an "approve with suggestions"


VerifyParseSucceeded(settingsJson);
CascadiaSettings settings;
settings._ParseJsonString(settingsJson, false);
Copy link
Contributor

Choose a reason for hiding this comment

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

i like that you added tests, but you should validate that they actually did something! check the resulting values in the path variables.

since you can't really make sure WINDIR expanded to "the right value", you could "check whether there is a % in the final string" maybe?

@DHowett-MSFT
Copy link
Contributor

You should force push this PR instead of deleting it and making a new one! You can even just revert your readme changes in this branch.

@bitcrazed bitcrazed deleted the bitcrazed/Expand-Background-Image-Path branch October 15, 2019 05:13
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.

Terminal takes an unexpected dirt nap when backgroundImage contains environment variables

3 participants