Coder Social home page Coder Social logo

fstab50 / branchdiff Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 1.0 40.89 MB

Git version control utility, Illustrates differences between current working branch and master branch

License: MIT License

Makefile 2.15% Shell 58.83% Python 35.90% Dockerfile 3.12%
git version-control code-tools linux developer-tools utilities merge diff command-line command-line-tool

branchdiff's Introduction


branchdiff


About this repository


Contents

--

back to the top


Summary

branchdiff is a utility for use with git version control. The program:

  • Instantly see differences between current working branch and any other branch
  • Access advanced git functionality without any code or typing syntax
  • Graphical view of when commits were made to the current branch, by whom
  • Graphical merge maps

branchdiff default view

back to the top


Supported Linux Distributions

  • Ubuntu 18.04, 20.04, 20.10, 22.04
  • Linux Mint 18, 19, 20, 21
  • Debian variants of Ubuntu / Linux Mint distributions above
  • Redhat 7,8+
  • CentOS 7, 8+

back to the top


Installation


Ubuntu, Linux Mint, Debian variants

The easiest way to install branchdiff is via the Debian-tools repository:

  1. Download the public key:

    $ wget -qO - http://awscloud.center/keys/public.key | sudo apt-key add -
    
  2. Install the repository:

    $ sudo echo "deb [arch=amd64] http://deb.awscloud.center <distribution> main" > \
                 /etc/apt/sources.list.d/debian-tools.list
    

    Where: <distribution> is one of the following:

    • trusty: Ubuntu 14.04, Ubuntu 14.04 based Linux distributions
    • xenial: Ubuntu 16.04, 16.04 based Linux distributions
    • bionic: Ubuntu 18.04, 18.04 based Linux distributions (Linux Mint 19, etc)
    • cosmic: Ubuntu 18.10, 18.10 based Linux distributions
  3. Verify debian-tools repository installation

    $  grep ^ /etc/apt/sources.list /etc/apt/sources.list.d/*
    

    repository-contents

  4. Update and install the package:

    $ sudo apt update  &&  sudo apt install branchdiff
    
  5. Verify Installation. To verify a Debian (.deb) package installation:

    $ apt show branchdiff
    

    apt

back to the top


Redhat, CentOS, Fedora, Amazon Linux

The easiest way to install branchdiff on redhat-based Linux distributions is via the developer-tools package repository:

  1. Download and install the repo definition file

    $ sudo yum install wget
    

    rpm-install1

    $ wget http://awscloud.center/rpm/developer-tools.repo
    
    $ sudo mv developer-tools.repo /etc/yum.repos.d/  &&  sudo chown 0:0 developer-tools.repo
    
  2. Update local repository cache

    $ sudo yum update -y
    
  3. Install branchdiff os package

    $ sudo yum install branchdiff
    

    rpm-install2

    Answer "y":

    rpm-install3

  4. Verify Installation

    $ yum info branchdiff
    

    rpm-install4

back to the top


Upgrading


  1. See if an upgrade is available, update your distribution's package repositories:
$  sudo apt update
  1. Issue a list command to see upgrades. Alternatively, you may issue $ sudo apt upgrade command.
$  apt list branchdiff -a

repo-contents

  1. Upgrade
$  sudo apt upgrade

back to the top


Options

To display the help menu:

    $ branchdiff  --help

branchdiff help

back to the top


Screenshots


Screenshots / Working Branch Status

branchdiff provides the status of working branch of the current git repository in which the cursor is located:

$ cd <git repository root directory>
$ branchdiff

branchdiff1

back to the top


Screenshots / Extended commit history

~/xlines$ branchdiff

branchdiff1

back to the top


Screenshots / Commit Log / history

branchdiff accurately provides the commit age of the working branch where the cursor is located:

$ branchdiff --commit-log history

commitlog-history

back to the top


branchdiff accurately provides the commit age of the working branch where the cursor is located:

Simple repository with minimal branches and merges:

$ branchdiff --commit-log detail

commitlog-history

Git repository with many working branches and complex merge cadence:

$ branchdiff --commit-log detail

commitlog-history

back to the top


Screenshots / Code Diff

When used without a subcommand, the code option (--code) triggers branchdiff to show the lines changed in all files updated in the current working branch compared to the master branch.

$ branchdiff --code

branchdiff-code

back to the top


Screenshots / Code Diff <filename>

Pressing the tab key twice autocompletes the names of all files that received updates in the current working branch.

$ branchdiff --code <tab><tab>

Ansible/deploy_configuration.yml                       Code/core/ec2prices.py
attribute_defs.yml                                     Code/core/__init__.py
cloudformation/dynamodb-table.template.yml             Code/core/parameter_processing.py
cloudformation/serverless-monitor.template.yml         Code/core/_version.py
Code/connectors/dynamodb.py                            Code/index.py
Code/connectors/__init__.py                            Jenkinsfile
Code/connectors/table.py                               Makefile
Code/core/dynamodb.py                                  requirements.txt

A filename can be selected by typing the first few characters:

$ branchdiff --code Code/con... <tab><tab>
$ branchdiff --code Code/connectors/table.py

branchdiff-code

back to the top


Author & Copyright

All works contained herein copyrighted via below author unless work is explicitly noted by an alternate author.

  • Copyright Blake Huber, All Rights Reserved.

back to the top


License

  • Software contained in this repository is licensed under the MIT License. A copy of the license agreement is included with this repository here.

back to the top


Disclaimer

The following code is provided in accordance with the strict legal disclaimer below:

Code is provided "as is". No liability is assumed by either the code's originating author nor this repo's owner for their use at AWS or any other facility. Furthermore, running function code at AWS may incur monetary charges; in some cases, charges may be substantial. Charges are the sole responsibility of the account holder executing code obtained from this library.

Additional terms may be found in the complete License Agreement.

back to the top


branchdiff's People

Contributors

fstab50 avatar

Watchers

 avatar

Forkers

jafahwer

branchdiff's Issues

Add the ability to view details of a single commit

$ branchdiff --commit-log

Allows viewing of the various versions of the commits made to a branch and their respective hexadecimal index numbering as show below (image).

image

Functionality should be added that allows a user to view details of single commit referenced by a hexadecimal index value as follows:

$ branchdiff --commit-log 99abb7a

Output:

image

Fedora Compatibility | missing epel-release

Fedora no longer utilises epel-release extra packages repository; however, epel is not required for Fedora because xclip resides in the main package repositories.

Create a separate rpm for Fedora

  • OR -
    Investigate use of post install script to handle this inconsistency.

OVERALL: epel-release should be eliminated as a requirement for rpm format.

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.