Browse files

1.1.0

CoffeeScript 1.3.1
optimist 0.3.1
  • Loading branch information...
1 parent cbcca83 commit a34fd0933c68e98de75b36ce41a09cfae7810722 Nicholas Kinsey committed Apr 18, 2012
Showing with 42 additions and 46 deletions.
  1. +1 −0 VERSION
  2. +20 −0 bin/tag
  3. +0 −29 bin/tag.coffee
  4. +11 −9 package.coffee
  5. +9 −8 package.json
  6. +1 −0 tag.coffee
View
1 VERSION
@@ -0,0 +1 @@
+1.1.0
View
20 bin/tag
@@ -0,0 +1,20 @@
+#!/usr/bin/env coffee
+fs = require 'fs'
+path = require 'path'
+{puts} = require 'util'
+
+optimist = require '../node_modules/optimist'
+
+argv = optimist
+ .usage("Dead-easy titles for OSX's Terminal.app windows/tabs")
+ .alias('v', 'version')
+ .describe('v', 'Print version')
+ .argv
+
+if argv.v or argv.version
+ console.log fs.readFileSync './VERSION', 'utf8'
+ process.exit 0
+
+tag = if argv._.length is 0 then path.basename process.cwd() else argv._[0]
+
+`puts('\033]0;' + tag + '\007')`
View
29 bin/tag.coffee
@@ -1,29 +0,0 @@
-#!/usr/bin/env coffee
-
-VERSION = '1.0.0'
-
-{exec} = require 'child_process'
-
-path = require 'path'
-
-optimist = require('../node_modules/optimist')
-
-{puts} = require 'sys'
-
-log = console.log
-
-usage = '''
- Usage:
- tag [TITLE]
-'''
-
-argv = optimist.usage(usage).argv
-
-log VERSION if argv.version
-
-if argv._.length is 0
- tag = path.basename(process.cwd())
-else
- tag = argv._[0]
-
-puts '\033]0;' + tag + '\007'
View
20 package.coffee
@@ -4,7 +4,7 @@ description: '''window/tab titles for Terminal.app'''
keywords: ['tag', 'title', 'terminal', 'osx', 'window', 'name']
-version: '1.0.0'
+version: require('fs').readFileSync('./VERSION', 'utf8')
author: 'feisty <tag@feisty.co> (http://feisty.co/)'
@@ -13,7 +13,7 @@ licenses: [
url: 'http://github.com/feisty/license/raw/master/LICENSE'
]
-contributors: ['Nicholas Kinsey <nicholas.kinsey@feistystudios.com>']
+contributors: ['Nicholas Kinsey <pyro@feisty.co>']
repository:
type: 'git'
@@ -22,18 +22,20 @@ repository:
web: 'http://github.com/feisty/tag'
bugs:
- mail: 'tag@feistystudios.com'
+ mail: 'tag@feisty.co'
web: 'http://github.com/feisty/tag/issues'
bin:
tag: './bin/tag.coffee'
-
+
main: 'tag.coffee'
dependencies:
- 'coffee-script': '>= 1.1.1 < 1.2'
- optimist: '>= 0.2.4 < 0.3'
-
+ 'coffee-script': '~1.3'
+ optimist: '~0.3'
+
engines:
- node: '>= 0.4.9 < 0.5'
- npm: '>= 1.0.15 < 1.1'
+ node: '~0.6'
+ npm: '~1.1'
+
+preferGlobal: true
View
17 package.json
@@ -9,7 +9,7 @@
"window",
"name"
],
- "version": "1.0.0",
+ "version": "1.1.0",
"author": "feisty <tag@feisty.co> (http://feisty.co/)",
"licenses": [
{
@@ -18,7 +18,7 @@
}
],
"contributors": [
- "Nicholas Kinsey <nicholas.kinsey@feistystudios.com>"
+ "Nicholas Kinsey <pyro@feisty.co>"
],
"repository": {
"type": "git",
@@ -27,19 +27,20 @@
"web": "http://github.com/feisty/tag"
},
"bugs": {
- "mail": "tag@feistystudios.com",
+ "mail": "tag@feisty.co",
"web": "http://github.com/feisty/tag/issues"
},
"bin": {
"tag": "./bin/tag.coffee"
},
"main": "tag.coffee",
"dependencies": {
- "coffee-script": ">= 1.1.1 < 1.2",
- "optimist": ">= 0.2.4 < 0.3"
+ "coffee-script": "~1.3",
+ "optimist": "~0.3"
},
"engines": {
- "node": ">= 0.4.9 < 0.5",
- "npm": ">= 1.0.15 < 1.1"
- }
+ "node": "~0.6",
+ "npm": "~1.1"
+ },
+ "preferGlobal": true
}
View
1 tag.coffee
@@ -0,0 +1 @@
+modules.exports = VERSION: ((require 'fs').readFileSync './VERSION', 'utf8')

0 comments on commit a34fd09

Please sign in to comment.