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

Restructure tutorial to separate instructions based on operating system #1796

Open
wants to merge 20 commits into
base: restructure-tutorial
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
564152a
Switch to actions/deploy-pages
ekohl Apr 6, 2023
39b7faa
Merge pull request #1791 from ekohl/remove-need-for-gh-pages-branch
amakarudze Apr 19, 2023
00446f4
Split setup instructions and summary
amakarudze Apr 19, 2023
ab0d913
Restructure content by OS, refactor installation steps
amakarudze Apr 21, 2023
fdbbb86
Remove unnecessary files from Chromebook folder
amakarudze Apr 21, 2023
91ee4c3
Fix Python installation and introduction sections
amakarudze Apr 21, 2023
db9e969
Fix django installation instructions
amakarudze Apr 21, 2023
efe896a
Restruture content up to Python introduction
amakarudze Apr 27, 2023
8fc2734
Refactor deploy folder, delete reduntant folders
amakarudze Apr 28, 2023
5368e73
Fix line breaks at 80 for chromebook/README.md
amakarudze Jun 1, 2023
11488b4
Fix lines for chromebook/django_start_project/README.md
amakarudze Jun 1, 2023
0c3e2d7
Fix line length for macosx/django_start_project/README.md
amakarudze Jun 1, 2023
808a0fd
Fix runcode file line length
amakarudze Jun 1, 2023
b3f114c
Fix line length for windows and runcode
amakarudze Jun 19, 2023
7bd90b9
Fix lines for code editor folder
amakarudze Jun 19, 2023
dcde212
Fix line length for more files
amakarudze Jun 19, 2023
3dd54d8
Fix link for runcode django_start_project
amakarudze Jun 19, 2023
213850f
Fix navigation issues, refactor SUMMARY.md
amakarudze Jun 29, 2023
cf28896
fix: relative image paths in specific os folders
jwhhh Oct 5, 2023
19ba762
Merge pull request #1 from jwhhh/change-structure-1792
amakarudze Nov 25, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 30 additions & 10 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,27 +1,47 @@
---

Choose a reason for hiding this comment

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

Do we need to do those changes with this PR? 🤔
Otherwise, I would do them separately, just so we can make it slightly smaller 😅

name: Build and Deploy

on:
push:
branches:
- master

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: "pages"
cancel-in-progress: true

jobs:
build-and-deploy:
build:
runs-on: ubuntu-latest
if: github.repository == 'djangogirls/tutorial'
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
persist-credentials: false

- name: Install and Build
run: |
npm install
npx honkit build

- name: Deploy
uses: JamesIves/github-pages-deploy-action@releases/v3
- name: Upload artifact
uses: actions/upload-pages-artifact@v1
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
BRANCH: gh-pages
FOLDER: _book
path: _book

deploy:
needs: build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2
82 changes: 68 additions & 14 deletions en/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,82 @@

