Permalink
Browse files

Add script for example

  • Loading branch information...
1 parent f8507a8 commit 15cb19cb05dacb714a640f360cfc5ec9b6ea0b19 @kachick committed Nov 28, 2012
Showing with 17 additions and 0 deletions.
  1. +17 −0 example/show_4th-monday_in_next_year.sh
@@ -0,0 +1,17 @@
+#!/bin/sh
+
+LANG=C; export LANG
+own_path=$(
+ cd $(dirname $0)
+ pwd
+)
+pj_path=$(dirname "$own_path")
+. "$pj_path/lib/extoday.sh"
+
+for n in $(seq 0 365); do
+ date=$(date --date "$n day" '+%Y-%m-%d')
+
+ if [ $(show_nth_week_in_month "$date") = 4 ] && [ $(show_wday "$date") = Mon ]; then
+ echo "$date"
+ fi
+done

0 comments on commit 15cb19c

Please sign in to comment.