Skip to content

Commit 83c5043

Browse files
authored
Merge pull request #2 from tomyitav/automatically-get-version
Automatically get version
2 parents 714233f + 3375af3 commit 83c5043

File tree

4 files changed

+13
-6
lines changed

4 files changed

+13
-6
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,7 @@ To generate a matching resolver file for type file, execute the command:
3737

3838
This will create a matching file, with all Query, Mutation and Subscription
3939
definitions.
40+
41+
### Extended documentation
42+
43+
Please check out the [extended documentation](https://tomyitav.github.io/generate-graphql-app) for more information

package-lock.json

Lines changed: 2 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "generate-graphql-app",
3-
"version": "1.2.4",
3+
"version": "1.3.2",
44
"description": "Cli tool for bootstrapping production grade GraphQL server",
55
"keywords": [
66
"graphql",
@@ -145,6 +145,7 @@
145145
"cross-spawn": "^6.0.5",
146146
"fs-extra": "^7.0.1",
147147
"graphql-json-schema": "^0.1.2",
148-
"inquirer": "^6.2.0"
148+
"inquirer": "^6.2.0",
149+
"pkginfo": "^0.4.1"
149150
}
150151
}

src/gga.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@
22

33
import * as program from 'commander'
44
import allCommands from './commands/all-commands'
5+
require('pkginfo')(module, 'version')
56

6-
program.version('1.3.1').description('Cli tool for bootstrapping production grade GraphQL server')
7+
program
8+
.version(module.exports.version)
9+
.description('Cli tool for bootstrapping production grade GraphQL server')
710

811
for (let command of allCommands) {
912
program

0 commit comments

Comments
 (0)