Search
 
SCRIPT & CODE EXAMPLE
 

SHELL

git lines per user

# its stupid long :P. but run this on linux in the root of your project :D
git log --shortstat --pretty="%cE" | sed 's/(.*)@.*/1/' | grep -v "^$" | awk 'BEGIN { line=""; } !/^ / { if (line=="" || !match(line, $0)) {line = $0 "," line }} /^ / { print line " # " $0; line=""}' | sort | sed -E 's/# //;s/ files? changed,//;s/([0-9]+) ([0-9]+ deletion)/1 0 insertions(+), 2/;s/(+)$/(+), 0 deletions(-)/;s/insertions?(+), //;s/ deletions?(-)//' | awk 'BEGIN {name=""; files=0; insertions=0; deletions=0;} {if ($1 != name && name != "") { print name ": " files " files changed, " insertions " insertions(+), " deletions " deletions(-), " insertions-deletions " net"; files=0; insertions=0; deletions=0; name=$1; } name=$1; files+=$2; insertions+=$3; deletions+=$4} END {print name ": " files " files changed, " insertions " insertions(+), " deletions " deletions(-), " insertions-deletions " net";}'
Comment

PREVIOUS NEXT
Code Example
Shell :: pm2 install 
Shell :: instal yay arch linux 
Shell :: install package chart.js 
Shell :: Unable to init server: Could not connect: Connection refused 
Shell :: ping list of ip addresses powershell 
Shell :: redis show all keys 
Shell :: connect ps4 controller to pc linux 
Shell :: linux combine zipped files 
Shell :: direnv 
Shell :: reset one branch onto another 
Shell :: ubuntu unzip zip 
Shell :: install lunar vim 
Shell :: how to find where python modules are installed 
Shell :: bash use cat in sed command 
Shell :: update git 
Shell :: vim save read only file 
Shell :: git command line see log 
Shell :: timeshift install 
Shell :: rejected master fetch first 
Shell :: git delete multiple branch local 
Shell :: Failure while executing; `/bin/launchctl bootstrap gui/501 /Users/singh/Library/LaunchAgents/homebrew.mxcl.httpd.plist` exited with 5. singh@Singhs-Air ~ % sudo apachectl start 
Shell :: create a vpn server linux 
Shell :: count number of lines in git repo 
Shell :: remove unused images docker manually 
Shell :: npm@azure/msal-browser 2.3.0 
Shell :: install zsh 
Shell :: git diff only file names 
Shell :: windows show proxy settings 
Shell :: how to install anydesk on manjaro 
Shell :: installing .deb on kali 
ADD CONTENT
Topic
Content
Source link
Name
7+7 =