aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2016-08-01 17:03:51 +1200
committerTom Ryder <tom@sanctum.geek.nz>2016-08-01 17:03:51 +1200
commit4a505f6bd80693588738bb6421799b8cf39cccba (patch)
treebd9c691bc18bf312cf24b6e322c26e1c553a60e6
parentMake jfc(1) into a POSIX sh script (diff)
downloaddotfiles-4a505f6bd80693588738bb6421799b8cf39cccba.tar.gz
dotfiles-4a505f6bd80693588738bb6421799b8cf39cccba.zip
Allow arguments for jfc(1)
-rwxr-xr-xbin/jfc1
-rw-r--r--man/man1/jfc.13
2 files changed, 4 insertions, 0 deletions
diff --git a/bin/jfc b/bin/jfc
index be1a3b04..36e11451 100755
--- a/bin/jfc
+++ b/bin/jfc
@@ -1,6 +1,7 @@
#!/bin/sh
# Commit all changes to a Git repository with a stock message
# message.
+cd -- "${1:-.}" || exit
grc || exit 0
git add --all || exit
git commit --message 'Committed by jfc(1)' --quiet || exit
diff --git a/man/man1/jfc.1 b/man/man1/jfc.1
index 1c3c8400..4244835b 100644
--- a/man/man1/jfc.1
+++ b/man/man1/jfc.1
@@ -4,6 +4,9 @@
\- add all and commit quietly to a Git repository with a stock message
.SH SYNOPSIS
.B jfc
+.br
+.B jfc
+/path/to/repo
.SH DESCRIPTION
.B jfc
adds all the changed/added files in a Git repository and commits them silently