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

Docs: Update Setup Guide for Windows #166

Open
meganindya opened this issue Feb 12, 2022 · 12 comments
Open

Docs: Update Setup Guide for Windows #166

meganindya opened this issue Feb 12, 2022 · 12 comments
Labels
documentation Improvements or additions to documentation good first issue Good for newcomers

Comments

@meganindya
Copy link
Member

Description

The "Setup Development Environment" section is geared towards BASH-like shells. The guide is good for Linux distros and MacOS. However, on Windows, there might be differences. Update the guide to accommodate Windows installations.

@meganindya meganindya added documentation Improvements or additions to documentation good first issue Good for newcomers labels Feb 12, 2022
@impAkshat
Copy link
Contributor

I am on it.

@impAkshat
Copy link
Contributor

impAkshat commented Feb 12, 2022

Without Docker setup in windows is running fine. But the specific versions are not installed.

To install the specific versions, there are some problems-

  1. Loading scripts are not allowed in windows. After installing typescript and running tsc -v.
    There is this error-
    tsc : File C:\Users\akshu\AppData\Roaming\npm\tsc.ps1 cannot be loaded because running scripts is disabled on this system. For more information, see about_Execution_Policies at https:/go.microsoft.com/fwlink/?LinkID=135170. There is some windows Power shell Execution Policies and the Default is Restricted. Although it can be changed by simply excuting 1 command (reference). But these Execution Policies are for security reasons and changing them might create problem for the user.

FIX CAN BE- No need to check the versions of installed scripts or warning the user about changing execution policies.

  1. To install the previous node version. We can use nvm. But in windows we have to install through installer and also have to use nvm-windows which is not developed by nvm as stated in nvm documentations -

for Windows, a few alternatives exist, which are neither supported nor developed by us

FIX CAN BE-

  • Update the node version if there is no breaking in the code as the required version of node for mbv4 is v14.17.0 is pretty old dated and current stable version is v16.14.0 .
    OR
  • To use nvm-windows
  1. && is not a valid statement separator in windows so checking installations node -v && npm -v && tsc -v && ts-node -v && http-server -v will give error.

@meganindya can you once check which typescript are you using, because installing the requirements using this command will install the latest versions.

npm i -g http-server
npm i -g typescript
npm i -g ts-node

@d-e-v-esh
Copy link
Contributor

d-e-v-esh commented Feb 12, 2022

&& works on PowerShell which is now considered as the main CLI for windows, cmd is dramatically inferior is just there for backward compatibility and I think most devs on windows use PowerShell with ExecutionPolicy RemoteSigned or something that lets them run scripts.

We can just put a disclaimer to use PowerShell instead of cmd and use node v14.17.0 in docs and say that you need ExecutionPolicy RemoteSigned to run scripts if they run into this problem and link them to this page.

@impAkshat
Copy link
Contributor

I am using Poweshell only, && is not supported there also.
image

@d-e-v-esh
Copy link
Contributor

d-e-v-esh commented Feb 12, 2022

@impAkshat what version of PowerShell are you running? Check with this $PSVersionTable.
This looks like PowerShell 5, it works in PowerShell 7.

@impAkshat
Copy link
Contributor

Right I am using version 5.

@d-e-v-esh
Copy link
Contributor

PowerShell 5 is very old, you should install PowerShell 7 latest version. That will work well.

@meganindya
Copy link
Member Author

We should use Node v16. The workflows all run on Node v16.

@meganindya
Copy link
Member Author

http-server, typescript, and ts-node at the global level aren't for the app. http-server can serve built files as an extra measure. If users have python installed, then can also run python3 -m http.server --bind 127.0.0.1 8080 (this command runs on unix-like systems). typescript and ts-node are also extra executables in case user wants to transpile or run a .ts script while developing. None of these are required by the app. typescript dependency used by the app is different from the global executable.

@meganindya
Copy link
Member Author

As for node, installing nodejs executable should install npm as well. I'm not sure about the installation paths on Windows.

@meganindya meganindya added this to the Release v4.1.0 milestone Feb 14, 2022
@d-e-v-esh
Copy link
Contributor

@meganindya What should we add to the docs? There does not seem to be many problems for windows other than the ExecutionPolicy error and the && error in older versions of PowerShell. Should we just add these two points into the documentation?

@meganindya meganindya removed this from the Release Next milestone Nov 6, 2022
@meganindya meganindya moved this to ⌛️ Ready in Music Blocks (v4) Nov 11, 2022
@LeelavathiChandu1
Copy link

Is this issue currently opened?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation good first issue Good for newcomers
Projects
Status: ⌛️ Ready
Development

No branches or pull requests

4 participants