{"id":24302683,"url":"https://github.com/aadarshlalchandani/aasetpy","last_synced_at":"2025-03-06T14:26:32.960Z","repository":{"id":275938927,"uuid":"922262854","full_name":"aadarshlalchandani/aasetpy","owner":"aadarshlalchandani","description":"Python Project Kickstarter Template.","archived":false,"fork":false,"pushed_at":"2025-03-05T04:55:09.000Z","size":161,"stargazers_count":5,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-05T05:30:26.332Z","etag":null,"topics":["aasetpy","annotations","boilerplate","decorators","docker","docker-compose","environment-variables","linux","python","rest-api","template"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aadarshlalchandani.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-01-25T18:38:18.000Z","updated_at":"2025-03-05T04:55:12.000Z","dependencies_parsed_at":"2025-03-05T05:35:53.645Z","dependency_job_id":null,"html_url":"https://github.com/aadarshlalchandani/aasetpy","commit_stats":null,"previous_names":["aadarshlalchandani/aasetpy"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aadarshlalchandani%2Faasetpy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aadarshlalchandani%2Faasetpy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aadarshlalchandani%2Faasetpy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aadarshlalchandani%2Faasetpy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aadarshlalchandani","download_url":"https://codeload.github.com/aadarshlalchandani/aasetpy/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242225799,"owners_count":20092659,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aasetpy","annotations","boilerplate","decorators","docker","docker-compose","environment-variables","linux","python","rest-api","template"],"created_at":"2025-01-17T00:18:00.148Z","updated_at":"2025-03-06T14:26:32.951Z","avatar_url":"https://github.com/aadarshlalchandani.png","language":"Python","funding_links":["https://www.buymeacoffee.com/aadarshlalchandani","https://img.buymeacoffee.com/button-api/?text=Buy"],"categories":[],"sub_categories":[],"readme":"\u003ca href=\"https://www.buymeacoffee.com/aadarshlalchandani\"\u003e\u003cimg src=\"https://img.buymeacoffee.com/button-api/?text=Buy me a coffee\u0026emoji=☕\u0026slug=aadarshlalchandani\u0026button_colour=5F7FFF\u0026font_colour=ffffff\u0026font_family=Cookie\u0026outline_colour=000000\u0026coffee_colour=FFDD00\" /\u003e\u003c/a\u003e\u0026nbsp;\u0026nbsp;\u0026nbsp;\u003ca href=\"https://www.producthunt.com/posts/aasetpy?embed=true\u0026utm_source=badge-featured\u0026utm_medium=badge\u0026utm_souce=badge-aasetpy\" target=\"_blank\"\u003e\u003cimg src=\"https://api.producthunt.com/widgets/embed-image/v1/featured.svg?post_id=851410\u0026theme=light\u0026t=1738843824699\" alt=\"aasetpy - Python\u0026#0032;Project\u0026#0032;Kickstarter\u0026#0032;Template | Product Hunt\" style=\"width: 250px; height: 54px;\" width=\"250\" height=\"54\" /\u003e\u003c/a\u003e\n\n# `aasetpy`\n\n![aasetpy release (latest by date)](https://img.shields.io/github/v/release/aadarshlalchandani/aasetpy?style=flat-square\u0026color=blue\u0026label=Release)\n![aasetpy downloads](https://img.shields.io/github/downloads/aadarshlalchandani/aasetpy/total?color=success\u0026label=Downloads)\n![License](https://img.shields.io/badge/License-GNU%20GPL%203.0-orange.svg)\n\n## `aasetpy` will create:\n\n- Virtual Environment (`env/`)\n- `.env` file to store environment variables\n- Directory to store Execution Logs (`logs/`)\n- Python Project Skeleton (`src/`)\n- `utils/` module in `src/`\n  \u003e The `utils` module has annotations and environment variables ready to use\n- `requirements.txt` with basic lightweight contents\n  \n  - ```txt\n    coverage\n    pytest\n    pylint\n    requests\n    psutil\n    pydantic\n    pydantic-settings\n    ```\n\n- `.gitignore` with necessary contents\n\n  - ```ini\n    env/\n    venv/\n    *.log\n    *.out\n    __pycache__/\n    .env\n    .venv\n    .vscode\n    test.py\n    ```\n\n- `Dockerfile` as basic containerization of the project\n- `docker.compose.yml` to build and run the docker project\n- `README.md` with the base instructions\n- `main.py` with basic implementation and usage of the src modules\n- `setup.sh` to setup your files in the root directory\n- `run.sh` to run your files in the root directory\n  \u003e `run.sh` will activate the virtual environment and run the program, storing the execution logs to the specified path\n- If used with the `api` flag, it will create the following files:\n  - `rest_api` module\n  - `limits` module for rate limiting\n  - `api.py` file in parent directory to run the uvicorn server\n  - api security file\n  - api logging file\n  - update the `.env` file as per API variables\n- If used with the `caching` flag, it will create the following files:\n  - `server_cache` module\n  - `redis` module\n  - `src/rest_api/api.py` gets updated with caching on endpoints as an example\n  - `local_cache` module decorator similar to that of `redis` module\n  - update the `.env` file as per Caching variables\n- Lastly, it removes nested `__pycache__` directories from the project.\n- [This script](https://gist.github.com/aadarshlalchandani/b737e77a480a70a4755267dd81f82a68#file-setup-sh) is run into your project directory upon running `aasetpy`\n- You can take a look  the files to be created [here](https://github.com/aadarshlalchandani/aasetpy/tree/main/aasetpy-template-files)\n\n## Single command setup in Ubuntu\n\n\u003e This setup requires to be run with `sudo` as it makes changes to the `/etc/bash.bashrc` file.\n\n```bash\nwget https://github.com/aadarshlalchandani/aasetpy/releases/download/v0.1.3/aasetpy.deb  \u003e/dev/null 2\u003e\u00261 \u0026\u0026 sudo apt install ./aasetpy.deb \u0026\u0026 rm aasetpy.deb\n```\n\n\u003cdetails\u003e\n\n\u003csummary\u003e\n\u003ch2 style=\"display: inline;\"\u003e\nManual Setup\n\u003c/h2\u003e\n\u003c/summary\u003e\n\n### Open bashrc file to add command alias\n\n```bash\nsudo nano /etc/bash.bashrc\n```\n\n### Add these lines to the end of file\n\n```bash\n## credits: aadarshlalchandani/aasetpy\nalias aasetpy='rm -rf ~/.wget-hsts \u0026\u0026 wget -q -O - https://gist.github.com/aadarshlalchandani/b737e77a480a70a4755267dd81f82a68/raw | bash -s --'\nalias aaresetpy='rm -rf ~/.wget-hsts \u0026\u0026 wget -q -O - https://gist.github.com/aadarshlalchandani/b737e77a480a70a4755267dd81f82a68/raw | bash -s -- reset'\n```\n\n### Reopen the terminal\n\nYour commands are now ready to be used!\n\n\u003c/details\u003e\n\n# Usage\n\n#### Setup (install/re-install dependencies) your Python Project\n\n```bash\naasetpy\n```\n\n#### Project Template with FastAPI\n\n```bash\naasetpy api\naasetpy caching\naasetpy api caching\n```\n\n#### Reset your Python Project\n\n```bash\naaresetpy\naaresetpy api\naaresetpy api caching\n```\n\nOR\n\n```bash\naasetpy reset\naasetpy reset api\naasetpy reset api caching\n```\n\n\u003e `caching` flag, during initial setup (in presence of `reset` flag), will only work in presence of `api` flag for obvious reasons.  \n\u003e You can call `aasetpy caching` without `api` once you have `rest_api` module in `src/`\n\n# Remove `aasetpy` from ubuntu\n\n```bash\nsudo apt remove aasetpy -y\n```\n\n[Reference](https://askubuntu.com/a/986053)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faadarshlalchandani%2Faasetpy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faadarshlalchandani%2Faasetpy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faadarshlalchandani%2Faasetpy/lists"}