mirror of
https://github.com/git-quick-stats/git-quick-stats.git
synced 2025-12-16 12:00:12 +01:00
Compare commits
126 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
22f1b3563d | ||
|
|
628b31ffd8 | ||
|
|
1e5723d7a2 | ||
|
|
0c1749a560 | ||
|
|
ecab54c630 | ||
|
|
7219205696 | ||
|
|
dd3c97816e | ||
|
|
d2b273eead | ||
|
|
5b08bb0b52 | ||
|
|
08d1a5a6e3 | ||
|
|
f5c2b82f02 | ||
|
|
bf29c19cf5 | ||
|
|
c6cb74a5e0 | ||
|
|
3f0befcd07 | ||
|
|
292876846d | ||
|
|
e70c288225 | ||
|
|
4d2621b084 | ||
|
|
2318d42765 | ||
|
|
ef74d79102 | ||
|
|
82f8690285 | ||
|
|
0f641ea0e6 | ||
|
|
6c7bd4fddf | ||
|
|
9f9617b88b | ||
|
|
8cea653d6c | ||
|
|
efa004122e | ||
|
|
0534327006 | ||
|
|
a113dc306f | ||
|
|
0fc2fe956b | ||
|
|
1efe3133dc | ||
|
|
3fd0ee2453 | ||
|
|
a4f19c9e54 | ||
|
|
cd38c40fe8 | ||
|
|
3283122a38 | ||
|
|
920b95c042 | ||
|
|
810ffcff54 | ||
|
|
f9df7ee5e2 | ||
|
|
e31fc931c8 | ||
|
|
0655814800 | ||
|
|
1eb8c53f09 | ||
|
|
3b2f26e85d | ||
|
|
93aa829eae | ||
|
|
1a11540b67 | ||
|
|
6692ec8aa3 | ||
|
|
63eba9f1b8 | ||
|
|
228e67f879 | ||
|
|
891e2277ad | ||
|
|
cc87b3046f | ||
|
|
7aea224e21 | ||
|
|
c37492bb4c | ||
|
|
c258e34afe | ||
|
|
9e18cf35d4 | ||
|
|
24ae67ae57 | ||
|
|
ed0e3cbb6b | ||
|
|
46a771138e | ||
|
|
9f54b87ed5 | ||
|
|
246076f5f6 | ||
|
|
c0a1795c1a | ||
|
|
63b9b42034 | ||
|
|
90f9e359c3 | ||
|
|
82ba58e01d | ||
|
|
5b64a8de17 | ||
|
|
b77021c545 | ||
|
|
62458b6fd1 | ||
|
|
ad5b503eea | ||
|
|
96b5dab53f | ||
|
|
85b7fb1cdf | ||
|
|
151b260be1 | ||
|
|
f06b7f4833 | ||
|
|
bf7533afa7 | ||
|
|
27edcf0f7a | ||
|
|
dc72babb20 | ||
|
|
c8ad2fba84 | ||
|
|
5cf8feee53 | ||
|
|
17fc8f326c | ||
|
|
d5c17e43c0 | ||
|
|
75c8bdc0de | ||
|
|
1a9be34f4c | ||
|
|
4979eaa69f | ||
|
|
1ed838f532 | ||
|
|
0fd9171e11 | ||
|
|
b14f364b6a | ||
|
|
10ad00bcbb | ||
|
|
539f49bb68 | ||
|
|
10bc3106f6 | ||
|
|
7160e3c39d | ||
|
|
f17cbd0ff7 | ||
|
|
a3cd429850 | ||
|
|
e069deaf8a | ||
|
|
b1285b828e | ||
|
|
c11bce17bd | ||
|
|
5f0bc1c7cf | ||
|
|
5f71b785ac | ||
|
|
cdb3f20790 | ||
|
|
dd69477293 | ||
|
|
4aef465e6b | ||
|
|
81fce5cadf | ||
|
|
f3931eb1a3 | ||
|
|
bdfe3beb25 | ||
|
|
90d118f09f | ||
|
|
d12c1c6c4f | ||
|
|
1282e4b46f | ||
|
|
96de74cf4f | ||
|
|
096fd86324 | ||
|
|
dd6a23568e | ||
|
|
48c062f8fa | ||
|
|
c3194f77e3 | ||
|
|
52f4eff27c | ||
|
|
c7d456465e | ||
|
|
e9f085f20e | ||
|
|
625ec404bc | ||
|
|
e6ffee5850 | ||
|
|
2422a010c6 | ||
|
|
749367701d | ||
|
|
3d86fa9664 | ||
|
|
a6a65faa8d | ||
|
|
0cc67fd4ac | ||
|
|
3344a05237 | ||
|
|
da78123ca8 | ||
|
|
ad50a915b0 | ||
|
|
88f970632f | ||
|
|
7f3220abb7 | ||
|
|
7a9e9c7f85 | ||
|
|
190ae631e5 | ||
|
|
94ea505dbd | ||
|
|
601986fbe1 | ||
|
|
01f60821ea |
6
.github/FUNDING.yml
vendored
Normal file
6
.github/FUNDING.yml
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
# These are supported funding model platforms
|
||||||
|
|
||||||
|
github: [arzzen]
|
||||||
|
open_collective: git-quick-stats
|
||||||
|
ko_fi: lukasmestan
|
||||||
|
custom: ['https://lukasmestan.com/thanks/']
|
||||||
38
.github/ISSUE_TEMPLATE/bug_report.md
vendored
Normal file
38
.github/ISSUE_TEMPLATE/bug_report.md
vendored
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
---
|
||||||
|
name: Bug report
|
||||||
|
about: Create a report to help us improve
|
||||||
|
title: ''
|
||||||
|
labels: ''
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Describe the bug**
|
||||||
|
A clear and concise description of what the bug is.
|
||||||
|
|
||||||
|
**To Reproduce**
|
||||||
|
Steps to reproduce the behavior:
|
||||||
|
1. Go to '...'
|
||||||
|
2. Click on '....'
|
||||||
|
3. Scroll down to '....'
|
||||||
|
4. See error
|
||||||
|
|
||||||
|
**Expected behavior**
|
||||||
|
A clear and concise description of what you expected to happen.
|
||||||
|
|
||||||
|
**Screenshots**
|
||||||
|
If applicable, add screenshots to help explain your problem.
|
||||||
|
|
||||||
|
**Desktop (please complete the following information):**
|
||||||
|
- OS: [e.g. iOS]
|
||||||
|
- Browser [e.g. chrome, safari]
|
||||||
|
- Version [e.g. 22]
|
||||||
|
|
||||||
|
**Smartphone (please complete the following information):**
|
||||||
|
- Device: [e.g. iPhone6]
|
||||||
|
- OS: [e.g. iOS8.1]
|
||||||
|
- Browser [e.g. stock browser, safari]
|
||||||
|
- Version [e.g. 22]
|
||||||
|
|
||||||
|
**Additional context**
|
||||||
|
Add any other context about the problem here.
|
||||||
20
.github/ISSUE_TEMPLATE/feature_request.md
vendored
Normal file
20
.github/ISSUE_TEMPLATE/feature_request.md
vendored
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
---
|
||||||
|
name: Feature request
|
||||||
|
about: Suggest an idea for this project
|
||||||
|
title: ''
|
||||||
|
labels: ''
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Is your feature request related to a problem? Please describe.**
|
||||||
|
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||||
|
|
||||||
|
**Describe the solution you'd like**
|
||||||
|
A clear and concise description of what you want to happen.
|
||||||
|
|
||||||
|
**Describe alternatives you've considered**
|
||||||
|
A clear and concise description of any alternative solutions or features you've considered.
|
||||||
|
|
||||||
|
**Additional context**
|
||||||
|
Add any other context or screenshots about the feature request here.
|
||||||
10
.gitignore
vendored
Normal file
10
.gitignore
vendored
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
*.json
|
||||||
|
*.db
|
||||||
|
.DS_Store*
|
||||||
|
._*
|
||||||
|
.*.swp
|
||||||
|
.*.swo
|
||||||
|
.Spotlight*
|
||||||
|
.Trash*
|
||||||
|
**/*~
|
||||||
|
nbproject/*
|
||||||
@@ -11,8 +11,6 @@ addons:
|
|||||||
- cmake
|
- cmake
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- git checkout ${TRAVIS_PULL_REQUEST_BRANCH:-$TRAVIS_BRANCH}
|
|
||||||
- git branch --set-upstream-to origin/$TRAVIS_BRANCH
|
|
||||||
- git rev-parse HEAD
|
- git rev-parse HEAD
|
||||||
|
|
||||||
script: make test
|
script: make test
|
||||||
|
|||||||
27
Dockerfile
Normal file
27
Dockerfile
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
FROM alpine
|
||||||
|
|
||||||
|
# Copy sources
|
||||||
|
COPY . /app
|
||||||
|
|
||||||
|
# Install required packages & build git-quick-stats
|
||||||
|
RUN apk add --no-cache bash git make ncurses util-linux \
|
||||||
|
&& cd /app \
|
||||||
|
&& make install \
|
||||||
|
&& rm -rf /app \
|
||||||
|
&& apk del --no-cache make \
|
||||||
|
&& mkdir -p /usr/local/bin \
|
||||||
|
&& echo -en "#!/bin/bash\nset -e\n[[ \"\${1::1}\" == '-' ]] && set -- /usr/bin/git quick-stats \"\$@\"\nexec \"\$@\"" \
|
||||||
|
> /usr/local/bin/docker-entrypoint \
|
||||||
|
&& chmod +x /usr/local/bin/docker-entrypoint
|
||||||
|
|
||||||
|
# Declare all variables usables by git-quick-stats
|
||||||
|
ENV _GIT_SINCE= \
|
||||||
|
_GIT_UNTIL= \
|
||||||
|
_GIT_LIMIT= \
|
||||||
|
_GIT_PATHSPEC= \
|
||||||
|
_MENU_THEME=default \
|
||||||
|
TERM=xterm-256color
|
||||||
|
|
||||||
|
WORKDIR /git
|
||||||
|
ENTRYPOINT [ "/usr/local/bin/docker-entrypoint" ]
|
||||||
|
CMD [ "/usr/bin/git", "quick-stats" ]
|
||||||
2
LICENSE
2
LICENSE
@@ -1,6 +1,6 @@
|
|||||||
MIT License
|
MIT License
|
||||||
|
|
||||||
Copyright (c) 2019 Lukáš Mešťan
|
Copyright (c) 2021 Lukáš Mešťan
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
|||||||
32
Makefile
32
Makefile
@@ -1,42 +1,42 @@
|
|||||||
PREFIX ?= /usr/local
|
PREFIX ?= /usr/local
|
||||||
|
_INSTDIR ?= $(DESTDIR)$(PREFIX)
|
||||||
|
BINDIR ?= $(_INSTDIR)/bin
|
||||||
|
MANDIR ?= $(_INSTDIR)/share/man
|
||||||
TASK_DONE = echo -e "\n✓ $@ done\n"
|
TASK_DONE = echo -e "\n✓ $@ done\n"
|
||||||
# files that need mode 755
|
|
||||||
EXEC_FILES=git-quick-stats
|
|
||||||
|
|
||||||
.PHONY: test
|
.PHONY: test
|
||||||
|
|
||||||
all:
|
all:
|
||||||
@echo "usage: make install"
|
@echo "Usage:"
|
||||||
@echo " make reinstall"
|
@echo " make install"
|
||||||
@echo " make uninstall"
|
@echo " make reinstall"
|
||||||
@echo " make test"
|
@echo " make uninstall"
|
||||||
|
@echo " make test"
|
||||||
|
|
||||||
help:
|
help:
|
||||||
$(MAKE) all
|
$(MAKE) all
|
||||||
@$(TASK_DONE)
|
@$(TASK_DONE)
|
||||||
|
|
||||||
install:
|
install:
|
||||||
mkdir -p $(PREFIX)/bin
|
install -d -m 0755 $(BINDIR)
|
||||||
install -m 0755 $(EXEC_FILES) $(PREFIX)/bin/$(EXEC_FILES)
|
install -m 0755 git-quick-stats $(BINDIR)/git-quick-stats
|
||||||
git config --global alias.quick-stats '! $(PREFIX)/bin/$(EXEC_FILES)'
|
|
||||||
$(MAKE) man
|
$(MAKE) man
|
||||||
@$(TASK_DONE)
|
@$(TASK_DONE)
|
||||||
|
|
||||||
uninstall:
|
uninstall:
|
||||||
test -d $(PREFIX)/bin && \
|
rm -f $(BINDIR)/git-quick-stats
|
||||||
cd $(PREFIX)/bin && \
|
rm -f $(MANDIR)/man1/git-quick-stats.1
|
||||||
rm -f $(EXEC_FILES) && \
|
|
||||||
git config --global --unset alias.quick-stats
|
|
||||||
@$(TASK_DONE)
|
@$(TASK_DONE)
|
||||||
|
|
||||||
reinstall:
|
reinstall:
|
||||||
@curl -s https://raw.githubusercontent.com/arzzen/git-quick-stats/master/git-quick-stats > git-quick-stats
|
@curl -sO https://raw.githubusercontent.com/arzzen/git-quick-stats/master/git-quick-stats
|
||||||
$(MAKE) uninstall && \
|
@curl -sO https://raw.githubusercontent.com/arzzen/git-quick-stats/master/git-quick-stats.1
|
||||||
$(MAKE) install
|
$(MAKE) install
|
||||||
@$(TASK_DONE)
|
@$(TASK_DONE)
|
||||||
|
|
||||||
man:
|
man:
|
||||||
install -g 0 -o 0 -m 0644 git-quick-stats.1 /usr/share/man/man1/
|
install -d -m 0755 $(MANDIR)/man1/
|
||||||
|
install -m 0644 git-quick-stats.1 $(MANDIR)/man1/
|
||||||
|
|
||||||
test:
|
test:
|
||||||
tests/commands_test.sh
|
tests/commands_test.sh
|
||||||
|
|||||||
327
README.md
327
README.md
@@ -1,131 +1,223 @@
|
|||||||
|
|
||||||
## GIT quick statistics [](https://twitter.com/intent/tweet?text=Simple%20and%20efficient%20way%20to%20access%20various%20statistics%20in%20git%20repository&url=https://github.com/arzzen/git-quick-stat&via=arzzen&hashtags=git,stats,tool,statistics,developers)
|
# GIT quick statistics [](#backers) [](#sponsors) [](https://twitter.com/intent/tweet?text=Simple%20and%20efficient%20way%20to%20access%20various%20statistics%20in%20git%20repository&url=https://github.com/arzzen/git-quick-stat&via=arzzen&hashtags=git,stats,tool,statistics,developers) [](https://travis-ci.org/arzzen/git-quick-stats) [](https://formulae.brew.sh/formula/git-quick-stats#default) [](https://repology.org/metapackage/git-quick-stats/packages)
|
||||||
|
|
||||||
[](https://travis-ci.org/arzzen/git-quick-stats)
|
> `git-quick-stats` is a simple and efficient way to access various statistics in a git repository.
|
||||||
[](http://braumeister.org/formula/git-quick-stats)
|
>
|
||||||
[](https://repology.org/metapackage/git-quick-stats/packages)
|
> Any git repository may contain tons of information about commits, contributors, and files. Extracting this information is not always trivial, mostly because there are a gadzillion options to a gadzillion git commands – I don’t think there is a single person alive who knows them all. Probably not even [Linus Torvalds](https://github.com/torvalds) himself :).
|
||||||
|
|
||||||
> `git quick-stats` is a simple and efficient way to access various statistics in git repository.
|

|
||||||
|
|
||||||
> Any git repository contains tons of information about commits, contributors, and files. Extracting this information is not always trivial, mostly because of a gadzillion options to a gadzillion git commands – I don’t think there is a single person alive who knows them all. Probably not even [Linus Torvalds](https://github.com/torvalds) himself :).
|
|
||||||
|
|
||||||
## Table of Contents
|
## Table of Contents
|
||||||
|
|
||||||
[**Screenshots**](#screenshots)
|
[**Screenshots**](#screenshots)
|
||||||
|
|
||||||
[**Installation**](#installation)
|
|
||||||
* [**Unix OS**](#unix-like-os)
|
|
||||||
* [**OS X**](#os-x-homebrew)
|
|
||||||
* [**Windows**](#windows-cygwin)
|
|
||||||
|
|
||||||
[**Usage**](#usage)
|
[**Usage**](#usage)
|
||||||
* [**Git log since/until**](#git-log-since-until)
|
|
||||||
|
* [**Interactive**](#interactive)
|
||||||
|
* [**Non-interactive**](#non-interactive)
|
||||||
|
* [**Command-line arguments**](#command-line-arguments)
|
||||||
|
* [**Git log since and until**](#git-log-since-and-until)
|
||||||
* [**Git log limit**](#git-log-limit)
|
* [**Git log limit**](#git-log-limit)
|
||||||
|
* [**Git log options**](#git-log-options)
|
||||||
* [**Git pathspec**](#git-pathspec)
|
* [**Git pathspec**](#git-pathspec)
|
||||||
* [**Tests**](#tests)
|
* [**Git merge view strategy**](#git-merge-view-strategy)
|
||||||
|
* [**Color themes**](#color-themes)
|
||||||
|
|
||||||
|
[**Installation**](#installation)
|
||||||
|
|
||||||
|
* [**UNIX and Linux**](#unix-and-linux)
|
||||||
|
* [**macOS**](#macos-homebrew)
|
||||||
|
* [**Windows**](#windows)
|
||||||
|
* [**Docker**](#docker)
|
||||||
|
|
||||||
[**System requirements**](#system-requirements)
|
[**System requirements**](#system-requirements)
|
||||||
* [**Dependences**](#dependences)
|
|
||||||
|
|
||||||
[**Contribution**](#contribution)
|
* [**Dependencies**](#dependencies)
|
||||||
|
|
||||||
[**FAQ**](#faq)
|
[**FAQ**](#faq)
|
||||||
|
|
||||||
[**License**](#licensing)
|
[**Contribution**](#contribution)
|
||||||
|
|
||||||
|
* [**Code reviews**](#code-reviews)
|
||||||
|
* [**Some tips for good pull requests**](#some-tips-for-good-pull-requests)
|
||||||
|
* [**Formatting**](#formatting)
|
||||||
|
|
||||||
|
[**Tests**](#tests)
|
||||||
|
|
||||||
|
[**Licensing**](#licensing)
|
||||||
|
|
||||||
|
[**Contributors**](#contributors)
|
||||||
|
|
||||||
|
* [**Backers**](#backers)
|
||||||
|
* [**Sponsors**](#sponsors)
|
||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|
|
||||||
|
|
||||||

|
|
||||||
|
|
||||||

|
|
||||||
|
|
||||||

|
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
|
### Interactive
|
||||||
|
|
||||||
|
`git-quick-stats` has a built-in interactive menu that can be executed as such:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git quick-stats
|
|
||||||
# or
|
|
||||||
git-quick-stats
|
git-quick-stats
|
||||||
```
|
```
|
||||||
|
|
||||||
Or you can use (non-interactive) direct execution:
|
Or
|
||||||
|
|
||||||
`git quick-stats <optional-command-to-execute-directly>`
|
```bash
|
||||||
|
git quick-stats
|
||||||
|
```
|
||||||
|
|
||||||
|
### Non-interactive
|
||||||
|
|
||||||
|
For those who prefer to utilize command-line options, `git-quick-stats` also has a non-interactive mode supporting both short and long options:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git-quick-stats <optional-command-to-execute-directly>
|
||||||
|
```
|
||||||
|
|
||||||
|
Or
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git quick-stats <optional-command-to-execute-directly>
|
||||||
|
```
|
||||||
|
|
||||||
|
### Command-line arguments
|
||||||
|
|
||||||
Possible arguments in short and long form:
|
Possible arguments in short and long form:
|
||||||
|
|
||||||
```
|
```bash
|
||||||
-r, --suggest-reviewers
|
GENERATE OPTIONS
|
||||||
show the best people to contact to review code
|
-T, --detailed-git-stats
|
||||||
-T, --detailed-git-stats
|
give a detailed list of git stats
|
||||||
give a detailed list of git stats
|
-R, --git-stats-by-branch
|
||||||
-d, --commits-per-day
|
see detailed list of git stats by branch
|
||||||
displays a list of commits per day
|
-c, --changelogs
|
||||||
-m, --commits-by-month
|
see changelogs
|
||||||
displays a list of commits per month
|
-L, --changelogs-by-author
|
||||||
-w, --commits-by-weekday
|
see changelogs by author
|
||||||
displays a list of commits per weekday
|
-S, --my-daily-stats
|
||||||
-o, --commits-by-hour
|
see your current daily stats
|
||||||
displays a list of commits per hour
|
-V, --csv-output-by-branch
|
||||||
-A, --commits-by-author-by-hour
|
output daily stats by branch in CSV format
|
||||||
displays a list of commits per hour by author
|
-j, --json-output
|
||||||
-a, --commits-per-author
|
save git log as a JSON formatted file to a specified area
|
||||||
displays a list of commits per author
|
|
||||||
-S, --my-daily-stats
|
LIST OPTIONS
|
||||||
see your current daily stats
|
-b, --branch-tree
|
||||||
-C, --contributors
|
show an ASCII graph of the git repo branch history
|
||||||
see a list of everyone who contributed to the repo
|
-D, --branches-by-date
|
||||||
-b, --branch-tree
|
show branches by date
|
||||||
show an ASCII graph of the git repo branch history
|
-C, --contributors
|
||||||
-D, --branches-by-date
|
see a list of everyone who contributed to the repo
|
||||||
show branches by date
|
-a, --commits-per-author
|
||||||
-c, --changelogs
|
displays a list of commits per author
|
||||||
see changelogs
|
-d, --commits-per-day
|
||||||
-L, --changelogs-by-author
|
displays a list of commits per day
|
||||||
see changelogs by author
|
-m, --commits-by-month
|
||||||
-h, -?, --help
|
displays a list of commits per month
|
||||||
display this help text in the terminal
|
-w, --commits-by-weekday
|
||||||
|
displays a list of commits per weekday
|
||||||
|
-o, --commits-by-hour
|
||||||
|
displays a list of commits per hour
|
||||||
|
-A, --commits-by-author-by-hour
|
||||||
|
displays a list of commits per hour by author
|
||||||
|
-z, --commits-by-timezone
|
||||||
|
displays a list of commits per timezone
|
||||||
|
-Z, --commits-by-author-by-timezone
|
||||||
|
displays a list of commits per timezone by author
|
||||||
|
|
||||||
|
SUGGEST OPTIONS
|
||||||
|
-r, --suggest-reviewers
|
||||||
|
show the best people to contact to review code
|
||||||
|
-h, -?, --help
|
||||||
|
display this help text in the terminal
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Git log since / until
|
### Git log since and until
|
||||||
|
|
||||||
You can set variable `_GIT_SINCE`, `_GIT_UNTIL` and limit the git log
|
You can set the variables `_GIT_SINCE` and/or `_GIT_UNTIL` before running `git-quick-stats` to limit the git log. These work similar to git's built-in `--since` and `--until` log options.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export _GIT_SINCE="2017-20-01"
|
export _GIT_SINCE="2017-01-20"
|
||||||
export _GIT_UNTIL="2017-22-01"
|
export _GIT_UNTIL="2017-01-22"
|
||||||
```
|
```
|
||||||
|
|
||||||
then run `git quick-stats` (affect all stats, except "My daily status" and "Git changelogs" )
|
Once set, run `git quick-stats` as normal. Note that this affects all stats that parse the git log history until unset.
|
||||||
|
|
||||||
|
### Git log limit
|
||||||
|
|
||||||
#### Git log limit
|
You can set variable `_GIT_LIMIT` for limited output. It will affect the "changelogs" and "branch tree" options.
|
||||||
|
|
||||||
You can set variable `_GIT_LIMIT` for limited output (it will affect: "Git changelogs" and "Branch tree view" )
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export _GIT_LIMIT=20
|
export _GIT_LIMIT=20
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Git pathspec
|
### Git log options
|
||||||
|
|
||||||
You can exclude directory from the stats by using [pathspec](https://git-scm.com/docs/gitglossary#gitglossary-aiddefpathspecapathspec)
|
You can set `_GIT_LOG_OPTIONS` for [git log options](https://git-scm.com/docs/git-log#_options):
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export _GIT_LOG_OPTIONS="--ignore-all-space --ignore-blank-lines"
|
||||||
|
```
|
||||||
|
|
||||||
|
### Git pathspec
|
||||||
|
|
||||||
|
You can exclude a directory from the stats by using [pathspec](https://git-scm.com/docs/gitglossary#gitglossary-aiddefpathspecapathspec)
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
export _GIT_PATHSPEC=':!directory'
|
export _GIT_PATHSPEC=':!directory'
|
||||||
```
|
```
|
||||||
|
|
||||||
|
You can also exclude files from the stats. Note that it works with any alphanumeric, glob, or regex that git respects.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export _GIT_PATHSPEC=':!package-lock.json'
|
||||||
|
```
|
||||||
|
|
||||||
|
### Git merge view strategy
|
||||||
|
|
||||||
|
You can set the variable `_GIT_MERGE_VIEW` to enable merge commits to be part of the stats by setting `_GIT_MERGE_VIEW` to `enable`. You can also choose to only show merge commits by setting `_GIT_MERGE_VIEW` to `exclusive`. Default is to not show merge commits. These work similar to git's built-in `--merges` and `--no-merges` log options.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export _GIT_MERGE_VIEW="enable"
|
||||||
|
export _GIT_MERGE_VIEW="exclusive"
|
||||||
|
```
|
||||||
|
|
||||||
|
### Git branch
|
||||||
|
|
||||||
|
You can set the variable `_GIT_BRANCH` to set the branch of the stats. Works with commands `--git-stats-by-branch` and `--csv-output-by-branch`.
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export _GIT_BRANCH="master"
|
||||||
|
```
|
||||||
|
|
||||||
|
### Color themes
|
||||||
|
|
||||||
|
You can change to the legacy color scheme by toggling the variable `_MENU_THEME` between `default` and `legacy`
|
||||||
|
|
||||||
|
```bash
|
||||||
|
export _MENU_THEME="legacy"
|
||||||
|
```
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
#### Unix like OS
|
### Debian and Ubuntu
|
||||||
|
|
||||||
|
If you are on at least Debian Bullseye or Ubuntu Focal you can use apt for installation:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
apt install git-quick-stats
|
||||||
|
```
|
||||||
|
|
||||||
|
### UNIX and Linux
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://github.com/arzzen/git-quick-stats.git && cd git-quick-stats
|
git clone https://github.com/arzzen/git-quick-stats.git && cd git-quick-stats
|
||||||
@@ -144,24 +236,55 @@ For update/reinstall
|
|||||||
sudo make reinstall
|
sudo make reinstall
|
||||||
```
|
```
|
||||||
|
|
||||||
#### OS X (homebrew)
|
### macOS (homebrew)
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
brew install git-quick-stats
|
brew install git-quick-stats
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Windows (cygwin)
|
Or you can follow the UNIX and Linux instructions if you wish.
|
||||||
|
|
||||||
|
### Windows
|
||||||
|
|
||||||
|
If you are installing with Cygwin, use these scripts:
|
||||||
|
|
||||||
* [installer](https://gist.github.com/arzzen/35e09866dfdadf2108b2420045739245)
|
* [installer](https://gist.github.com/arzzen/35e09866dfdadf2108b2420045739245)
|
||||||
* [uninstaller](https://gist.github.com/arzzen/21c660014d0663b6c5710014714779d6)
|
* [uninstaller](https://gist.github.com/arzzen/21c660014d0663b6c5710014714779d6)
|
||||||
|
|
||||||
|
If you are wishing to use this with WSL, follow the UNIX and Linux instructions.
|
||||||
|
|
||||||
|
### Docker
|
||||||
|
|
||||||
|
You can use the Docker image provided:
|
||||||
|
|
||||||
|
* Build: `docker build -t arzzen/git-quick-stats .`
|
||||||
|
* Run interactive menu: `docker run --rm -it -v $(pwd):/git arzzen/git-quick-stats`
|
||||||
|
* Docker pull command: `docker pull arzzen/git-quick-stats` [docker repository](https://hub.docker.com/r/arzzen/git-quick-stats)
|
||||||
|
|
||||||
## System requirements
|
## System requirements
|
||||||
|
|
||||||
* Unix like OS with a proper shell
|
* An OS with a Bash shell
|
||||||
* Tools we use: awk ; cat ; column ; echo ; git ; grep ; head ; seq ; sort ; tput ; tr ; uniq ; wc
|
* Tools we use:
|
||||||
|
|
||||||
#### Dependences
|
```bash
|
||||||
|
awk
|
||||||
|
basename
|
||||||
|
cat
|
||||||
|
column
|
||||||
|
echo
|
||||||
|
git
|
||||||
|
grep
|
||||||
|
head
|
||||||
|
printf
|
||||||
|
seq
|
||||||
|
sort
|
||||||
|
tput
|
||||||
|
tr
|
||||||
|
uniq
|
||||||
|
wc
|
||||||
|
```
|
||||||
|
|
||||||
|
### Dependencies
|
||||||
|
|
||||||
* [`bsdmainutils`](https://packages.debian.org/sid/bsdmainutils) `apt install bsdmainutils`
|
* [`bsdmainutils`](https://packages.debian.org/sid/bsdmainutils) `apt install bsdmainutils`
|
||||||
|
|
||||||
@@ -169,17 +292,24 @@ brew install git-quick-stats
|
|||||||
|
|
||||||
*Q:* I get some errors after run git-quick-stats in cygwin like `/usr/local/bin/git-quick-stats: line 2: $'\r': command not found`
|
*Q:* I get some errors after run git-quick-stats in cygwin like `/usr/local/bin/git-quick-stats: line 2: $'\r': command not found`
|
||||||
|
|
||||||
*A:* You can run dos2unix app in cygwin `/bin/dos2unix.exe /usr/local/bin/git-quick-stats`. This will convert it to Unix format and you then should be able to run it.
|
*A:* You can run the dos2unix app in cygwin as follows: `/bin/dos2unix.exe /usr/local/bin/git-quick-stats`. This will convert the script from the CR-LF convention that Microsoft uses to the LF convention that UNIX, OS X, and Linux use. You should then should be able to run it as normal.
|
||||||
|
|
||||||
|
*Q:* How they could be used in a project with many git projects and statistics would show a summary of all git projects?
|
||||||
|
|
||||||
|
*A:* If you want to include submodule logs, you can try using the following: `export _GIT_LOG_OPTIONS="-p --submodule=log"`
|
||||||
|
(more info about [git log --submodule](https://git-scm.com/docs/git-log#Documentation/git-log.txt---submoduleltformatgt))
|
||||||
|
|
||||||
## Contribution
|
## Contribution
|
||||||
|
|
||||||
Want to contribute? Great! First, read this page.
|
Want to contribute? Great! First, read this page.
|
||||||
|
|
||||||
#### Code reviews
|
### Code reviews
|
||||||
All submissions, including submissions by project members, require review.</br>
|
|
||||||
We use Github pull requests for this purpose.
|
All submissions, including submissions by project members, require review.</br>
|
||||||
|
We use GitHub pull requests for this purpose.
|
||||||
|
|
||||||
|
### Some tips for good pull requests
|
||||||
|
|
||||||
#### Some tips for good pull requests:
|
|
||||||
* Use our code </br>
|
* Use our code </br>
|
||||||
When in doubt, try to stay true to the existing code of the project.
|
When in doubt, try to stay true to the existing code of the project.
|
||||||
* Write a descriptive commit message. What problem are you solving and what
|
* Write a descriptive commit message. What problem are you solving and what
|
||||||
@@ -192,11 +322,11 @@ We use Github pull requests for this purpose.
|
|||||||
HEAD. This make reviewing the code so much easier, and our history more
|
HEAD. This make reviewing the code so much easier, and our history more
|
||||||
readable.
|
readable.
|
||||||
|
|
||||||
#### Formatting
|
### Formatting
|
||||||
|
|
||||||
This documentation is written using standard [markdown syntax](https://help.github.com/articles/markdown-basics/). Please submit your changes using the same syntax.
|
This documentation is written using standard [markdown syntax](https://help.github.com/articles/markdown-basics/). Please submit your changes using the same syntax.
|
||||||
|
|
||||||
#### Tests
|
## Tests
|
||||||
|
|
||||||
[](https://codecov.io/gh/arzzen/git-quick-stats)
|
[](https://codecov.io/gh/arzzen/git-quick-stats)
|
||||||
|
|
||||||
@@ -205,9 +335,36 @@ make test
|
|||||||
```
|
```
|
||||||
|
|
||||||
## Licensing
|
## Licensing
|
||||||
|
|
||||||
MIT see [LICENSE][] for the full license text.
|
MIT see [LICENSE][] for the full license text.
|
||||||
|
|
||||||
[read this page]: http://github.com/arzzen/git-quick-stats/blob/master/docs/CONTRIBUTING.md
|
[read this page]: http://github.com/arzzen/git-quick-stats/blob/master/.github/CONTRIBUTING.md
|
||||||
[landing page]: http://arzzen.github.io/git-quick-stats
|
[landing page]: http://arzzen.github.io/git-quick-stats
|
||||||
[LICENSE]: https://github.com/arzzen/git-quick-stats/blob/master/LICENSE
|
[LICENSE]: https://github.com/arzzen/git-quick-stats/blob/master/LICENSE
|
||||||
|
|
||||||
|
## Contributors
|
||||||
|
|
||||||
|
This project exists thanks to all the people who contribute.
|
||||||
|
|
||||||
|
[](https://github.com/arzzen/git-quick-stats/graphs/contributors)
|
||||||
|
|
||||||
|
### Backers
|
||||||
|
|
||||||
|
Thank you to all our backers! 🙏 [[Become a backer](https://opencollective.com/git-quick-stats#backer)]
|
||||||
|
|
||||||
|
[](https://opencollective.com/git-quick-stats#backers)
|
||||||
|
|
||||||
|
### Sponsors
|
||||||
|
|
||||||
|
Support this project by becoming a sponsor. Your logo will show up here with a link to your website. [[Become a sponsor](https://opencollective.com/git-quick-stats#sponsor)]
|
||||||
|
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/0/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/1/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/2/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/3/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/4/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/5/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/6/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/7/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/8/website)
|
||||||
|
[](https://opencollective.com/git-quick-stats/sponsor/9/website)
|
||||||
|
|||||||
BIN
docs/bg.png
BIN
docs/bg.png
Binary file not shown.
|
Before Width: | Height: | Size: 55 KiB |
6
docs/css/animate.min.css
vendored
6
docs/css/animate.min.css
vendored
File diff suppressed because one or more lines are too long
5
docs/css/bootstrap.min.css
vendored
5
docs/css/bootstrap.min.css
vendored
File diff suppressed because one or more lines are too long
@@ -1,509 +0,0 @@
|
|||||||
/*!
|
|
||||||
* Start Bootstrap - Creative Bootstrap Theme (http://startbootstrap.com)
|
|
||||||
* Code licensed under the Apache License v2.0.
|
|
||||||
* For details, see http://www.apache.org/licenses/LICENSE-2.0.
|
|
||||||
*/
|
|
||||||
|
|
||||||
html,
|
|
||||||
body {
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
font-family: Merriweather,'Helvetica Neue',Arial,sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
hr {
|
|
||||||
max-width: 50px;
|
|
||||||
border-color: #f05f40;
|
|
||||||
border-width: 3px;
|
|
||||||
}
|
|
||||||
|
|
||||||
hr.light {
|
|
||||||
border-color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
a {
|
|
||||||
color: #f05f40;
|
|
||||||
-webkit-transition: all .35s;
|
|
||||||
-moz-transition: all .35s;
|
|
||||||
transition: all .35s;
|
|
||||||
}
|
|
||||||
|
|
||||||
a:hover,
|
|
||||||
a:focus {
|
|
||||||
color: #eb3812;
|
|
||||||
}
|
|
||||||
|
|
||||||
#about a {
|
|
||||||
color: rgba(52, 52, 52, .7);
|
|
||||||
}
|
|
||||||
|
|
||||||
#about a:hover,
|
|
||||||
#about a:focus {
|
|
||||||
color: rgb(52, 52, 52);
|
|
||||||
}
|
|
||||||
|
|
||||||
h1,
|
|
||||||
h2,
|
|
||||||
h3,
|
|
||||||
h4,
|
|
||||||
h5,
|
|
||||||
h6 {
|
|
||||||
font-family: 'Open Sans','Helvetica Neue',Arial,sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
p {
|
|
||||||
margin-bottom: 20px;
|
|
||||||
font-size: 16px;
|
|
||||||
line-height: 1.5;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-primary {
|
|
||||||
background-color: #f05f40;
|
|
||||||
}
|
|
||||||
|
|
||||||
.bg-dark {
|
|
||||||
color: #fff;
|
|
||||||
background-color: #222;
|
|
||||||
}
|
|
||||||
|
|
||||||
.text-faded {
|
|
||||||
color: rgba(255,255,255,.7);
|
|
||||||
}
|
|
||||||
|
|
||||||
section {
|
|
||||||
padding: 100px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
aside {
|
|
||||||
padding: 50px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.no-padding {
|
|
||||||
padding: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default {
|
|
||||||
border-color: rgba(34,34,34,.05);
|
|
||||||
font-family: 'Open Sans','Helvetica Neue',Arial,sans-serif;
|
|
||||||
background-color: #fff;
|
|
||||||
-webkit-transition: all .35s;
|
|
||||||
-moz-transition: all .35s;
|
|
||||||
transition: all .35s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .navbar-header .navbar-brand {
|
|
||||||
text-transform: uppercase;
|
|
||||||
font-family: 'Open Sans','Helvetica Neue',Arial,sans-serif;
|
|
||||||
font-weight: 700;
|
|
||||||
color: #2d8888;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .navbar-header .navbar-brand:hover,
|
|
||||||
.navbar-default .navbar-header .navbar-brand:focus {
|
|
||||||
color: #eb3812;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .nav > li>a,
|
|
||||||
.navbar-default .nav>li>a:focus {
|
|
||||||
text-transform: uppercase;
|
|
||||||
font-size: 13px;
|
|
||||||
font-weight: 700;
|
|
||||||
color: #222;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .nav > li>a:hover,
|
|
||||||
.navbar-default .nav>li>a:focus:hover {
|
|
||||||
color: #f05f40;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .nav > li.active>a,
|
|
||||||
.navbar-default .nav>li.active>a:focus {
|
|
||||||
color: #f05f40!important;
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .nav > li.active>a:hover,
|
|
||||||
.navbar-default .nav>li.active>a:focus:hover {
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media(min-width:768px) {
|
|
||||||
.navbar-default {
|
|
||||||
border-color: rgba(255,255,255,.3);
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .navbar-header .navbar-brand {
|
|
||||||
color: rgba(255,255,255,.7);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .navbar-header .navbar-brand:hover,
|
|
||||||
.navbar-default .navbar-header .navbar-brand:focus {
|
|
||||||
color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .nav > li>a,
|
|
||||||
.navbar-default .nav>li>a:focus {
|
|
||||||
color: rgba(255,255,255,.7);
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default .nav > li>a:hover,
|
|
||||||
.navbar-default .nav>li>a:focus:hover {
|
|
||||||
color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default.affix {
|
|
||||||
border-color: rgba(34,34,34,.05);
|
|
||||||
background-color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default.affix .navbar-header .navbar-brand {
|
|
||||||
font-size: 14px;
|
|
||||||
color: #f05f40;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default.affix .navbar-header .navbar-brand:hover,
|
|
||||||
.navbar-default.affix .navbar-header .navbar-brand:focus {
|
|
||||||
color: #eb3812;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default.affix .nav > li>a,
|
|
||||||
.navbar-default.affix .nav>li>a:focus {
|
|
||||||
color: #222;
|
|
||||||
}
|
|
||||||
|
|
||||||
.navbar-default.affix .nav > li>a:hover,
|
|
||||||
.navbar-default.affix .nav>li>a:focus:hover {
|
|
||||||
color: #f05f40;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
header {
|
|
||||||
position: relative;
|
|
||||||
width: 100%;
|
|
||||||
min-height: auto;
|
|
||||||
text-align: center;
|
|
||||||
color: #fff;
|
|
||||||
background-color: #2f2d2f;
|
|
||||||
/*background-color: #2c3333;*/
|
|
||||||
/*background-image: url(../img/header.jpg);*/
|
|
||||||
/*background-position: center;*/
|
|
||||||
/*-webkit-background-size: cover;*/
|
|
||||||
/*-moz-background-size: cover;*/
|
|
||||||
/*background-size: cover;*/
|
|
||||||
/*-o-background-size: cover;*/
|
|
||||||
}
|
|
||||||
|
|
||||||
header .header-content {
|
|
||||||
position: relative;
|
|
||||||
width: 100%;
|
|
||||||
padding: 100px 15px;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
header .header-content .header-content-inner h1 {
|
|
||||||
margin-top: 0;
|
|
||||||
margin-bottom: 0;
|
|
||||||
/* text-transform: uppercase; */
|
|
||||||
font-weight: 700;
|
|
||||||
font-size: 120px;
|
|
||||||
}
|
|
||||||
|
|
||||||
header .header-content .header-content-inner hr {
|
|
||||||
margin: 30px auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
header .header-content .header-content-inner p {
|
|
||||||
margin-bottom: 50px;
|
|
||||||
font-size: 16px;
|
|
||||||
font-weight: 300;
|
|
||||||
color: rgba(255,255,255,.7);
|
|
||||||
}
|
|
||||||
|
|
||||||
@media(min-width:768px) {
|
|
||||||
header {
|
|
||||||
min-height: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
header .header-content {
|
|
||||||
position: absolute;
|
|
||||||
top: 50%;
|
|
||||||
padding: 0 50px;
|
|
||||||
-webkit-transform: translateY(-50%);
|
|
||||||
-ms-transform: translateY(-50%);
|
|
||||||
transform: translateY(-50%);
|
|
||||||
}
|
|
||||||
|
|
||||||
header .header-content .header-content-inner {
|
|
||||||
margin-right: auto;
|
|
||||||
margin-left: auto;
|
|
||||||
max-width: 1000px;
|
|
||||||
}
|
|
||||||
|
|
||||||
header .header-content .header-content-inner p {
|
|
||||||
margin-right: auto;
|
|
||||||
margin-left: auto;
|
|
||||||
max-width: 80%;
|
|
||||||
font-size: 18px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.section-heading {
|
|
||||||
margin-top: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.service-box {
|
|
||||||
margin: 50px auto 0;
|
|
||||||
max-width: 400px;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media(min-width:992px) {
|
|
||||||
.service-box {
|
|
||||||
margin: 20px auto 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.service-box p {
|
|
||||||
margin-bottom: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box {
|
|
||||||
display: block;
|
|
||||||
position: relative;
|
|
||||||
margin: 0 auto;
|
|
||||||
max-width: 650px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box .portfolio-box-caption {
|
|
||||||
display: block;
|
|
||||||
position: absolute;
|
|
||||||
bottom: 0;
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
text-align: center;
|
|
||||||
color: #fff;
|
|
||||||
opacity: 0;
|
|
||||||
background: rgba(240,95,64,.9);
|
|
||||||
-webkit-transition: all .35s;
|
|
||||||
-moz-transition: all .35s;
|
|
||||||
transition: all .35s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box .portfolio-box-caption .portfolio-box-caption-content {
|
|
||||||
position: absolute;
|
|
||||||
top: 50%;
|
|
||||||
width: 100%;
|
|
||||||
text-align: center;
|
|
||||||
transform: translateY(-50%);
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box .portfolio-box-caption .portfolio-box-caption-content .project-category,
|
|
||||||
.portfolio-box .portfolio-box-caption .portfolio-box-caption-content .project-name {
|
|
||||||
padding: 0 15px;
|
|
||||||
font-family: 'Open Sans','Helvetica Neue',Arial,sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box .portfolio-box-caption .portfolio-box-caption-content .project-category {
|
|
||||||
text-transform: uppercase;
|
|
||||||
font-size: 14px;
|
|
||||||
font-weight: 600;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box .portfolio-box-caption .portfolio-box-caption-content .project-name {
|
|
||||||
font-size: 18px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box:hover .portfolio-box-caption {
|
|
||||||
opacity: 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media(min-width:768px) {
|
|
||||||
.portfolio-box .portfolio-box-caption .portfolio-box-caption-content .project-category {
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-box .portfolio-box-caption .portfolio-box-caption-content .project-name {
|
|
||||||
font-size: 22px;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
.call-to-action h2 {
|
|
||||||
margin: 0 auto 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.text-primary {
|
|
||||||
color: #f05f40;
|
|
||||||
}
|
|
||||||
|
|
||||||
.no-gutter > [class*=col-] {
|
|
||||||
padding-right: 0;
|
|
||||||
padding-left: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-default {
|
|
||||||
border-color: #fff;
|
|
||||||
color: #222;
|
|
||||||
background-color: #fff;
|
|
||||||
-webkit-transition: all .35s;
|
|
||||||
-moz-transition: all .35s;
|
|
||||||
transition: all .35s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-default:hover,
|
|
||||||
.btn-default:focus,
|
|
||||||
.btn-default.focus,
|
|
||||||
.btn-default:active,
|
|
||||||
.btn-default.active,
|
|
||||||
.open > .dropdown-toggle.btn-default {
|
|
||||||
border-color: #ededed;
|
|
||||||
color: #222;
|
|
||||||
background-color: #f2f2f2;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-default:active,
|
|
||||||
.btn-default.active,
|
|
||||||
.open > .dropdown-toggle.btn-default {
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-default.disabled,
|
|
||||||
.btn-default[disabled],
|
|
||||||
fieldset[disabled] .btn-default,
|
|
||||||
.btn-default.disabled:hover,
|
|
||||||
.btn-default[disabled]:hover,
|
|
||||||
fieldset[disabled] .btn-default:hover,
|
|
||||||
.btn-default.disabled:focus,
|
|
||||||
.btn-default[disabled]:focus,
|
|
||||||
fieldset[disabled] .btn-default:focus,
|
|
||||||
.btn-default.disabled.focus,
|
|
||||||
.btn-default[disabled].focus,
|
|
||||||
fieldset[disabled] .btn-default.focus,
|
|
||||||
.btn-default.disabled:active,
|
|
||||||
.btn-default[disabled]:active,
|
|
||||||
fieldset[disabled] .btn-default:active,
|
|
||||||
.btn-default.disabled.active,
|
|
||||||
.btn-default[disabled].active,
|
|
||||||
fieldset[disabled] .btn-default.active {
|
|
||||||
border-color: #fff;
|
|
||||||
background-color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-default .badge {
|
|
||||||
color: #fff;
|
|
||||||
background-color: #222;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-primary {
|
|
||||||
border-color: #f05f40;
|
|
||||||
color: #fff;
|
|
||||||
background-color: #2d8888;
|
|
||||||
-webkit-transition: all .35s;
|
|
||||||
-moz-transition: all .35s;
|
|
||||||
transition: all .35s;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-primary:hover,
|
|
||||||
.btn-primary:focus,
|
|
||||||
.btn-primary.focus,
|
|
||||||
.btn-primary:active,
|
|
||||||
.btn-primary.active,
|
|
||||||
.open > .dropdown-toggle.btn-primary {
|
|
||||||
color: #fff;
|
|
||||||
background-color: #68a9a9;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-primary:active,
|
|
||||||
.btn-primary.active,
|
|
||||||
.open > .dropdown-toggle.btn-primary {
|
|
||||||
background-image: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-primary.disabled,
|
|
||||||
.btn-primary[disabled],
|
|
||||||
fieldset[disabled] .btn-primary,
|
|
||||||
.btn-primary.disabled:hover,
|
|
||||||
.btn-primary[disabled]:hover,
|
|
||||||
fieldset[disabled] .btn-primary:hover,
|
|
||||||
.btn-primary.disabled:focus,
|
|
||||||
.btn-primary[disabled]:focus,
|
|
||||||
fieldset[disabled] .btn-primary:focus,
|
|
||||||
.btn-primary.disabled.focus,
|
|
||||||
.btn-primary[disabled].focus,
|
|
||||||
fieldset[disabled] .btn-primary.focus,
|
|
||||||
.btn-primary.disabled:active,
|
|
||||||
.btn-primary[disabled]:active,
|
|
||||||
fieldset[disabled] .btn-primary:active,
|
|
||||||
.btn-primary.disabled.active,
|
|
||||||
.btn-primary[disabled].active,
|
|
||||||
fieldset[disabled] .btn-primary.active {
|
|
||||||
border-color: #f05f40;
|
|
||||||
background-color: #f05f40;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-primary .badge {
|
|
||||||
color: #f05f40;
|
|
||||||
background-color: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn {
|
|
||||||
border: 0;
|
|
||||||
border-radius: 300px;
|
|
||||||
text-transform: uppercase;
|
|
||||||
font-family: 'Open Sans','Helvetica Neue',Arial,sans-serif;
|
|
||||||
font-weight: 700;
|
|
||||||
font-size: 1.4em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.btn-xl {
|
|
||||||
padding: 15px 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-moz-selection {
|
|
||||||
text-shadow: none;
|
|
||||||
color: #fff;
|
|
||||||
background: #222;
|
|
||||||
}
|
|
||||||
|
|
||||||
::selection {
|
|
||||||
text-shadow: none;
|
|
||||||
color: #fff;
|
|
||||||
background: #222;
|
|
||||||
}
|
|
||||||
|
|
||||||
img::selection {
|
|
||||||
color: #fff;
|
|
||||||
background: 0 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
img::-moz-selection {
|
|
||||||
color: #fff;
|
|
||||||
background: 0 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
body {
|
|
||||||
webkit-tap-highlight-color: #222;
|
|
||||||
}
|
|
||||||
|
|
||||||
#map {
|
|
||||||
height: 300px;
|
|
||||||
overflow: visible;
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.subtitle {
|
|
||||||
color: #b1b1b1;
|
|
||||||
}
|
|
||||||
|
|
||||||
.logo {
|
|
||||||
width: 50%;
|
|
||||||
padding-bottom: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.screencap {
|
|
||||||
width: 80%;
|
|
||||||
padding-top: 20px;
|
|
||||||
padding-bottom: 30px;
|
|
||||||
}
|
|
||||||
@@ -1,81 +0,0 @@
|
|||||||
/*!
|
|
||||||
* The code below adds the modal functionality of the Freelancer Bootstrap Theme
|
|
||||||
* and was originally part of this theme.
|
|
||||||
*
|
|
||||||
*
|
|
||||||
* Start Bootstrap - Freelancer Bootstrap Theme (http://startbootstrap.com)
|
|
||||||
* Code licensed under the Apache License v2.0.
|
|
||||||
* For details, see http://www.apache.org/licenses/LICENSE-2.0.
|
|
||||||
*/
|
|
||||||
|
|
||||||
body {
|
|
||||||
overflow-x: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
.img-centered {
|
|
||||||
margin: 0 auto;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .modal-content {
|
|
||||||
padding: 100px 0;
|
|
||||||
min-height: 100%;
|
|
||||||
border: 0;
|
|
||||||
border-radius: 0;
|
|
||||||
text-align: center;
|
|
||||||
background-clip: border-box;
|
|
||||||
-webkit-box-shadow: none;
|
|
||||||
box-shadow: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .modal-content h2 {
|
|
||||||
margin: 0;
|
|
||||||
font-size: 3em;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .modal-content img {
|
|
||||||
margin-bottom: 30px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .modal-content .item-details {
|
|
||||||
margin: 30px 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .close-modal {
|
|
||||||
position: absolute;
|
|
||||||
top: 25px;
|
|
||||||
right: 25px;
|
|
||||||
width: 75px;
|
|
||||||
height: 75px;
|
|
||||||
background-color: transparent;
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .close-modal:hover {
|
|
||||||
opacity: .3;
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .close-modal .lr {
|
|
||||||
z-index: 1051;
|
|
||||||
width: 1px;
|
|
||||||
height: 75px;
|
|
||||||
margin-left: 35px;
|
|
||||||
background-color: #2c3e50;
|
|
||||||
-webkit-transform: rotate(45deg);
|
|
||||||
-ms-transform: rotate(45deg);
|
|
||||||
transform: rotate(45deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .close-modal .lr .rl {
|
|
||||||
z-index: 1052;
|
|
||||||
width: 1px;
|
|
||||||
height: 75px;
|
|
||||||
background-color: #2c3e50;
|
|
||||||
-webkit-transform: rotate(90deg);
|
|
||||||
-ms-transform: rotate(90deg);
|
|
||||||
transform: rotate(90deg);
|
|
||||||
}
|
|
||||||
|
|
||||||
.portfolio-modal .modal-backdrop {
|
|
||||||
display: none;
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
BIN
docs/favicon.ico
BIN
docs/favicon.ico
Binary file not shown.
|
Before Width: | Height: | Size: 1.4 KiB |
@@ -1,35 +0,0 @@
|
|||||||
<!DOCTYPE html>
|
|
||||||
<html lang="en-us">
|
|
||||||
<head>
|
|
||||||
<meta charset="utf-8">
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
||||||
<meta name="author" content="Lukas Mestan">
|
|
||||||
<meta name="description" content="Commandline GIT statistics">
|
|
||||||
<title>git quick stats</title>
|
|
||||||
<link rel="shortcut icon" href="favicon.ico?v=1" type="image/x-icon">
|
|
||||||
<link rel="stylesheet" href="css/bootstrap.min.css" type="text/css">
|
|
||||||
<link href="https://fonts.googleapis.com/css?family=Montserrat" rel="stylesheet">
|
|
||||||
<link rel="stylesheet" href="css/animate.min.css" type="text/css">
|
|
||||||
<link rel="stylesheet" href="css/creative.css" type="text/css">
|
|
||||||
<link rel="stylesheet" href="css/modals.css" type="text/css">
|
|
||||||
<!--[if lt IE 9]>
|
|
||||||
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
|
|
||||||
<script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
|
|
||||||
<![endif]-->
|
|
||||||
<meta http-equiv="refresh" content="0;url=https://lukasmestan.com/git-quick-stats/">
|
|
||||||
</head>
|
|
||||||
<body id="page-top">
|
|
||||||
<header>
|
|
||||||
<div class="header-content">
|
|
||||||
<div class="header-content-inner">
|
|
||||||
<h1>git quick stats</h1>
|
|
||||||
<h3 class="subtitle"> simple and efficient way to access various statistics in git repository</h3>
|
|
||||||
<img class="screencap" src="bg.png" \>
|
|
||||||
<br>
|
|
||||||
<a href="https://github.com/arzzen/git-quick-stats" class="btn btn-primary btn-xl page-scroll">download</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</header>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
1021
git-quick-stats
1021
git-quick-stats
File diff suppressed because it is too large
Load Diff
@@ -1,13 +1,13 @@
|
|||||||
.TH git-quick-stats "1" "January 2019" "git-quick-stats" "User Commands"
|
.TH git-quick-stats "1" "June 2021" "git-quick-stats" "User Commands"
|
||||||
.SH NAME
|
.SH NAME
|
||||||
.B git\-quick\-stats
|
.B git\-quick\-stats
|
||||||
\- Simple and efficient way to access various stats in a git repository.
|
\- Simple and efficient way to access various stats in a git repository.
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
.PP
|
.PP
|
||||||
For non\-interactive mode:
|
For non\-interactive mode:
|
||||||
.B git\-quick\-stats [OPTIONS]
|
.B git\-quick\-stats [OPTIONS]
|
||||||
.PP
|
.PP
|
||||||
For interactive mode:
|
For interactive mode:
|
||||||
.B git-quick-stats
|
.B git-quick-stats
|
||||||
.PP
|
.PP
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
@@ -17,19 +17,64 @@ and files. Extracting this information is not always trivial, mostly because
|
|||||||
of a gadzillion options to a gadzillion git commands.
|
of a gadzillion options to a gadzillion git commands.
|
||||||
This program allows you to see detailed information about a git repository.
|
This program allows you to see detailed information about a git repository.
|
||||||
.PP
|
.PP
|
||||||
.SH OPTIONS
|
.SH GENERATE OPTIONS
|
||||||
.HP
|
|
||||||
\fB\-r\fR, \fB\-\-suggest\-reviewers\fR
|
|
||||||
.IP
|
|
||||||
show the best people to contact to review code
|
|
||||||
.HP
|
|
||||||
.PP
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-T\fR, \fB\-\-detailed\-git\-stats\fR
|
\fB\-T\fR, \fB\-\-detailed\-git\-stats\fR
|
||||||
.IP
|
.IP
|
||||||
give a detailed list of git stats
|
give a detailed list of git stats
|
||||||
.HP
|
.HP
|
||||||
.PP
|
.PP
|
||||||
|
\fB\-R\fR, \fB\-\-git\-stats\-by\-branch\fR
|
||||||
|
.IP
|
||||||
|
see detailed list of git stats by branch
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-c\fR, \fB\-\-changelogs\fR
|
||||||
|
.IP
|
||||||
|
see changelogs
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-L\fR, \fB\-\-changelogs\-by\-author\fR
|
||||||
|
.IP
|
||||||
|
see changelogs by author
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-S\fR, \fB\-\-my\-daily\-stats\fR
|
||||||
|
.IP
|
||||||
|
see your current daily stats
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-V\fR, \fB\-\-csv\-output\-by\-branch\fR
|
||||||
|
.IP
|
||||||
|
output daily stats by branch in CSV format
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-j\fR, \fB\-\-json\-output\fR
|
||||||
|
.IP
|
||||||
|
save git log as a JSON formatted file to a specified area
|
||||||
|
.HP
|
||||||
|
.SH LIST OPTIONS
|
||||||
|
.PP
|
||||||
|
\fB\-b\fR, \fB\-\-branch\-tree\fR
|
||||||
|
.IP
|
||||||
|
show an ASCII graph of the git repo branch history
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-D\fR, \fB\-\-branches\-by\-date\fR
|
||||||
|
.IP
|
||||||
|
show branches by date
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-C\fR, \fB\-\-contributors\fR
|
||||||
|
.IP
|
||||||
|
see a list of everyone who contributed to the repo
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
|
\fB\-a\fR, \fB\-\-commits\-per\-author\fR
|
||||||
|
.IP
|
||||||
|
displays a list of commits per author
|
||||||
|
.HP
|
||||||
|
.PP
|
||||||
\fB\-d\fR, \fB\-\-commits\-per\-day\fR
|
\fB\-d\fR, \fB\-\-commits\-per\-day\fR
|
||||||
.IP
|
.IP
|
||||||
displays a list of commits per day
|
displays a list of commits per day
|
||||||
@@ -55,39 +100,20 @@ displays a list of commits per hour
|
|||||||
displays a list of commits per hour by author
|
displays a list of commits per hour by author
|
||||||
.HP
|
.HP
|
||||||
.PP
|
.PP
|
||||||
\fB\-a\fR, \fB\-\-commits\-per\-author\fR
|
\fB\-z\fR, \fB\-\-commits\-by\-timezone\fR
|
||||||
.IP
|
.IP
|
||||||
displays a list of commits per author
|
displays a list of commits per timezone
|
||||||
.HP
|
.HP
|
||||||
.PP
|
.PP
|
||||||
\fB\-S\fR, \fB\-\-my\-daily\-stats\fR
|
\fB\-Z\fR, \fB\-\-commits\-by\-author\-by\-timezone\fR
|
||||||
.IP
|
.IP
|
||||||
see your current daily stats
|
displays a list of commits per timezone by author
|
||||||
.HP
|
.HP
|
||||||
|
.SH SUGGEST OPTIONS
|
||||||
.PP
|
.PP
|
||||||
\fB\-C\fR, \fB\-\-contributors\fR
|
\fB\-r\fR, \fB\-\-suggest\-reviewers\fR
|
||||||
.IP
|
.IP
|
||||||
see a list of everyone who contributed to the repo
|
show the best people to contact to review code
|
||||||
.HP
|
|
||||||
.PP
|
|
||||||
\fB\-b\fR, \fB\-\-branch\-tree\fR
|
|
||||||
.IP
|
|
||||||
show an ASCII graph of the git repo branch history
|
|
||||||
.HP
|
|
||||||
.PP
|
|
||||||
\fB\-D\fR, \fB\-\-branches\-by\-date\fR
|
|
||||||
.IP
|
|
||||||
show branches by date
|
|
||||||
.HP
|
|
||||||
.PP
|
|
||||||
\fB\-c\fR, \fB\-\-changelogs\fR
|
|
||||||
.IP
|
|
||||||
see changelogs
|
|
||||||
.HP
|
|
||||||
.PP
|
|
||||||
\fB\-L\fR, \fB\-\-changelogs\-by\-author\fR
|
|
||||||
.IP
|
|
||||||
see changelogs by author
|
|
||||||
.HP
|
.HP
|
||||||
.PP
|
.PP
|
||||||
\fB\-h\fR, \-?, \fB\-\-help\fR
|
\fB\-h\fR, \-?, \fB\-\-help\fR
|
||||||
@@ -96,18 +122,35 @@ display this help text in the terminal
|
|||||||
.PP
|
.PP
|
||||||
.SH ADDITIONAL USAGE
|
.SH ADDITIONAL USAGE
|
||||||
You can set _GIT_SINCE and _GIT_UNTIL to limit the git time log, example:
|
You can set _GIT_SINCE and _GIT_UNTIL to limit the git time log, example:
|
||||||
.IP
|
|
||||||
.PP
|
.PP
|
||||||
.B export _GIT_SINCE="2017\-20\-01"
|
.B export _GIT_SINCE="2017\-01\-20"
|
||||||
.IP
|
|
||||||
.PP
|
.PP
|
||||||
You can set _GIT_LIMIT for limited output log, example:
|
You can set _GIT_LIMIT for limited output log, example:
|
||||||
.PP
|
.PP
|
||||||
.B export _GIT_LIMIT=20
|
.B export _GIT_LIMIT=20
|
||||||
.PP
|
.PP
|
||||||
You can exclude a directory from the stats by using pathspec, example:
|
You can set _GIT_LOG_OPTIONS for git log options, example:
|
||||||
.PP
|
.PP
|
||||||
.B export _GIT_PATHSPEC=':!directory'
|
.B export _GIT_LOG_OPTIONS="--ignore-all-space --ignore-blank-lines"
|
||||||
|
.PP
|
||||||
|
You can exclude directories or files from the stats by using pathspec, example:
|
||||||
|
.PP
|
||||||
|
.B export _GIT_PATHSPEC=':!pattern'
|
||||||
|
.PP
|
||||||
|
You can set _GIT_MERGE_VIEW to show merge commits with normal commits, example:
|
||||||
|
.PP
|
||||||
|
.B export _GIT_MERGE_VIEW="enable"
|
||||||
|
.PP
|
||||||
|
You can also set _GIT_MERGE_VIEW to only show merge commits, example:
|
||||||
|
.PP
|
||||||
|
.B export _GIT_MERGE_VIEW="exclusive"
|
||||||
|
.PP
|
||||||
|
You can switch to the legacy color scheme, example:
|
||||||
|
.PP
|
||||||
|
.B export _MENU_THEME=legacy
|
||||||
|
.PP
|
||||||
|
You can set _GIT_BRANCH to set the branch of the stats, example:
|
||||||
|
.PP
|
||||||
|
.B export _GIT_BRANCH="master"
|
||||||
.
|
.
|
||||||
.fi
|
.fi
|
||||||
|
|
||||||
|
|||||||
@@ -17,12 +17,16 @@
|
|||||||
# You should have received a copy of the GNU Lesser General Public License
|
# You should have received a copy of the GNU Lesser General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
set -o nounset
|
||||||
|
|
||||||
export DISCOVERONLY=${DISCOVERONLY:-}
|
export DISCOVERONLY=${DISCOVERONLY:-}
|
||||||
export DEBUG=${DEBUG:-}
|
export DEBUG=${DEBUG:-}
|
||||||
export STOP=${STOP:-}
|
export STOP=${STOP:-}
|
||||||
export INVARIANT=${INVARIANT:-}
|
export INVARIANT=${INVARIANT:-}
|
||||||
export CONTINUE=${CONTINUE:-}
|
export CONTINUE=${CONTINUE:-}
|
||||||
|
|
||||||
|
GREP=${GREP:-grep}
|
||||||
|
|
||||||
args="$(getopt -n "$0" -l \
|
args="$(getopt -n "$0" -l \
|
||||||
verbose,help,stop,discover,invariant,continue vhxdic $*)" \
|
verbose,help,stop,discover,invariant,continue vhxdic $*)" \
|
||||||
|| exit -1
|
|| exit -1
|
||||||
@@ -132,12 +136,12 @@ assert_raises() {
|
|||||||
_assert_with_grep() {
|
_assert_with_grep() {
|
||||||
local grep_modifier="$1"
|
local grep_modifier="$1"
|
||||||
local output="$($2)"
|
local output="$($2)"
|
||||||
local exitcode="$4" || 0
|
local exitcode=0
|
||||||
shift 2
|
shift 2
|
||||||
|
|
||||||
while [ $# != 0 ]; do
|
while [ $# != 0 ]; do
|
||||||
assert_raises "echo '$output' | $GREP $grep_modifier '$1'" $exitcode || return 1
|
assert_raises "echo '$output' | $GREP $grep_modifier '$1'" $exitcode || return 1
|
||||||
shift
|
shift
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -3,17 +3,95 @@
|
|||||||
. tests/assert.sh -v
|
. tests/assert.sh -v
|
||||||
|
|
||||||
src="./git-quick-stats"
|
src="./git-quick-stats"
|
||||||
#assert "$src fail" "Invalid argument\n\nNAME\n git-quick-stats - Simple and efficient way to access various stats in a git repo\n\nSYNOPSIS\n For non-interactive mode: git-quick-stats [OPTIONS]\n For interactive mode: git-quick-stats\n\nDESCRIPTION\n Any git repository contains tons of information about commits, contributors,\n and files. Extracting this information is not always trivial, mostly because\n of a gadzillion options to a gadzillion git commands.\n\n This program allows you to see detailed information about a git repository.\n\nOPTIONS\n suggestReviewers - see best people to contact to review code\n detailedGitStats - displays a detailed list of git status\n commitsPerDay - displays a list of commits per day\n commitsByMonth - displays a list of commits per month\n commitsByWeekday - displays a list of commits per weekday\n commitsByHour - displays a list of commits per hour\n commitsByAuthorByHour - see a list of commits per hour by author\n commitsPerAuthor - displays a list of commits per author\n myDailyStats - see your current daily stats\n contributors - see a list of all contributors\n branchTree - see an ASCII graph of the git repo\n branchesByDate - show branches by date\n changelogs - see changelogs\n changelogsByAuthor - see changelogs by author\n\nADDITIONAL USAGE\n You can set _GIT_SINCE and _GIT_UNTIL to limit the git time log\n ex: export _GIT_SINCE=2017-20-01\n You can set _GIT_LIMIT for limited output log\n ex: export _GIT_LIMIT=20\n You can exclude a directory from the stats by using pathspec\n ex: export _GIT_PATHSPEC=':!directory'\n \nCONTRIBUTION\n For details regarding contribution, please see the contribution.md document\n\nLICENSE\n This is under the MIT license. See LICENSE in the repo for more info"
|
assert "$src fail" "Invalid argument
|
||||||
assert "$src fail" "Invalid argument\n\nNAME\n git-quick-stats - Simple and efficient way to access various stats in a git repo\n\nSYNOPSIS\n For non-interactive mode: git-quick-stats [OPTIONS]\n For interactive mode: git-quick-stats\n\nDESCRIPTION\n Any git repository contains tons of information about commits, contributors,\n and files. Extracting this information is not always trivial, mostly because\n of a gadzillion options to a gadzillion git commands.\n\n This program allows you to see detailed information about a git repository.\n\nOPTIONS\n -r, --suggest-reviewers\n show the best people to contact to review code\n -T, --detailed-git-stats\n give a detailed list of git stats\n -d, --commits-per-day\n displays a list of commits per day\n -m, --commits-by-month\n displays a list of commits per month\n -w, --commits-by-weekday\n displays a list of commits per weekday\n -o, --commits-by-hour\n displays a list of commits per hour\n -A, --commits-by-author-by-hour\n displays a list of commits per hour by author\n -a, --commits-per-author\n displays a list of commits per author\n -S, --my-daily-stats\n see your current daily stats\n -C, --contributors\n see a list of everyone who contributed to the repo\n -b, --branch-tree\n show an ASCII graph of the git repo branch history\n -D, --branches-by-date\n show branches by date\n -c, --changelogs\n see changelogs\n -L, --changelogs-by-author\n see changelogs by author\n -h, -?, --help\n display this help text in the terminal\n\nADDITIONAL USAGE\n You can set _GIT_SINCE and _GIT_UNTIL to limit the git time log\n ex: export _GIT_SINCE=\"2017-20-01\"\n You can set _GIT_LIMIT for limited output log\n ex: export _GIT_LIMIT=20\n You can exclude a directory from the stats by using pathspec\n ex: export _GIT_PATHSPEC=':!directory'"
|
|
||||||
|
NAME
|
||||||
|
git-quick-stats - Simple and efficient way to access various stats in a git repo
|
||||||
|
|
||||||
|
SYNOPSIS
|
||||||
|
For non-interactive mode: git-quick-stats [OPTIONS]
|
||||||
|
For interactive mode: git-quick-stats
|
||||||
|
|
||||||
|
DESCRIPTION
|
||||||
|
Any git repository contains tons of information about commits, contributors,
|
||||||
|
and files. Extracting this information is not always trivial, mostly because
|
||||||
|
of a gadzillion options to a gadzillion git commands.
|
||||||
|
|
||||||
|
This program allows you to see detailed information about a git repository.
|
||||||
|
|
||||||
|
GENERATE OPTIONS
|
||||||
|
-T, --detailed-git-stats
|
||||||
|
give a detailed list of git stats
|
||||||
|
-R, --git-stats-by-branch
|
||||||
|
see detailed list of git stats by branch
|
||||||
|
-c, --changelogs
|
||||||
|
see changelogs
|
||||||
|
-L, --changelogs-by-author
|
||||||
|
see changelogs by author
|
||||||
|
-S, --my-daily-stats
|
||||||
|
see your current daily stats
|
||||||
|
-V, --csv-output-by-branch
|
||||||
|
output daily stats by branch in CSV format
|
||||||
|
-j, --json-output
|
||||||
|
save git log as a JSON formatted file to a specified area
|
||||||
|
|
||||||
|
LIST OPTIONS
|
||||||
|
-b, --branch-tree
|
||||||
|
show an ASCII graph of the git repo branch history
|
||||||
|
-D, --branches-by-date
|
||||||
|
show branches by date
|
||||||
|
-C, --contributors
|
||||||
|
see a list of everyone who contributed to the repo
|
||||||
|
-a, --commits-per-author
|
||||||
|
displays a list of commits per author
|
||||||
|
-d, --commits-per-day
|
||||||
|
displays a list of commits per day
|
||||||
|
-m, --commits-by-month
|
||||||
|
displays a list of commits per month
|
||||||
|
-w, --commits-by-weekday
|
||||||
|
displays a list of commits per weekday
|
||||||
|
-o, --commits-by-hour
|
||||||
|
displays a list of commits per hour
|
||||||
|
-A, --commits-by-author-by-hour
|
||||||
|
displays a list of commits per hour by author
|
||||||
|
-z, --commits-by-timezone
|
||||||
|
displays a list of commits per timezone
|
||||||
|
-Z, --commits-by-author-by-timezone
|
||||||
|
displays a list of commits per timezone by author
|
||||||
|
|
||||||
|
SUGGEST OPTIONS
|
||||||
|
-r, --suggest-reviewers
|
||||||
|
show the best people to contact to review code
|
||||||
|
-h, -?, --help
|
||||||
|
display this help text in the terminal
|
||||||
|
|
||||||
|
ADDITIONAL USAGE
|
||||||
|
You can set _GIT_SINCE and _GIT_UNTIL to limit the git time log
|
||||||
|
ex: export _GIT_SINCE=\"2017-01-20\"
|
||||||
|
You can set _GIT_LIMIT for limited output log
|
||||||
|
ex: export _GIT_LIMIT=20
|
||||||
|
You can set _GIT_LOG_OPTIONS for git log options
|
||||||
|
ex: export _GIT_LOG_OPTIONS=\"--ignore-all-space --ignore-blank-lines\"
|
||||||
|
You can exclude directories or files from the stats by using pathspec
|
||||||
|
ex: export _GIT_PATHSPEC=':!pattern'
|
||||||
|
You can set _GIT_MERGE_VIEW to view merge commits with normal commits
|
||||||
|
ex: export _GIT_MERGE_VIEW=enable
|
||||||
|
You can also set _GIT_MERGE_VIEW to only show merge commits
|
||||||
|
ex: export _GIT_MERGE_VIEW=exclusive
|
||||||
|
You can set _MENU_THEME to display the legacy color scheme
|
||||||
|
ex: export _MENU_THEME=legacy
|
||||||
|
You can set _GIT_BRANCH to set the branch of the stats
|
||||||
|
ex: export _GIT_BRANCH=master"
|
||||||
|
|
||||||
assert_raises "$src fail" 1
|
assert_raises "$src fail" 1
|
||||||
|
|
||||||
assert_contains "$src --suggest-reviewers" "Suggested code reviewers (based on git history)" 127
|
assert_contains "$src --suggest-reviewers" "Suggested code reviewers (based on git history)"
|
||||||
assert_raises "$src --suggest-reviewers" 0
|
assert_raises "$src --suggest-reviewers" 0
|
||||||
|
|
||||||
assert_contains "$src --detailed-git-stats" "Contribution stats" 127
|
assert_contains "$src --detailed-git-stats" "Contribution stats"
|
||||||
assert_raises "$src --detailed-git-stats" 0
|
assert_raises "$src --detailed-git-stats" 0
|
||||||
|
|
||||||
assert_contains "$src --commits-per-day" "Git commits per date" 127
|
assert_contains "$src --commits-per-day" "Git commits per date"
|
||||||
assert_raises "$src --commits-per-day" 0
|
assert_raises "$src --commits-per-day" 0
|
||||||
|
|
||||||
assert_end
|
assert_end
|
||||||
|
|||||||
Reference in New Issue
Block a user