Coder Social home page Coder Social logo

eunseo0u0 / my-little-monorepo-with-pants Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 89 KB

Python monorepo example

License: MIT License

Starlark 10.77% Python 78.42% Dockerfile 4.17% Makefile 6.64%
pantsbuild python build-system docker github-actions black build-tool ruff monorepos linux

my-little-monorepo-with-pants's Introduction

My Little Monorepo with Pants

Python Ruff Black Docformatter Linux MacOS

Welcome to "My Little Monorepo with Pants" - This repository contains an example of a monorepo with Python which utilizes a powerful tool, called Pants. Feel free to explore, experiment, and adapt the practices demonstrated here to meet your specific development needs. Whether you're new to monorepos or Pants, this repository aims to be a valuable resource for enhancing your development workflow. ๐Ÿš€โœจ

Repository Highlights

  • Pants: This repository is built on the Pants build system. It not only utilizes Pants for code execution but also for various tasks like code formatting, linting, and testing. Additionally, Pants is employed for building and pushing container images (with Docker), as well as managing dependencies.

  • Simple API Example: Explore a straightforward CRUD API implemented with FastAPI. This example can be instrumental in understanding Python monorepo concepts.

  • Automated Build: A streamlined continuous integration (CI) and continuous delivery (CD) process is in place, automated through GitHub Actions.

Core Pants Goals

  • run: run an executable or script.
  • test: run tests with Pytest.
  • fmt: autoformat source code.
  • lint: lint source code in check-only mode.
  • check: run MyPy.
  • repl: open a REPL (standard shell or IPython).
  • package: package your code into an asset, e.g. a wheel or a PEX file.
  • publish: how to distribute packages to a repository

Repository Structure

./
โ”œโ”€โ”€ 3rdparty/
โ”‚   โ”œโ”€โ”€ BUILD
โ”‚   โ”œโ”€โ”€ black-requirements.txt
โ”‚   โ”œโ”€โ”€ black.lock
โ”‚   โ”œโ”€โ”€ coverage-py-requirements.txt
โ”‚   โ”œโ”€โ”€ coverage-py.lock
โ”‚   โ”œโ”€โ”€ docformatter-requirements.txt
โ”‚   โ”œโ”€โ”€ docformatter.lock
โ”‚   โ”œโ”€โ”€ pytest-requirements.txt
โ”‚   โ”œโ”€โ”€ pytest.lock
โ”‚   โ”œโ”€โ”€ python-default.lock
โ”‚   โ”œโ”€โ”€ python-requirements.txt
โ”‚   โ”œโ”€โ”€ ruff-requirements.txt
โ”‚   โ””โ”€โ”€ ruff.lock
โ”œโ”€โ”€ BUILD
โ”œโ”€โ”€ LICENSE
โ”œโ”€โ”€ README.md
โ”œโ”€โ”€ pants.ci.toml
โ”œโ”€โ”€ pants.toml
โ”œโ”€โ”€ pyproject.toml
โ”œโ”€โ”€ src/
โ”‚   โ””โ”€โ”€ todos/
โ”‚       โ”œโ”€โ”€ BUILD
โ”‚       โ”œโ”€โ”€ Dockerfile
โ”‚       โ”œโ”€โ”€ Makefile
โ”‚       โ”œโ”€โ”€ README.md
โ”‚       โ”œโ”€โ”€ apps/
โ”‚       โ”‚   โ”œโ”€โ”€ BUILD
โ”‚       โ”‚   โ”œโ”€โ”€ monitor.py
โ”‚       โ”‚   โ””โ”€โ”€ v1/
โ”‚       โ”‚       โ”œโ”€โ”€ BUILD
โ”‚       โ”‚       โ””โ”€โ”€ todos.py
โ”‚       โ”œโ”€โ”€ main.py
โ”‚       โ””โ”€โ”€ models/
โ”‚           โ””โ”€โ”€ v1/
โ”‚               โ”œโ”€โ”€ BUILD
โ”‚               โ””โ”€โ”€ todos.py
โ””โ”€โ”€ tests/
    โ””โ”€โ”€ src/
        โ””โ”€โ”€ todos/
            โ””โ”€โ”€ apps/
                โ”œโ”€โ”€ BUILD
                โ”œโ”€โ”€ monitor_test.py
                โ””โ”€โ”€ v1/
                    โ”œโ”€โ”€ BUILD
                    โ””โ”€โ”€ todos_test.py

References

my-little-monorepo-with-pants's People

Contributors

eunseo0u0 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.