diff --git a/bin/ec2-cost b/bin/ec2-cost index cefcc90b..3b669154 100755 --- a/bin/ec2-cost +++ b/bin/ec2-cost @@ -17,31 +17,17 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -FORCE=0 DETAIL=0 PKG="byobu" -# Default is "off" -p="ec2-cost" -grep -qs "^$p=1$" "$HOME/.$PKG/status" && FORCE=1 -grep -qs "^$p=0$" "$HOME/.$PKG/status" && FORCE=0 - for arg in $@; do case "$arg" in - -f|--force) - FORCE=1 - ;; -d|--detail) DETAIL=1 ;; esac done -# Exit immediately if this is not an Amazon EC2 instance, we're not -# manually turned on, and we're not in force mode -[ -r "/etc/ec2_version" -o -r "$HOME/.$PKG/ec2-cost" -o "$FORCE" = "1" ] -[ "$?" = "0" ] || exit 0 - # Approximate Instance Cost Basis # US Europe # Small (1cpu, 32bit) $0.10/h $0.11/h