• Stars
    star
    7,605
  • Rank 5,044 (Top 0.1 %)
  • Language
    Shell
  • License
    MIT License
  • Created over 8 years ago
  • Updated 6 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Recall what you did on the last working day. Psst! or be nosy and find what someone else in your team did ;-)

git-standup

Recall what you did on the last working day ..or be nosy and find what someone else did.

A little tool that I always wanted for myself. I work on several repositories on daily basis and it is mostly difficult for me to remember where I left off in each one of them. git-standup helps me with running standups and keeping track of what I have been doing. By default it gives you the most common usage i.e. shows you commits from the last working day in the current directory and the directories below current level plus it comes with several options to modify how it behaves.

Requirements

The only requirement is having good commit messages :)

Install

You can install git-standup using one of the options listed below

Source Command
curl curl -L https://raw.githubusercontent.com/kamranahmedse/git-standup/master/installer.sh | sudo sh
npm npm install -g git-standup
brew brew update && brew install git-standup
aur pacaur -S git-standup-git
manual Clone and run make install

Usage

Simply run it in your project directory and it will give you the output from the last working day

git standup

If you run it in a folder containing multiple git repositories, it will go through each of the projects and give you the standup report for each one of them.

Options

You can pass several options to modify how git-standup behaves

git standup [-a <author name>]
            [-w <weekstart-weekend>]
            [-m <max-dir-depth>]
            [-F]
            [-b <branch-to-use>]
            [-d <since-days-ago>]
            [-u <until-days-ago>]
            [-D <date-format>]
            [-A <after-date>]
            [-B <before-date>]
            [-L]
            [-g]
            [-h]
            [-f]
            [-s]
            [-r]
            [-c]
            [-R]

Here is the detail for each of the options

Option Description
a Specify author to restrict search to e.g. -a "Kamran Ahmed" or -a "all"
b Specify branch to restrict search to (unset: all branches, "$remote/$branch" to include fetches)
w Specify week start and end days e.g. in UAE weekdays are from Sunday to Thursday so you can do -w SUN-THU
m Specify the depth of recursive directory search e.g. -m 3 defaults to two
F Force recursion up to specified depth even when git repository found earlier
d Specify the number of days back to include e.g. -d 30 to get for a month
u Specify the number of days back till which standup should run e.g. -u 3
L Toggle inclusion of symbolic links in recursive directory search
D Specify the date format for "git log" (default: relative) possible values
A Show the commits till after the given date
B Show the commits till before the given date
h Display the help screen
g Show if commit is GPG signed (G) or not (N)
f Fetch the latest commits beforehand
s Silences the no activity message (useful when running in a directory having many repositories)
c Show diff-stat for every matched commit
r Generates the standup report file git-standup-report.txt in the current directory
R Display the author date instead of the committer date

For the basic usage, all you have to do is run git standup in a repository or a folder containing multiple repositories

Single Repository Usage

To check all your personal commits from last working day, head to the project repository and run

$ git standup

git standup

Multiple Repository Usage

Open a directory having multiple repositories and run

$ git standup

git standup

This will show you all your commits since the last working day in all the repositories inside.

Directory depth

By default the script searches only in the current directory or one level deep. If you want to increase that, use the -m switch. If the base directory is a git repository you can use the -F switch to force the recursion.

$ git standup -m 3

Checking someone else's commits

If you want to find out someone else's commits do

# Considering their name on git is "John Doe"
$ git standup -a "John Doe"

Apart from restrict to commits from a certain user, you can also use -a flag to avoid certain users. You can do that if you enable perl regexp in your git installation git config --global grep.patternType perl, and use the author filter like below:

git standup -a'^(?!(renovate\[bot\]))'

git standup

Check what every contributor did

If you want to find out someone else's commits do

$ git standup -a "all"

Commits from n days ago

If you would like to show all your/someone else's commits from n days ago, you can do

# Show all my commits from 4 days ago
$ git standup -d 4

# Show all John Doe's commits from 5 days ago
$ git standup -a "John Doe" -d 5

git standup -d 5

Date filters