* [Introduction](README.md)
* [Installation](installation/README.md)
* [Installation (RunCode Cloud)](cloud_development_setup/README.md)
* [Installation (Chromebook)](chromebook_setup/README.md)
* [Installation (OS X/Windows/Linux)](installation/README.md#osx-windows-linux)
* [Command Line](installation/README.md#intro-command-line)
* [Python](installation/README.md#python)
* [Code Editor](installation/README.md#code-editor)
* [Virtual Environment](installation/README.md#virtualenv)
* [Django](installation/README.md#django)
* [Git](installation/README.md#git)
* [GitHub](installation/README.md#github-account)
* [PythonAnywhere](installation/README.md#pythonanywhere-account)
* [RunCode Cloud Installation](runcode/README.md)
* [GitHub](runcode/README.md#github)
* [RunCode](runcode/README.md#runcode)
* [Visual Studio Code](runcode/README.md#visual-studio-runcode)
* [PythonAnywhere](runcode/README.md#pythonanywhere)
* [Command Line](runcode/README.md#command-line)
* [Django](runcode/README.md#django)
* [ChromeBook Installation](chromebook/README.md)
* [Cloud IDE](chromebook/README.md#cloud-ide)
* [PaizaCloud Cloud IDE](chromebook/README.md#paizacloud-cloud-ide)
* [AWS Cloud9](chromebook/README.md#aws-cloud9)
* [Glitch.com Cloud IDE](chromebook/README.md#glitch-cloud-ide)
* [Virtual Environment](chromebook/README.md#virtual-environment)
* [GitHub](chromebook/README.md#github)
* [Linux Installation](linux/README.md)
* [Command Line](linux/README.md#intro-command-line)
* [Python](linux/README.md#python)
* [Code Editor](linux/README.md#code-editor)
* [Virtual Environment](linux/README.md#virtualenv)
* [Django](linux/README.md#django)
* [Git](linux/README.md#git)
* [GitHub](linux/README.md#github-account)
* [Mac OSX Installation](macosx/README.md)
* [Command Line](macosx/README.md#intro-command-line)
* [Python](macosx/README.md#python)
* [Code Editor](macosx/README.md#code-editor)
* [Virtual Environment](macosx/README.md#virtualenv)
* [Django](macosx/README.md#django)
* [Git](macosx/README.md#git)
* [GitHub](macosx/README.md#github-account)
* [PythonAnywhere](macosx/README.md#pythonanywhere)
* [Windows Installation](windows/README.md)
* [Command Line](windows/README.md#intro-command-line)
* [Python](windows/README.md#python)
* [Code Editor](windows/README.md#code-editor)
* [Virtual Environment](windows/README.md#virtualenv)
* [Django](windows/README.md#django)
* [Git](windows/README.md#git)
* [GitHub](windows/README.md#github-account)
* [PythonAnywhere](windows/README.md#pythonanywhere-account)
* [How the Internet works](how_the_internet_works/README.md)
* [Introduction to command line](intro_to_command_line/README.md)
* [Python installation](python_installation/README.md)
* [Code editor](code_editor/README.md)
* [RunCode- Introduction to command line](runcode/intro_to_command_line/README.md)
* [ChromeBook/Linux- Introduction to command line](linux/intro_to_command_line/README.md)
* [Mac OSX - Introduction to command line](macosx/intro_to_command_line/README.md)
* [Windows - Introduction to command line](windows/intro_to_command_line/README.md)
* [Python Installation](python_installation/README.md)
* [ChromeBook/Linux - Python installation](linux/python_installation/README.md)
* [Mac OSX - Python installation](macosx/python_installation/README.md)
* [Windows - Python installation](windows/python_installation/README.md)
* [Introduction to Python](python_introduction/README.md)
* [RunCode - Introduction to Python](runcode/python_introduction/README.md)
* [Linux - Introduction to Python](linux/python_introduction/README.md)
* [Mac OSX - Introduction to Python](macosx/python_introduction/README.md)
* [Windows - Introduction to Python](windows/python_introduction/README.md)
* [Code editor](code_editor/README.md)
* [What is Django?](django/README.md)
* [Django installation](django_installation/README.md)
* [Django Installation](django_installation/README.md)
* [RunCode - Django installation](runcode/django_installation/README.md)
* [ChromeBook - Django installation](chromebook/README.md#glitch-cloud-ide)

Choose a reason for hiding this comment

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

Here it points to the section, not README.MD, is it supposed to be?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The Chromebook links have always been like that, pointing to a section in a README.md and not the README.md itself because they are in one file, though different applications are being installed. It's not a change I am introducing, and changing those links would introduce a new change. That's why I left them like that.

* [Linux - Django installation](linux/django_installation/README.md)
* [Mac OSX - Django installation](macosx/django_installation/README.md)
* [Windows - Django installation](windows/django_installation/README.md)
* [Your first Django project!](django_start_project/README.md)
* [RunCode - Your first Django project!](runcode/django_start_project/README.md)
* [ChromeBook - Your first Django project!](chromebook/django_start_project/README.md)
* [Linux - Your first Django project!](linux/django_start_project/README.md)
* [Mac OSX - Your first Django project!](macosx/django_start_project/README.md)
* [Windows - Your first Django project!](windows/django_start_project/README.md)
* [Django models](django_models/README.md)
* [Django admin](django_admin/README.md)
* [Deploy!](deploy/README.md)
* [RunCode - Deploy!](runcode/deploy/README.md)
* [Linux - Deploy!](linux/deploy/README.md)
* [Mac OSX - Deploy!](macosx/deploy/README.md)
* [Windows - Deploy!](windows/deploy/README.md)
* [Django URLs](django_urls/README.md)
* [Django views – time to create!](django_views/README.md)
* [Introduction to HTML](html/README.md)
Expand Down
101 changes: 68 additions & 33 deletions en/chromebook_setup/instructions.md → en/chromebook/README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,30 @@
You can [skip right over this section](http://tutorial.djangogirls.org/en/installation/#install-python) if you're not using a Chromebook. If you
are, your installation experience will be a little different. You can ignore the
rest of the installation instructions.
# Chromebook setup

### Cloud IDE (PaizaCloud Cloud IDE, AWS Cloud9, Glitch.com)
> **Note** If you already worked through the installation steps, no need to do this again – you can skip
straight ahead to [How the Internet works](../how_the_internet_works/README.md).

Cloud IDE is a tool that gives you a code editor and access to a computer running
on the Internet where you can install, write, and run the software. For the duration
of the tutorial, cloud IDE will act as your _local machine_. You'll still be
running commands in a terminal interface just like your classmates on OS X,
Ubuntu, or Windows, but your terminal will be connected to a computer running
# Installation
In this tutorial you will be building a blog. In order to do that, as you go through the tutorial you'll be instructed on how to
set up some online accounts as needed for your ChromeBook. This page gathers all of the sign-up instructions in one place
(which is useful for some workshop formats).

Since you're working on a ChromeBook, your installation experience is going to be a little different. With a Chromebook, you only
need to create some online accounts.

Follow the steps below to create the necessary accounts.

### Cloud IDE (PaizaCloud Cloud IDE, AWS Cloud9, Glitch.com) {#cloud-ide}

Cloud IDE is a tool that gives you a code editor and access to a computer running
on the Internet where you can install, write, and run the software. For the duration
of the tutorial, cloud IDE will act as your _local machine_. You'll still be
running commands in a terminal interface just like your classmates on OS X,
Ubuntu, or Windows, but your terminal will be connected to a computer running
somewhere else that cloud IDE sets up for you.
Here are the instructions for cloud IDEs (PaizaCloud Cloud IDE, AWS Cloud9, Glitch.com).
You can choose one of the cloud IDEs, and follow the instruction of the cloud IDE.

#### PaizaCloud Cloud IDE
#### PaizaCloud Cloud IDE {#paizacloud-cloud-ide}

1. Go to [PaizaCloud Cloud IDE](https://paiza.cloud/)
2. Sign up for an account
Expand All @@ -31,14 +42,14 @@ $
The terminal on the PaizaCloud Cloud IDE is prepared for your instructions.
You can resize or maximize that window to make it a bit bigger.

#### AWS Cloud9
Currently Cloud 9 requires you to sign up with AWS and enter credit card
#### AWS Cloud9 {#aws-cloud9}
Currently Cloud 9 requires you to sign up with AWS and enter credit card
information.

1. Install Cloud 9 from the [Chrome web store](https://chrome.google.com/webstore/detail/cloud9/nbdmccoknlfggadpfkmcpnamfnbkmkcp)
2. Go to [c9.io](https://c9.io) and click _Get started with AWS Cloud9_
3. Sign up for an AWS account (requires credit card information, but you can
use it for free)
use it for free)
4. In the AWS Dashboard, enter _Cloud9_ in the search bar and click it
5. In the Cloud 9 dashboard, click _Create environment_
6. Name it _django-girls_
Expand All @@ -57,16 +68,16 @@ text, and a small window at the bottom that looks something like this:
yourusername:~/workspace $
```

This bottom area is your terminal. You can use the terminal to send instructions
to the remote Cloud 9 computer. You can resize that window to make it a bit
bigger.
This bottom area is your terminal. You can use the terminal to send instructions to the remote Cloud 9 computer.
You can resize that window to make it a bit bigger.

#### Glitch.com Cloud IDE
#### Glitch.com Cloud IDE {#glitch-cloud-ide}

1. Go to [Glitch.com](https://glitch.com/)
2. Sign up for an account (https://glitch.com/signup) or use your GitHub account if you have one. (See GitHub instructions below.)
3. Click _New Project_ and choose _hello-webpage_
4. Click on the Tools dropdown list (at the bottom left side of the window), then on Terminal button to open terminal tab with a prompt like this:
4. Click on the Tools dropdown list (at the bottom left side of the window), then on Terminal button to open terminal tab with a
prompt like this:

{% filename %}Terminal{% endfilename %}
```
Expand Down Expand Up @@ -140,17 +151,20 @@ LOGGING = {
},
}
```
This will create a `debug.log` file detailing Django operations and any error messages that might come up, making it much easier to fix if your website does not work.
This will create a `debug.log` file detailing Django operations and any error messages that might come up, making it much easier
to fix if your website does not work.

The initial restarting of the Glitch project should fail.
(If you click on the top dropdown button `Show` then click on `In a New Window`, you will receive a `DisallowedHost` error message.)
Do not worry about it at this stage, the tutorial will fix this as soon as you update the Django settings of your project in the `mysite/settings.py` file.
(If you click on the top dropdown button `Show` then click on `In a New Window`, you will receive a `DisallowedHost`error
message.)
Do not worry about it at this stage, the tutorial will fix this as soon as you update the Django settings of your project in the
`mysite/settings.py` file.

### Virtual Environment
### Virtual Environment {#virtual-environment}

A virtual environment (also called a virtualenv) is like a private box we can
stuff useful computer code into for a project we're working on. We use them to
keep the various bits of code we want for our various projects separate so
A virtual environment (also called a virtualenv) is like a private box we can
stuff useful computer code into for a project we're working on. We use them to
keep the various bits of code we want for our various projects separate so
things don't get mixed up between projects.

Run:
Expand All @@ -166,22 +180,43 @@ pip install django~={{ book.django_version }}

(note that on the last line we use a tilde followed by an equal sign: `~=`).

### GitHub
### GitHub {#github}

Make a [GitHub](https://github.com) account.

### PythonAnywhere
### PythonAnywhere {#pythonanywhere}

The Django Girls tutorial includes a section on what is called Deployment,
which is the process of taking the code that powers your new web application
and moving it to a publicly accessible computer (called a server) so other
The Django Girls tutorial includes a section on what is called Deployment,
which is the process of taking the code that powers your new web application
and moving it to a publicly accessible computer (called a server) so other
people can see your work.

This part is a little odd when doing the tutorial on a Chromebook since we're
This part is a little odd when doing the tutorial on a Chromebook since we're
already using a computer that is on the Internet (as opposed to, say, a laptop).
However, it's still useful, as we can think of our Cloud 9 workspace as a place
for our "in progress" work and Python Anywhere as a place to show off our stuff
However, it's still useful, as we can think of our Cloud 9 workspace as a place
for our "in progress" work and Python Anywhere as a place to show off our stuff
as it becomes more complete.

Thus, sign up for a new Python Anywhere account at
[www.pythonanywhere.com](https://www.pythonanywhere.com).

{% include "/deploy/signup_pythonanywhere.md" %}

# Start reading

Congratulations, you are all set up and ready to go!If you still have some time before the workshop, it would be useful to start reading a
few of the beginning chapters:

* [How the internet works](../how_the_internet_works/README.md)

* [Introduction to the command line](../linux/intro_to_command_line/README.md)

* [Introduction to Python](../linux/python_introduction/README.md)

* [What is Django?](../django/README.md)


# Enjoy the workshop!

When you begin the workshop, you'll be able to go straight to [Your first Django project!](../linux/django_start_project/README.md) because you
already covered the material in the earlier chapters.
Loading