Commands to get commit statistics for a Git repository from the command line -
using git log
, git shortlog
and friends.
# use b as prefix | |
set-option -g prefix C-b | |
unbind-key C-a | |
bind-key C-b send-prefix | |
# Start numbering at 1 | |
set-option -g base-index 1 | |
# Allows for faster key repetition | |
set-option -g escape-time 0 |
git branch -m old_branch new_branch # Rename branch locally | |
git push origin :old_branch # Delete the old branch | |
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote |
Macro hygiene is the concept of macros that work in all contexts; they don't affect and aren't affected by anything around them. Ideally all macros would be fully hygienic, but there are lots of pitfalls and traps that make it all too easy to accidentally write unhygienic macros. This guide attempts to provide a comprehensive resource for writing the most hygienic macros.
First, a little aside on the details of Rust's module system, and specifically paths; it is
This file provides commands to display a list of Git branches ordered by the 20 most recent commits, both locally and including remote branches. These commands are helpful for developers to easily track recent activity in the repository.
To view a list of local Git branches sorted by commit date, use the following command:
git for-each-ref --count=20 --sort=-committerdate refs/heads --format='%(authordate:short) %(color:red)%(objectname:short) %(color:yellow)%(refname:short)%(color:reset) (%(color:green)%(committerdate:relative)%(color:reset))'