Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate client version string from package.json version #212

Merged
merged 2 commits into from Dec 18, 2014
Merged
Changes from 1 commit
Commits
File filter...
Filter file types
Jump to…
Jump to file or symbol
Failed to load files and symbols.

Always

Just for now

Prev

set client version in node too

  • Loading branch information
feross committed Dec 17, 2014
commit 1293fbd2436a01abd296df3de5c5a20bcbdaf047
@@ -31,7 +31,8 @@ inherits(WebTorrent, EventEmitter)
* '0.16.1' -> '0016'
* '1.2.5' -> '0102'
*/
var VERSION = '__VERSION__'.match(/([0-9]+)/g).slice(0, 2).map(zeroFill(2)).join('')
var VERSION = (require('./package.json').version || '__VERSION__')
.match(/([0-9]+)/g).slice(0, 2).map(zeroFill(2)).join('')

/**
* WebTorrent Client
@@ -13,6 +13,7 @@
"browser": {
"./lib/fs-storage": false,
"./server": false,
"./package.json": false,
"addr-to-ip-port": false,
"bittorrent-dht/client": false,
"bittorrent-swarm": "webtorrent-swarm",
ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.