Boiler plates for the creation of Python Project Template.
- Install Python 3
- Install Cookiecutter
pip install cookiecutter
- Create a blank repository (no readme etc) on Github
- Run
cookiecutter https://github.com/marmstr93ng/PythonProjectTemplate.git
filling in the prompted information - Connect the local directory to the git repository
- Inside the local folder run a git bash window
- Run
git init
git remote add origin https://(the cloning URL).git
- Add all file
git add .
- Commit all files with an appropriate comment
git commit -m "feat: added modified boiler plate files"
git push origin master
An inbuilt Python tool that creates an isolated python environment, keeping project dependencies independent from each other.
python -m venv .venv
.\\.venv\\Scripts\\activate
or.\\.venv\\Scripts\\deactivate
[DEPRICATED FOR PYPROJECT.TOML] A file which contains all the python packages used in the project
pip freeze > requirements.txt
- Capture the python requirementspip install -r requirements.txt
- Install all python packages specified in requirements file
How to include a Github repo in the requirements file
<type>: <subject>
<BLANK LINE>
<body>
<BLANK LINE>
<footer>
- The header line is mandatory, while the rest of the message is advisory.
- Any line of the commit message cannot be longer 100 characters! This allows the message to be easier to read on GitHub as well as in various git tools.
- use the imperative, present tense: "change" not "changed" nor "changes"
- feat: a new user feature (inclusion in a release bumps a MINOR version)
- fix: a user bug fixed (inclusion in a release bumps a PATCH version)
- docs: changes to documentation
- style: formatting changes, missing semicolons, etc
- refactor: code change that neither fixes a bug nor adds a feature
- perf: code change that improves performance (inclusion in a release bumps a PATCH version)
- test: adding missing or correcting existing tests
- chore: changes to the build process or auxiliary tools and libraries such as documentation generation
A succinct description of the change.
- don't capitalize first letter
- no dot (.) at the end
The body should include the motivation for the change and contrast this with previous behaviour
The footer should contain any information about breaking changes and is also the place to reference issue numbers from your issue tracker
- Closed bugs should be listed, comma separated, on a separate line at the end of the footer prefixed with "Closes" keyword like this:
Closes #123, #245
Run all the commands in Git Bash
ssh-keygen -t rsa -b 4096 -C "[email protected]"
- On "Enter a file in which to save the key," press Enter. This accepts the default file location.
- At the prompt, type a secure passphrase.
- SSH-Agent is an SSH key manager that stores the SSH key in a process memory so that users can log into SSH servers without having to type the key’s passphrase every time they authenticate with the server
- Ensure ssh-agent is enabled:
eval "$(ssh-agent -s)"
- Add your SSH key to the ssh-agent:
ssh-add ~/.ssh/id_rsa
- Copy the SSH key to your clipboard.
clip < ~/.ssh/id_rsa.pub
- In the top right corner of any page, click your profile photo, then click Settings
- In the user settings sidebar, click SSH keys.
- Click New SSH key.
- Name and add Key
ssh -T [email protected]
- Check if the hash that is shown matches one of the hashes shown in Github SSH Key Fingerprints
- If the following error occurs
The authenticity of host 'github.com (140.82.121.3)' can't be established.
runssh-keyscan github.com >> ~/.ssh/known_hosts
which will add authenticity to your known_hosts.