You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: environment-setup.md
+10-28Lines changed: 10 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -236,41 +236,23 @@ If the binary is not found run `gem env` to examine your folders, and update you
236
236
237
237
:::warning Important note about macOS 12.3+
238
238
239
-
Starting with macOS 12.3, python 2.x is no longer shipped with the system and requires you to install it manually.
239
+
Starting with macOS 12.3, python 2.x is no longer shipped with the system and the python3 executable isn't aliased to `python`, you will need to do that manually.
240
240
241
241
If you are on macOS 12.3 or newer, please follow these instructions.
242
242
243
-
:warning: These instructions may change over time, as we are still evaluating whether or not there's a better approach, but the following should get you running on macOS 12.3+.
244
-
245
-
First, install **<abbrtitle="Python version manager">pyenv</abbr>** and [email protected] by running the following:
243
+
:warning:**Note**: Python 3 is fully supported by the NativeScript components that rely on it, however changing our scripts to use the `python3` executable name by default is a minor breaking change we're aiming to introduce in NativeScript 8.3. Until then, this workaround is required to get running.
246
244
247
245
```cli
248
-
brew install pyenv
249
-
pyenv install 2.7.18
250
-
251
-
# set the global python version to 2.7.18
252
-
pyenv global 2.7.18
253
-
254
-
# link the installed python version to be available to XCode
To load and initialize pyenv, add the following lines to your shell profile, usually `~/.bash_profile` or `~/.bashrc`, or if you are using `zsh` then `~/.zshrc`:
259
-
260
-
```bash
261
-
ifcommand -v pyenv 1>/dev/null 2>&1;then
262
-
eval"$(pyenv init --path)"
263
-
eval"$(pyenv init -)"
264
-
fi
246
+
# link and alias the installed python3
247
+
# version to be available to XCode as python
248
+
sudo ln -s $(which python3) /usr/local/bin/python
265
249
```
266
250
267
-
**Note:** Make sure to open a new terminal window for the above changes to take effect!
268
-
269
251
Next, update **<abbrtitle="Python package manager">pip</abbr>** and install **<abbrtitle="Python 2 & 3 compatibility package used by NativeScript">six</abbr>** by running the following:
270
252
271
253
```cli
272
-
pip install --upgrade pip
273
-
python -m pip install six
254
+
python3 -m pip install --upgrade pip
255
+
python3 -m pip install six
274
256
```
275
257
276
258
Now continue to the "Install the **NativeScript CLI** globally" section below.
@@ -284,8 +266,8 @@ sudo easy_install pip==20.3.3
284
266
python -m pip install six
285
267
```
286
268
287
-
:::tip NOTE
288
-
You may see a Deprecation warning when installing **six**, feel free to ignore it for now — NativeScript will update to Python 3.x in the near future.
269
+
:::tip Note
270
+
You may see a Deprecation warning when installing **six**, feel free to ignore it for now — NativeScript will update to Python 3.x in version 8.3.
289
271
:::
290
272
291
273
Install the **NativeScript CLI** globally:
@@ -294,7 +276,7 @@ Install the **NativeScript CLI** globally:
294
276
npm install -g nativescript
295
277
```
296
278
297
-
:::tip NOTE
279
+
:::tip Note
298
280
You may see Deprecation and security warnings from **npm**, these are safe to ignore.
299
281
300
282
_**More details for those curious:** The NativeScript CLI relies on 3rd party packages that may have been deprecated over the past years. We are slowly replacing these dependencies with newer, supported alternatives to resolve these warnings, however they are generally safe to ignore, since the CLI is never exposed to the public and it's only used for local development, where most of the security concerns don't apply._
0 commit comments