You can apply the filters on the commits shown. Use -A and -B flags to specify after and before dates

# Show all the commits after October 01, 2018
git standup -A "2018-10-01 00:00"
# Show all the commits till before October 01, 2018
git standup -B "2018-10-01 00:00"
# Show the commits between September 20 and September 30
git standup -A "2018-09-20 00:00:00" -B "2018-09-30 23:59"

Show Diff-stat

Add -c flag to show the diff-stat for each of the commits in standup results

git standup -c

Add -g flag to check the GPG info

$ git standup -g

GPG Info

Specifying the date format

Add -D flag to specify the date format. Default is relative

Please note that it accepts the same format that you could pass while doing git log. For example

$ git standup -D relative
# Or instead of relative, it could be local|default|iso|iso-strict|rfc|short|raw etc

Branch Filter

Use of -b foobar option, which restricts returned results to commits present on branch foobar. Supports arbitrary branch specs, so for example -b origin/foobar would include data present on the remote that has not been merged locally.

# Use develop branch for standup
git standup -b develop

Directory whitelisting

If you want to restrict the standup to some paths, you can whitelist them by adding them to a .git-standup-whitelist file. For example if you have the below directory structure

├── Workspace              # All your projects are here
│   ├── project-a          # Some git repository called project-a
│   ├── project-b          # Some git repository called project-b
│   ├── sketch-files       # Some sketch files
│   ├── mockups            # Some balsamiq mockups
│   └── ...                # etc.
└── ...

And you want the git-standup to show logs for only project-a and project-b, you can do that by creating a .git-standup-whitelist file under the Workspace directory with the below contents and it will only consider these directories for the standup

project-a
project-b

Changing the Weekdays

By default, it considers that the work week starts on Monday and ends on Friday. So if you are running this on any day between Tuesday and Friday, it will show you your commits from the last day. However, if you are running this on Monday, it will show you all your commits since Friday.

If you want to change this, like I want because here in Dubai working days are normally Sunday to Thursday, you will have to do the following

$ git standup -w "SUN-THU"

Fetch commits before showing standup

If you have many repositories that you want to generate a standup for, it may be useful to automatically run git fetch before viewing the standup.

If you would like to automatically run git fetch --all before printing the standup, you can add the -f flag, as show below

$ git standup -f

Mixing options

Of course you can mix the options together but please note that if you provide the number of days, it will override the weekdays configuration (MON-FRI) and will show you the commits specifically from n days ago.

# Show all the John Doe's commits from 5 days ago
$ git standup -a "John Doe" -d 5

License

MIT © Kamran Ahmed

More Repositories

1

developer-roadmap

Interactive roadmaps, guides and other educational content to help developers grow in their careers.
TypeScript
293,915
star
2

design-patterns-for-humans

An ultra-simplified explanation to design patterns
45,135
star
3

driver.js

A light-weight, no-dependency, vanilla JavaScript engine to drive user's focus across the page
TypeScript
22,682
star
4

pennywise

Cross-platform application to open any website or media in a floating window
JavaScript
3,761
star
5

githunt

Hunt the most starred projects on any date on GitHub
JavaScript
2,863
star
6

roadmap.sh

Community driven roadmaps, articles and resources for developers
Nunjucks
2,196
star
7

jquery-toast-plugin

Highly customizable jquery plugin to show toast messages
JavaScript
1,511
star
8

brusher

Create beautiful webpage backgrounds
JavaScript
748
star
9

tab-switcher

Chrome Extension - Switch between the opened tabs in the blink of an eye
JavaScript
445
star
10

aws-cost-cli

CLI tool to perform cost analysis on your AWS account with Slack integration
TypeScript
416
star
11

itomate

Automate your iTerm layouts and session setup
Python
335
star
12

datastructures-in-javascript

Illustrated Data Structures — Video Series
JavaScript
175
star
13

kamranahmedse.github.io

Blog created using github-pages-blog-action
HTML
166
star
14

awesome-minimal-sites

An opinionated collection of minimal yet beautiful websites.
158
star
15

local-ses

Trap and test AWS SES emails locally
TypeScript
157
star
16

