-
Notifications
You must be signed in to change notification settings - Fork 11
Creating a Dev Environment
tip: each of these links are a direct link to the download page of the tool
- Visual Studio Code (recommended code editor)
- Pycharm (project supports this editor, but you have to pay for Django template linting)
- vim (you are actually insane if you pick this one)
- neovim (chad text editor)
- Python (we do a little python)
- pipenv (virtual environments)
- git (version control)
- GitHub CLI (github authorization)
- Python (because python)
- Django (django template syntax highlighting)
- GitLens (very good extension in general, everyone should have it)
- Make sure you are logged in to GitHub via GitHub CLI. To do this, run
gh auth login
in a terminal and follow the steps. If you are not logged in, you won't be able to push to your GitHub repos. - You should make sure your IDE/Code Editor supports:
- Python syntax highlighting and linting
- Django template syntax highlighting and linting
- You can open a PowerShell terminal in a directory by pressing shift+right-click and selecting "Open in Powershell terminal" in the right click prompt. This option is not shown when right clicking normally.
- In VSCode, to open an integrated terminal you can press ctrl+shift+`.
- The .vscode and .idea folders contain config helpers for the IDEs: VSCode and IntelliJ IDEA
If you plan on contributing to this project, you should probably make a form of it (fork button on top right hand corner). If you just want to run the server, you can just continue on.
- Open up a terminal then navigate to your preferred directory
- Run
git clone https://github.com/worcestertechnicalhighschool/ratatoskr.git
- Run
cd ./ratatoskr
- Run
code .
to open VSCode in the current directory
- In a terminal, run
pipenv install
-
pipenv shell
(do this every time you want to run the server) cd ./ratatoskr
python manage.py migrate
python manage.py initsocialapp
python manage.py runserver
- Debugging is already configured for VSCode. All you have to do is press the run button on the debug tab.
- If you have another preferred IDE, you can configure debugging yourself.
I would really recommend disabling the Django extension by default mostly due to it hijacking control over all .html
files. You can enable it only for one workspace by clicking the dropdown arrow beside "Enable" and clicking "Enable (workspace).
Also, if you navigate to your settings.json
(ctrl+,, then click on the paper icon on the top right), you can add the following snippet to re-enable Emmet while editing Django templates
"emmet.includeLanguages": {
"django-html": "html"
},
If intellisense is reporting unresolved imports, you have to switch your Python environment to the virtual environment. Do this by clicking the Python version on the bottom left and select the virtual environment.
- Things we use
- Heroku Maintaining
- Creating a dev environment
- Documentation Guidelines
- Calendar Integration Schema