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: css/README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,7 +37,7 @@ CSS is a static file, so in order to customize CSS, we need to first configure s
37
37
38
38
### Configure static files in Django
39
39
40
-
First, we need to create a folder to store our static files in. Go ahead and create a folder called `static` inside your `djangogirls`folder.
40
+
First, we need to create a directory to store our static files in. Go ahead and create a directory called `static` inside your `djangogirls`directory.
41
41
42
42
static
43
43
manage.py
@@ -52,7 +52,7 @@ This way Django will know where to find your static files.
52
52
53
53
## Your first CSS file!
54
54
55
-
Let's create a CSS file now, to add your own style to your web-page. Create a new folder called `css` inside your `static`folder. Then create a new file called `blog.css` inside this `css` directory. Ready?
55
+
Let's create a CSS file now, to add your own style to your web-page. Create a new directory called `css` inside your `static`directory. Then create a new file called `blog.css` inside this `css` directory. Ready?
Copy file name to clipboardExpand all lines: django_installation/README.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ Before we install Django, we'll get you to install an extremely useful tool that
14
14
15
15
So, let's create a **virtual environment** (also called a *virtualenv*). It will isolate your Python/Django setup on a per-project basis, meaning that any changes you make to one website won't affect any others you're also developing. Neat, right?
16
16
17
-
All you need to do is find a folder in which you want to create the `virtualenv`; your home directory, for example. On Windows it might look like `C:\Users\Name\` (where `Name` is the name of your login).
17
+
All you need to do is find a directory in which you want to create the `virtualenv`; your home directory, for example. On Windows it might look like `C:\Users\Name\` (where `Name` is the name of your login).
18
18
19
19
For this tutorial we will be using a new directory `djangogirls` from your home directory:
20
20
@@ -30,7 +30,7 @@ To create a new `virtualenv`, you need to open the console (we told you about th
where `C:\Python34\python` is the folder in which you previously installed Python and `myvenv` is the name of your `virtualenv`. You can use any other name, but stick to lowercase and use no spaces. It is also good idea to keep the name short - you'll be referencing it a lot!
33
+
where `C:\Python34\python` is the drectory in which you previously installed Python and `myvenv` is the name of your `virtualenv`. You can use any other name, but stick to lowercase and use no spaces. It is also good idea to keep the name short - you'll be referencing it a lot!
34
34
35
35
### Linux and OS X
36
36
@@ -51,7 +51,7 @@ Creating a `virtualenv` on both Linux and OS X is as simple as running:
51
51
52
52
## Working with virtualenv
53
53
54
-
The command above will create a folder called `myvenv` that contains our virtual environment (basically bunch of folders and files). All we want to do now is starting it by running:
54
+
The command above will create a directory called `myvenv` that contains our virtual environment (basically bunch of directory and files). All we want to do now is starting it by running:
Copy file name to clipboardExpand all lines: django_models/README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -57,11 +57,11 @@ A model in Django is a special kind of object - it is saved in the `database` (d
57
57
58
58
### Creating an application
59
59
60
-
To keep everything tidy, we will create a separate application inside our project. It is very nice to have everything organized from the very beginning. To create an application we need to run in the console (from `djangogirls`folder where `manage.py` file is) `python manage.py startapp blog`.
60
+
To keep everything tidy, we will create a separate application inside our project. It is very nice to have everything organized from the very beginning. To create an application we need to run in the console (from `djangogirls`directory where `manage.py` file is) `python manage.py startapp blog`.
61
61
62
62
(myvenv) ~/djangogirls$ python manage.py startapp blog
63
63
64
-
You will notice that a new `blog`folder is created and it contains a number of files now. Our folders and files in our project should look like this:
64
+
You will notice that a new `blog`directory is created and it contains a number of files now. Our directories and files in our project should look like this:
Copy file name to clipboardExpand all lines: django_orm/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,7 +18,7 @@ Remember when we talked about including code written in different files? Now is
18
18
from django.shortcuts import render
19
19
from .models import Post
20
20
21
-
Dot after `from` means *current folder* or *current application*. Since `views.py` and `models.py` are in the same directory we can simply use `.` and the name of the file (without `.py`). Then we import the name of the model (`Post`).
21
+
Dot after `from` means *current directory* or *current application*. Since `views.py` and `models.py` are in the same directory we can simply use `.` and the name of the file (without `.py`). Then we import the name of the model (`Post`).
22
22
23
23
But what's next? To take actual blog posts from `Post` model we need something called a `Queryset`.
`django-admin.py` is a script that will create the folders and files for you. You should now have a folder structure which looks like this:
28
+
`django-admin.py` is a script that will create the directories and files for you. You should now have a directory structure which looks like this:
29
29
30
30
manage.py
31
31
│
@@ -66,7 +66,7 @@ This is already set up in this part of your `mysite/settings.py` file:
66
66
}
67
67
}
68
68
69
-
To create a database for our blog, let's run the following in the console: `python manage.py syncdb` (we need to be in a parent `mysite` directory that contains `manage.py` file). If that goes well, you should see something like this:
69
+
To create a database for our blog, let's run the following in the console: `python manage.py syncdb` (we need to be the `djangogirls` directory that contains the`manage.py` file). If that goes well, you should see something like this:
70
70
71
71
(myvenv) ~/djangogirls$ python manage.py syncdb
72
72
Creating tables ...
@@ -95,7 +95,7 @@ It will ask you if you want to create a *superuser* - a user which has control o
95
95
96
96
And we're done! Time to start the web server and see if our website is working!
97
97
98
-
You need to be in the folder that contains the `manage.py` file (the `mysite` folder). In the console, we can start the web server by running `python manage.py runserver`:
98
+
You need to be in the directory that contains the `manage.py` file (the `djangogirls` directory). In the console, we can start the web server by running `python manage.py runserver`:
Copy file name to clipboardExpand all lines: extend_your_application/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -30,7 +30,7 @@ We want to have a link to a post detail page on the post's title. Let's change `
30
30
31
31
Time to explain the mysterious `{% url 'blog.views.post_detail' pk=post.pk %}`. As you suspect `{% %}` notation means that we are using Django template tags. This time we will use one that will create a URL for us!
32
32
33
-
`blog.views.post_detail` is a path to a `post_detail`*view* we want to create. Please note: `blog` is the name of our application (in folder `blog`), `views` is from the name of the `views.py` file and the last bit: `post_detail` is the name of the *view*.
33
+
`blog.views.post_detail` is a path to a `post_detail`*view* we want to create. Please note: `blog` is the name of our application (in the directory `djangogirls`), `views` is from the name of the `views.py` file and the last bit: `post_detail` is the name of the *view*.
Copy file name to clipboardExpand all lines: html/README.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,15 +16,15 @@ HTML stands for "HyperText Markup Language." __HyperText__ means it's a type of
16
16
17
17
Creating a template means creating a template file. Everything is a file, right? You have probably noticed this already.
18
18
19
-
Templates are saved in `blog/templates/blog`folder. So first create a folder called `templates` inside your blog folder. Then create another folder called `blog` inside your templates folder:
19
+
Templates are saved in `blog/templates/blog`directory. So first create a directory called `templates` inside your blog directory. Then create another directory called `blog` inside your templates directory:
20
20
21
21
blog
22
22
└───templates
23
23
└───blog
24
24
25
-
(You might wonder why we need two folders both called `blog` - as you will discover later, this is simply a useful naming convention that makes life easier when things start to get more complicated.)
25
+
(You might wonder why we need two directories both called `blog` - as you will discover later, this is simply a useful naming convention that makes life easier when things start to get more complicated.)
26
26
27
-
And now create a `post_list.html` file (just leave it blank for now) inside the `blog/templates/blog`folder.
27
+
And now create a `post_list.html` file (just leave it blank for now) inside the `blog/templates/blog`directory.
28
28
29
29
See how your website looks now: http://127.0.0.1:8000/
| mkdir | mkdir | create a new folder|**mkdir testfolder**|
18
-
|del | rm | delete a folder/file | **del c:\test\test.txt**
17
+
| mkdir | mkdir | create a new directory|**mkdir testdirectory**|
18
+
|del | rm | delete a directory/file | **del c:\test\test.txt**
19
19
For more about the above commands, check out the Further Information section below.
20
20
21
21
These are just a very few of the possible black window commands.
@@ -26,7 +26,7 @@ These are just a very few of the possible black window commands.
26
26
* Up arrow - rerun previous commands. You can avoid typing the same commands again by using the up arrow key to rerun recently used commands.
27
27
28
28
29
-
* Tab key - the tab key will autocomplete folder and file names. For example, typing **dir t ** + Tab will autocomplete to all directories starting with t in the current directory (such as task, test, tutorial).
29
+
* Tab key - the tab key will autocomplete directory and file names. For example, typing **dir t ** + Tab will autocomplete to all directories starting with t in the current directory (such as task, test, tutorial).
30
30
31
31
32
32
## Further information about the commands above
@@ -38,7 +38,7 @@ These are just a very few of the possible black window commands.
38
38
For example if you are in a directory called c:\test, and there were three directories in that the test directory called A, B, and C, you could just type **cd A** and press enter. You would then be in the c:\test\A.
39
39
40
40
41
-
* The **cd ..** command - this will take you to the next folder up.
41
+
* The **cd ..** command - this will take you to the next directory up.
42
42
43
43
44
44
* The **dir** (Windows) and **ls** (others) command - this will list the files and directories contained in your current directory. If I typed **dir \test** or **ls test** I would see the contents of the c:\test directory.
@@ -52,7 +52,7 @@ Also note for many commands you can use the \* symbol which stands for wildcard.
52
52
* The **move** (Windows) or **mv** (others) command - this allows you to move files from one location to another. The syntax you use is the same as for the **copy** command.
53
53
54
54
55
-
* The **mkdir** command - this allows you to create a new directory. For example **mkdir temp** creates a new folder called temp in the current directory.
55
+
* The **mkdir** command - this allows you to create a new directory. For example **mkdir temp** creates a new directory called temp in the current directory.
56
56
57
57
58
58
* The **del** (Windows) or **rm** command (others) - this allows you to delete the specified file. For example, **del test.txt** deletes the test.txt file from the current directory.
Copy file name to clipboardExpand all lines: optional_postgresql_installation/README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -18,7 +18,7 @@ Choose the newest version available for your operating system. Download the inst
18
18
19
19
The easiest way is to download the free [Postgres.app](http://postgresapp.com/) and install it like any other application on your operating system.
20
20
21
-
Download it, drag to the Applications folder and run by double clicking. That's it!
21
+
Download it, drag to the Applications directory and run by double clicking. That's it!
22
22
23
23
You'll also have to add the Postgres command line tools to your `PATH` variable, what is described [here](http://postgresapp.com/documentation/cli-tools.html).
0 commit comments