Code Monkey home page Code Monkey logo

premerge's Introduction

Pre-merge Job Runner

This repository contains a single Python script that runs pre-merge jobs on most recently changed files. These jobs encompass formatting, linting, and copyright management for both Python and C++ files.

Installation

To set up the pre-merge job runner, follow these steps:

  1. Add as a Submodule

    You may integrate this as a submodule in your existing repository. Navigate to your project root folder and add premerge using the following command:

    git submodule add https://github.com/wengchenyang1/premerge.git premerge
  2. Run the Setup Script

    bash ./premerge/setup.sh

    The setup.sh script will set up necessary configurations, such as copying template config files for linting and formatting to the root folder (if there are not any).

Usage

Running the Pre-merge Checks

To run the pre-merge checks, execute the following command in your project root directory:

python premerge/pre_merge.py

Note

This setup script and accompanying pre-merge checks are designed for quick implementation and execution of a series of verification tasks in small projects. While it serves well for basic use cases, it may not be the optimal solution for larger projects with more complex requirements.

The single-file structure of this setup may limit its extensibility and scalability. For more extensive projects, consider using more sophisticated tools and frameworks that are specifically designed for larger codebases and more intricate workflows.

TODOs

See issues.

premerge's People

Contributors

wengchenyang1 avatar

Watchers

 avatar

premerge's Issues

Write test

Unit tests for the python functions might be needed.

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.