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

Fix: compatibility with WSL and Powershell Unix for draw.io diagram #91

Merged
merged 4 commits into from
Dec 8, 2022

Conversation

quintindk
Copy link
Contributor

While testing this script for a customer I was disappointed to see that it didn't generate the Draw.io diagram file when running in Powershell on Windows Subsystem for Linux. Seems to have been a small change i.e. folder slashes and a simple if change.

Tested this on Ubuntu for Windows 22.04 LTS.

@quintindk quintindk closed this Dec 6, 2022
@quintindk quintindk reopened this Dec 6, 2022
@marcusribeirobr
Copy link

Cara, muito boa essa ferramenta! Tenho mostrado pra gente até de dentro da Microsoft que fica impressionado. Parabéns!

Hello,

We need to add this if, or it might fail when running on regular Windows.
Copy link
Collaborator

@Claudio-Merola Claudio-Merola left a comment

Choose a reason for hiding this comment

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

just add this validation to the line 762:
if($($args[0]) -like '**')
{
$ModuSeq0 = New-Object System.IO.StreamReader($($args[0]) + '\Extras\DrawIODiagram.ps1')
}
else
{
$ModuSeq0 = New-Object System.IO.StreamReader($($args[0]) + '/Extras/DrawIODiagram.ps1')
}

@quintindk
Copy link
Contributor Author

Made the required changes. Thanks for letting me be part of such an amazing tool's development :)

@Claudio-Merola Claudio-Merola merged commit a5316c7 into microsoft:main Dec 8, 2022
@quintindk quintindk deleted the fix/wsl-diagram branch June 6, 2023 06:55
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.

3 participants