aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xdone24
-rwxr-xr-xstatus35
-rwxr-xr-xztd38
3 files changed, 57 insertions, 40 deletions
diff --git a/done b/done
new file mode 100755
index 0000000..6e95bbd
--- /dev/null
+++ b/done
@@ -0,0 +1,24 @@
+#!/bin/bash
+#
+# Submit updates to a project.
+#
+
+# Parameters
+PROJECT="$1"
+
+# Try to get there
+if [ ! -z "$PROJECT" ]; then
+ cd $PROJECT &> /dev/null || exit 1
+fi
+
+# Sync
+if git status &> /dev/null; then
+ if which updates > /dev/null; then
+ updates
+ else
+ git commit -a -m "Updates $PROJECT"
+ git push
+ fi
+
+ git fetch --all
+fi
diff --git a/status b/status
index b12e83b..98a11f0 100755
--- a/status
+++ b/status
@@ -1,6 +1,37 @@
#!/bin/bash
#
-# Check project status using mr.
+# Check the overall status of your work.
#
-mrconfig-updater && mr -m status
+# Parameters
+PROJECT="$1"
+
+# Dispatch
+if [ ! -z "$PROJECT" ]; then
+ # Check the status of the given project
+ cd $PROJECT &> /dev/null && git status
+else
+ # Ensure we are in the home folder
+ cd
+
+ # Check your reminders
+ if [ -e "$HOME/.reminders" ]; then
+ remind ~/.reminders | grep -v '^No reminders.$'
+ fi
+
+ # Update your mrconfig and check all registered repositories
+ mrconfig-updater && mr -m status
+
+ # Check your TODO lists
+ todo
+
+ # Check if you have mails to send
+ postponed
+
+ # Check if are dangling downloaded files
+ if [ -e "$HOME/load" ] && [ ! -z "`ls -1 ~/load/`" ]; then
+ echo "Dangling files at ~/load:"
+ echo ""
+ ls -lh ~/load/
+ fi
+fi
diff --git a/ztd b/ztd
deleted file mode 100755
index 7d3add8..0000000
--- a/ztd
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/bin/bash
-#
-# ZTD extension to commit, push and fetch a project.
-#
-
-# Parameters
-PROJECT="$1"
-
-# Try to get there
-if [ ! -z "$PROJECT" ]; then
- cd $PROJECT &> /dev/null
-elif ! git status &> /dev/null; then
- cd
- remind ~/.reminders | grep -v '^No reminders.$'
- status
- todo
- postponed
-
- if [ ! -z "`ls -1 ~/load/`" ]; then
- echo "Dangling files at ~/load:"
- echo ""
- ls -lh ~/load/
- fi
-
- exit
-fi
-
-# Sync
-if git status &> /dev/null; then
- if which updates > /dev/null; then
- updates
- else
- git commit -a -m "Updates $PROJECT"
- git push
- fi
-
- git fetch --all
-fi