Giter Site home page Giter Site logo

coolcat467 / idlealign Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 0.0 104 KB

Idle Align - Emacs Align by Regular Expression as an IDLE Extension

License: GNU General Public License v3.0

Python 99.21% Shell 0.79%
python python3 idle align coolcat467 extension python-idle regex regular-expression regular-expressions tkinter-python

idlealign's Introduction

IDLEAlign

Python IDLE extension to align code by a regular expression

Tests

pre-commit.ci status pre-commit code style: black Ruff

What does this extension do?

This IDLE extension allows you to align a block of code by a regular expression selecting the text you would like to have aligned and then running Format -> Align Selection or Alt+a on default. If space wrap is enabled in the dialog that appears, regular expression match in selected text will have a single space added on both sides. If disabled, this will not happen. This is very helpful for making large blocks of assignment statements pretty or for making comments for your ruff rules in pyproject.toml all match up.

Installation (Without root permissions)

  1. Go to terminal and install with pip install idlealign[user].
  2. Run command idleuserextend; idlealign. You should see the following output: Config should be good! Config should be good!.
  3. Open IDLE, go to Options -> Configure IDLE -> Extensions. If everything went well, alongside ZzDummy there should be and option called idlealign. This is where you can configure if idlealign is enabled or not.

Installation (Legacy, needs root permission)

  1. Go to terminal and install with pip install idlealign.
  2. Run command idlealign. You will likely see a message saying idlealign not in system registered extensions!. Run the command given to add lintcheck to your system's IDLE extension config file.
  3. Again run command idlealign. This time, you should see the following output: Config should be good!.
  4. Open IDLE, go to Options -> Configure IDLE -> Extensions. If everything went well, alongside ZzDummy there should be and option called idlealign. This is where you can configure if idlealign is enabled or not.

idlealign's People

Contributors

coolcat467 avatar pre-commit-ci[bot] avatar

Stargazers

 avatar

Watchers

 avatar  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.