Skip to content

Commit 4863b61

Browse files
committed
Converted python versions to book variable
1 parent 401a13d commit 4863b61

File tree

5 files changed

+14
-14
lines changed

5 files changed

+14
-14
lines changed

en/chromebook_setup/instructions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ Run:
7474
```
7575
mkdir djangogirls
7676
cd djangogirls
77-
python3.6 -mvenv myvenv
77+
python{{ book.py_version }} -mvenv myvenv
7878
source myvenv/bin/activate
7979
pip install django~={{ book.django_version }}
8080
```

en/deploy/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ Deploying a web app on PythonAnywhere involves pulling down your code from GitHu
152152

153153
{% filename %}PythonAnywhere command-line{% endfilename %}
154154
```
155-
$ pip3.6 install --user pythonanywhere
155+
$ pip{{ book.pyaw_version }} install --user pythonanywhere
156156
```
157157

158158
That should print out some things like `Collecting pythonanywhere`, and eventually end with a line saying `Successfully installed (...) pythonanywhere- (...)`.
@@ -161,7 +161,7 @@ Now we run the helper to automatically configure our app from GitHub. Type the f
161161

162162
{% filename %}PythonAnywhere command-line{% endfilename %}
163163
```
164-
$ pa_autoconfigure_django.py --python=3.6 https://github.com/<your-github-username>/my-first-blog.git
164+
$ pa_autoconfigure_django.py --python={{ book.pyaw_version }} https://github.com/<your-github-username>/my-first-blog.git
165165
```
166166

167167
As you watch that running, you'll be able to see what it's doing:

en/django_installation/instructions.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ $ python3 -m venv myvenv
8585
>{% filename %}command-line{% endfilename %}
8686
>```
8787
>$ sudo apt install python-virtualenv
88-
>$ virtualenv --python=python3.6 myvenv
88+
>$ virtualenv --python=python{{ book.py_version }} myvenv
8989
>```
9090
9191
> __NOTE:__ If you get an error like
@@ -99,7 +99,7 @@ $ python3 -m venv myvenv
9999
>
100100
>{% filename %}command-line{% endfilename %}
101101
>```
102-
>sudo apt install python3.6-venv
102+
>sudo apt install python{{ book.py_version }}-venv
103103
>```
104104
105105
<!--endsec-->

en/python_installation/instructions.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@ First check whether your computer is running a 32-bit version or a 64-bit versio
1616

1717
You can download Python for Windows from the website https://www.python.org/downloads/windows/. Click on the "Latest Python 3 Release - Python x.x.x" link. If your computer is running a **64-bit** version of Windows, download the **Windows x86-64 executable installer**. Otherwise, download the **Windows x86 executable installer**. After downloading the installer, you should run it (double-click on it) and follow the instructions there.
1818

19-
One thing to watch out for: During the installation, you will notice a window marked "Setup". Make sure you tick the "Add Python 3.6 to PATH" or 'Add Python to your environment variables" checkbox and click on "Install Now", as shown here (it may look a bit different if you are installing a different version):
19+
One thing to watch out for: During the installation, you will notice a window marked "Setup". Make sure you tick the "Add Python {{ book.py_version }} to PATH" or 'Add Python to your environment variables" checkbox and click on "Install Now", as shown here (it may look a bit different if you are installing a different version):
2020

2121
![Don't forget to add Python to the Path](../python_installation/images/python-installation-options.png)
2222

2323
When the installation completes, you may see a dialog box with a link you can follow to learn more about Python or about the version you installed. Close or cancel that dialog -- you'll be learning more in this tutorial!
2424

25-
Note: if you are using an older version of Windows (7, Vista, or any older version) and the Python 3.6.x installer fails with an error, you can try either:
25+
Note: if you are using an older version of Windows (7, Vista, or any older version) and the Python {{ book.py_version }}.x installer fails with an error, you can try either:
2626
1. install all Windows Updates and try to install Python again; or
2727
2. install an [older version of Python](https://www.python.org/downloads/windows/), e.g., [3.4.6](https://www.python.org/downloads/release/python-346/).
2828

@@ -40,7 +40,7 @@ data-collapse=true ces-->
4040
You need to go to the website https://www.python.org/downloads/release/python-361/ and download the Python installer:
4141

4242
* Download the *Mac OS X 64-bit/32-bit installer* file,
43-
* Double click *python-3.6.1-macosx10.6.pkg* to run the installer.
43+
* Double click *python-{{ book.py_release }}-macosx10.x.pkg* to run the installer.
4444

4545
<!--endsec-->
4646

@@ -52,10 +52,10 @@ It is very likely that you already have Python installed out of the box. To chec
5252
{% filename %}command-line{% endfilename %}
5353
```
5454
$ python3 --version
55-
Python 3.6.1
55+
Python {{ book.py_release }}
5656
```
5757

58-
If you have a different version of Python installed, at least 3.4.0 (e.g. 3.6.0), then you don't have to upgrade. If you don't have Python installed, or if you want a different version, first check what Linux distribution you are using with the following command:
58+
If you have a different version of Python installed, at least 3.4.0 (e.g. {{ book.py_release }}), then you don't have to upgrade. If you don't have Python installed, or if you want a different version, first check what Linux distribution you are using with the following command:
5959

6060
{% filename %}command-line{% endfilename %}
6161
```
@@ -108,11 +108,11 @@ Verify the installation was successful by opening a command prompt and running t
108108
{% filename %}command-line{% endfilename %}
109109
```
110110
$ python3 --version
111-
Python 3.6.1
111+
Python {{ book.py_release }}
112112
```
113-
The version shown may be different from 3.6.1 -- it should match the version you installed.
113+
The version shown may be different from {{ book.py_release }} -- it should match the version you installed.
114114

115-
**NOTE:** If you're on Windows and you get an error message that `python3` wasn't found, try using `python` (without the `3`) and check if it still might be a version of Python that is 3.4.0 or higher. If that doesn't work either, you may open a new command prompt and try again; this happens if you use a command prompt left open from before the Python installation.
115+
**NOTE:** If you're on Windows and you get an error message that `python3` wasn't found, try using `python` (without the `3`) and check if it still might be a version of Python that is 3.4.0 or higher. If that doesn't work either, you may open a new command prompt and try again; this happens if you use a command prompt left open from before the Python installation.
116116

117117
----
118118

en/python_introduction/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ We want to open up a Python console, so type in `python` on Windows or `python3`
1919
{% filename %}command-line{% endfilename %}
2020
```
2121
$ python3
22-
Python 3.6.1 (...)
22+
Python {{ book.py_release }} (...)
2323
Type "help", "copyright", "credits" or "license" for more information.
2424
>>>
2525
```

0 commit comments

Comments
 (0)