pipeline-js

Pipeline pattern implementation with the support for sync and async stages
JavaScript
147
star
17

github-pages-blog-action

Create good looking blog from your markdown files in a GitHub repository
CSS
87
star
18

redux-persist-expire

Expiring transformer for redux-persist
JavaScript
78
star
19

css-tailor

✂ Automatically generate CSS from your HTML classes
JavaScript
68
star
20

stylos

Webpack plugin to automatically generate and inject CSS utilities to your application
JavaScript
67
star
21

git-first

Chrome Extension – Takes you to the first commit of a GitHub repository
JavaScript
66
star
22

express-api-problem

Express package to automatically turn your exceptions to the API Problem JSON response
TypeScript
65
star
23

laravel-faulty

Automatically turn your thrown exceptions to JSON response while conforming to API problem specification
PHP
64
star
24

smasher

Smash your directories to get JSON or Array representation and vice versa.
PHP
60
star
25

laravel-modular-boilerplate

A boilerplate to create modular application in laravel 5.1
PHP
59
star
26

copy-marker

Chrome extension — Create URLs with highlighted page selection
JavaScript
55
star
27

beetle

Abuse unicode to incite mayhem
Shell
53
star
28

db-playground

Easily create a sandbox environment for your database exploration.
Shell
50
star
29

jumper-bot

A game developed using HTML-5 canvas and Javascript
JavaScript
50
star
30

laravel-censor

A middleware for Laravel 5.* to easily redact or replace the words from the pages you want.
PHP
43
star
31

github-notable-comments

Chrome Extension – Navigate through the most reacted comments in github issues and PRs
JavaScript
40
star
32

gulp-css-tailor

✂ Gulp plugin to automatically generate CSS from your HTML classes
JavaScript
39
star
33

github-diffs

Easier code reviews by collapse/expand diffs in pull requests
JavaScript
35
star
34

laraformer

Laravel 5.* package to easily introduce a transformation layer for your data
PHP
32
star
35

brainza-fps-unity3d-game

First person shooter 3d game.
ASP
31
star
36

makers.ae

Community of makers in UAE
TypeScript
31
star
37

node-basic-auth-example

Sample implementation of Basic Authentication in Node.js
JavaScript
25
star
38

github-actions-youtube

Codebase for my youtube video on GitHub actions
HTML
25
star
39

php-shorthand

Calculate unique shorthands for a given set of strings
PHP
25
star
40

node-session-auth-example

Sample implementation of Session Authentication in Node.js
JavaScript
23
star
41

promises-examples

Codebase accompanying my YouTube video: All about Asynchronous JavaScript
23
star
42

mongo-playground

Single command to setup MongoDB playground with different datasets
Shell
22
star
43

tweet-counter

Chrome Extension - Bring back the character counters in tweet boxes
JavaScript
20
star
44

mongodumper

Docker image to back up MongoDB database and upload to S3
Shell
18
star
45

slack-msg

Dead simple CLI tool to send messages to Slack
JavaScript
18
star
46

gcuf-news-caster

Google Chrome Extension that shows the latest news from GCUF Website
JavaScript
17
star
47

mondex

CLI tool to create and manage MongoDB indexes using code
TypeScript
16
star
48

walkers

A console based fan fiction RPG for The Walking Dead TV Series
PHP
14
star
49

ng-atlas

An Angular JS application that lets you tour around the globe ..free of cost ;-)
JavaScript
13
star
50

markdown-it-class

Plugin for markdown-it to allow adding classes to HTML tags.
JavaScript
10
star
51

egghead-mongo-aggregation

Codebase for my "Aggregation in MongoDB" videos on Egghead
JavaScript
10
star
52

yaml-sample

JavaScript
8
star
53

sendy

Dockerized Sendy application with one-click deployment setup for Railway.
Shell
7
star
54

kamranahmedse

7
star
55

mulk

Gets the country details by country name, ITU or ISO codes
JavaScript
4
star
56

astro-view-transitions-bug

JavaScript
3
star
57

github-user-activity

JavaScript
3
star