Skip to main content

Snap Env (https://snapenv.com) Python base module.

Project description

Open in Dev Containers

Snap SAAS Base

Snap Env (https://snapenv.com) Python base module.

Using

Python package: To add and install this package as a dependency of your project, run poetry add snap-saas-base.

Contributing

Prerequisites
1. Set up Git to use SSH
  1. Generate an SSH key and add the SSH key to your GitHub account.
  2. Configure SSH to automatically load your SSH keys:
    cat << EOF >> ~/.ssh/config
    Host *
      AddKeysToAgent yes
      IgnoreUnknown UseKeychain
      UseKeychain yes
    EOF
    
2. Install Docker
  1. Install Docker Desktop.
3. Install VS Code or PyCharm
  1. Install VS Code and VS Code's Dev Containers extension. Alternatively, install PyCharm.
  2. Optional: install a Nerd Font such as FiraCode Nerd Font and configure VS Code or configure PyCharm to use it.
4. Install OpenCommit
  1. Install OpenCommit. Open a new shell window and execute the following commands:
    npm install -g opencommit
    oco config set OCO_OPENAI_API_KEY=sk-N...
    oco config set OCO_MODEL=gpt-4
    oco config set OCO_EMOJI=true
    
5. Install gpt4docstrings (dont install until tool upgrade to use new openai API client)
  1. Install gpt4docstrings. In the directory of the project and with poetry activated, execute the following commands:
    poetry add --group dev gpt4docstrings
    
  2. Optional: Test the command:
    OPENAI_API_KEY=sk-N... gpt4docstrings -w src/api.py
    
    • Check src/snap_saas_base/api.py to see the generated docstring.
6. Install aider
  1. Install aider. In the directory of the project and with poetry activated, execute the following commands:
    poetry add --group dev aider-chat
    
  2. Optional: Test the command:
    OPENAI_API_KEY=sk-N... aider --no-auto-commits 
    
    • After aider is loaded, use /help to see avaiable commands and check [aider project(https://github.com/paul-gauthier/aider) to understand this tool.
7. Install cz-conventional-gitmoji
  1. Install cz-conventional-gitmoji. In the directory of the project and with poetry activated, execute the following commands:
    poetry add --group dev cz-conventional-gitmoji
    
  2. Optional: Test the command:
    cz commit
    
Development environments

The following development environments are supported:

  1. ⭐️ GitHub Codespaces: click on Code and select Create codespace to start a Dev Container with GitHub Codespaces.
  2. ⭐️ Dev Container (with container volume): click on Open in Dev Containers to clone this repository in a container volume and create a Dev Container with VS Code.
  3. Dev Container: clone this repository, open it with VS Code, and run Ctrl/⌘ + + PDev Containers: Reopen in Container.
  4. PyCharm: clone this repository, open it with PyCharm, and configure Docker Compose as a remote interpreter with the dev service.
  5. Terminal: clone this repository, open it with your terminal, and run docker compose up --detach dev to start a Dev Container in the background, and then run docker compose exec dev zsh to open a shell prompt in the Dev Container.
Developing
  • This project follows the Conventional Commits standard to automate Semantic Versioning and Keep A Changelog with Commitizen.
  • Run poe from within the development environment to print a list of Poe the Poet tasks available to run on this project.
  • Run poetry add {package} from within the development environment to install a run time dependency and add it to pyproject.toml and poetry.lock. Add --group test or --group dev to install a CI or development dependency, respectively.
  • Run poetry update from within the development environment to upgrade all dependencies to the latest versions allowed by pyproject.toml.
  • Run cz --name cz_gitmoji commit so commit files using conventional commits with emojis.
  • Run cz --name cz_gitmoji bump --changelog to bump the package's version, update the CHANGELOG.md, and create a git tag.
  • Run git push --tags to push the new tag to github.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

snap_saas_base-0.10.2.tar.gz (12.6 kB view details)

Uploaded Source

Built Distribution

snap_saas_base-0.10.2-py3-none-any.whl (13.1 kB view details)

Uploaded Python 3

File details

Details for the file snap_saas_base-0.10.2.tar.gz.

File metadata

  • Download URL: snap_saas_base-0.10.2.tar.gz
  • Upload date:
  • Size: 12.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.9 Linux/6.5.0-1018-azure

File hashes

Hashes for snap_saas_base-0.10.2.tar.gz
Algorithm Hash digest
SHA256 03c7a7288f72e540ab6b8978dc93864b78226228ccde0fd12ea85331cc3452e1
MD5 7b62b1aa6d5311e484d87fd8ac182b92
BLAKE2b-256 7b8823e6374e6c6742d7062c3f289ecf212e144f824f7ec96157e337105ebaaf

See more details on using hashes here.

File details

Details for the file snap_saas_base-0.10.2-py3-none-any.whl.

File metadata

  • Download URL: snap_saas_base-0.10.2-py3-none-any.whl
  • Upload date:
  • Size: 13.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.9 Linux/6.5.0-1018-azure

File hashes

Hashes for snap_saas_base-0.10.2-py3-none-any.whl
Algorithm Hash digest
SHA256 095176b0118cbe18a6b724474b5716a272085856a582b45710eff70e48b51ca0
MD5 6e611a8dbc17c739f38de5cc2932fd2e
BLAKE2b-256 a6375b38be25532684c2377e2b0ee9af5021519de51ba2a78b778870130fec6d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page