Skip to content

Commit 35ec5f3

Browse files
author
Nicholas Kinsey
committed
init
Signed-off-by: Nicholas Kinsey <nicholas.kinsey@feistystudios.com>
0 parents  commit 35ec5f3

File tree

3 files changed

+112
-0
lines changed

3 files changed

+112
-0
lines changed

bin/xp

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
#!/usr/bin/env coffee
2+
path = require 'path'
3+
fs = require 'fs'
4+
{exec} = require 'child_process'
5+
6+
CONFIG =
7+
EMAIL: 'xp@feistystudios.com'
8+
9+
AUTHORS:
10+
'nk': 'Nicholas Kinsey'
11+
'nr': 'Nathan Rashleigh'
12+
'bs': 'Brendan Scarvell'
13+
14+
fs.stat path.join(process.cwd(), '.git'), (error, stats) ->
15+
throw '.git found but not a directory' unless stats.isDirectory()
16+
17+
authors = new Array
18+
19+
for initials in process.argv[2...]
20+
authors.push CONFIG.AUTHORS[initials]
21+
22+
author = authors.join ' and '
23+
24+
end = ->
25+
exec 'git config --get-regexp user.*', (error, stdout, stderr) ->
26+
console.log stdout
27+
28+
if authors.length > 1
29+
exec """git config user.name '#{author}'""", ->
30+
exec """git config user.email '#{CONFIG.EMAIL}'""", ->
31+
end()
32+
else
33+
exec """git config --unset user.name""", ->
34+
exec """git config --unset user.email""", ->
35+
end()

package.coffee

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
{
2+
name: 'xp'
3+
description: '''Handy tools for eXtreme Programming'''
4+
5+
keywords: ['xp', 'extreme', 'programming', 'git', 'tools', 'utility', 'utilities', 'tool', 'pair']
6+
7+
version: '0.1.0'
8+
9+
author: 'Feisty Studios <xp@feistystudios.com> (http://feistystudios.com/)'
10+
11+
licenses: [
12+
{
13+
type: 'FEISTY'
14+
url: 'https://github.com/feisty/license/raw/master/LICENSE'
15+
}
16+
]
17+
18+
contributors: [
19+
'Nicholas Kinsey <nicholas.kinsey@feistystudios.com>'
20+
]
21+
22+
repository:
23+
type: 'git'
24+
url: 'https://github.com/feisty/xp.git'
25+
private: 'git@github.com:feisty/xp.git'
26+
web: 'https://github.com/feisty/xp'
27+
28+
bugs:
29+
mail: 'xp@feistystudios.com'
30+
web: 'https://github.com/feisty/xp/issues'
31+
32+
directories:
33+
lib: './lib'
34+
doc: './doc'
35+
bin: './bin'
36+
37+
dependencies:
38+
'coffee-script': '>= 1.0.0'
39+
40+
engines:
41+
node: '>= 0.3.4'
42+
}

package.json

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
{
2+
name: 'xp',
3+
description: 'Handy tools for eXtreme Programming',
4+
keywords: ['xp', 'extreme', 'programming', 'git', 'tools', 'utility', 'utilities', 'tool', 'pair'],
5+
version: '0.1.0',
6+
author: 'Feisty Studios <xp@feistystudios.com> (http://feistystudios.com/)',
7+
licenses: [
8+
{
9+
type: 'FEISTY',
10+
url: 'https://github.com/feisty/license/raw/master/LICENSE'
11+
}
12+
],
13+
contributors: ['Nicholas Kinsey <nicholas.kinsey@feistystudios.com>'],
14+
repository: {
15+
type: 'git',
16+
url: 'https://github.com/feisty/xp.git',
17+
private: 'git@github.com:feisty/xp.git',
18+
web: 'https://github.com/feisty/xp'
19+
},
20+
bugs: {
21+
mail: 'xp@feistystudios.com',
22+
web: 'https://github.com/feisty/xp/issues'
23+
},
24+
directories: {
25+
lib: './lib',
26+
doc: './doc',
27+
bin: './bin'
28+
},
29+
dependencies: {
30+
'coffee-script': '>= 1.0.0'
31+
},
32+
engines: {
33+
node: '>= 0.3.4'
34+
}
35+
}

0 commit comments

Comments
 (0)