Git Product home page Git Product logo

patchcmd's Introduction

Patch command

A Thunderbird add-on to generate command lines to send patches

You have to send a lot of patches to mailing list with the git send-email command line utility, but are tired of manually picking email addresses and email IDs to paste them in your command line? This Thuderbird add-on has been made just to address your needs. From a given email in Thuderbird, it generates the whole command line to answer to this email and selects it; all you need to do is to copy/paste this single line into your terminal to send your patch.

Oh, well, technically you still have to add the name of the patch you want to send… but the --to= and --cc= and --in-reply-to= should all be handled for you.

Installation

Please see Mozilla's instructions to install the add-on locally or to package it into a .xpi file.

Under UNIX-like systems you can create the .xpi file by simply running:

cd /path/to/PatchCmd/
make

Usage

Once installed, go to Thunderbird and select an email, and go to the email pane (the one in which the body of the email is displayed). You have Reply and Reply All/Reply List and Forward and Archive, Junk buttons and so on at the top of the pane, on the header box. The last of those buttons labeled More ⏷. It opens a drop-down menu if you click on it. Do so: there is now a new item entitled Generate patch command. This is it! Click on it, and a pop-up window will show you the generated command line, already selected for you to copy.

Note that the text box is editable, so that you can edit the command before you copy it.

Screenshots

The new command:

New command.

The pop-up:

Pop-up.

Disclaimers

Regarding security

Always be extremely careful with what you copy and paste into your terminal. People have shown many times that it is possible to hide rogue code. You have no reason to believe me, after all.

Also, it could be that some input coming from the headers will break the commands. The add-on encloses it with single quotes, and tries to escape single quotes coming from the input, but there might be some subtleties I forgot to deal with. Just be cautious, and check for correctness of the command.

Regarding responsibility

Be cautious before you validate your command line: read and proofread whatever command you enter. The add-on provide the commands as a best effort, but is not error prone. I will not be responsible if you send trash to a public mailing list, or if you send emails to the wrong people. So again: verify that everything looks fine before sending the email.

Also see the License section below.

License

Public domain. No warranty of any kind. See LICENSE. Because do whatever you want with this code.

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.