Code Monkey home page Code Monkey logo

prompt-git-info's Introduction

Prompt Git Info

Module for Orbital Shell

Add custom text to the prompt of console showing the status of git repositories if the current directory is above a repository folder

.NET last commit releasever releasedate
toplanguage lngcount
codesize reposize

Usage

install into the shell:

> module -i prompt-git-info

disable/enable:

> prompt-info -e false
> prompt-info -e true

Preview

up to date

worktree changed

index changed

ahead

behind

behind + behind message

ahead/behind

ahead/behind + behind message

no repo

Settings

namespace env.com.git.promptInfo

variable type value
isEnabled bool true
isEnabledGetRemoteStatus bool true
runInBackgroundTask bool false
infoBackgroundColor string \e[48;5;237
modifiedTextTemplate string %bgColor%(f=white) %repoName% ├ %branch% %sepSymbol%%errorMessage%\e[48;5;237m+%indexAdded% ~%indexChanges% -%indexDeleted% | ~%worktreeChanges% -%worktreeDeleted% ?%untracked%(rdc
behindTextTemplate string %bgColor%(f=white) %repoName% ├ %branch% %sepSymbol%%errorMessage%\e[48;5;237m+%indexAdded% ~%indexChanges% -%indexDeleted% | ~%worktreeChanges% -%worktreeDeleted% ?%untracked% (b=darkred)↓%behind%%behindMessage%(rdc)
aheadBehindTextTemplate string %bgColor%(f=white) %repoName% ├ %branch% %sepSymbol%%errorMessage%\e[48;5;237m+%indexAdded% ~%indexChanges% -%indexDeleted% | ~%worktreeChanges% -%worktreeDeleted% ?%untracked% \e[48;5;136m↑%ahead%(b=darkred)↓%behind%%behindMessage%(rdc)
aheadTextTemplate string %bgColor%(f=white) %repoName% ├ %branch% %sepSymbol%%errorMessage%\e[48;5;237m+%indexAdded% ~%indexChanges% -%indexDeleted% | ~%worktreeChanges% -%worktreeDeleted% ?%untracked% \e[48;5;136m↑%ahead%(rdc)
noDataTextTemplate string %bgColor%(f=white) %repoName% ├ %branch% %errorMessage%(rdc)
templateNoRepository string (b=darkblue)(f=white) » %errorMessage%(rdc)
behindBackgroundColor string (b=darkred)
aheadBackgroundColor string \e[48;5;136m
upToDateBackgroundColor string \e[48;5;22m
modifiedBackgroundColor string \e[48;5;130m
modifiedUntrackedBackgroundColor string \e[48;5;166m
unknownBackgroundColor string (b=darkblue)

Settings example

change behin background color, for example within user .profile script :

set env.com.git.promptInfo.behindBackgroundColor (b=magenta)

Templates paramters

  • infoColor
  • behindColor
  • aheadColor
  • unknownBackgroundColor
  • bgColor
  • branch
  • errorMessage
  • indexAdded
  • indexChanges
  • indexDeleted
  • worktreeChanges
  • worktreeAdded
  • worktreeDeleted
  • untracked
  • repoName
  • behind
  • ahead
  • sepSymbol
  • behindMessage






Orbital Shell is a multi-plateform (windows, linux, macos, arm) command shell, inspired by bash and POSIX recommendations. It provides any usual bash shell feature (even if modernized) and nice syntaxes and features allowing to interact (get/set/call members) with C# objects. Developed using C# 8, .NET Core 3.1/Net 5 and .NET Standard 2.1

prompt-git-info's People

Contributors

franck-gaspoz avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

franck-gaspoz

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.