Skip to content

Commit a679720

Browse files
author
Bruno Herfst
committed
v1.0.2
Update ownership and read
1 parent 0481aa0 commit a679720

File tree

5 files changed

+41
-15
lines changed

5 files changed

+41
-15
lines changed

.travis.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
sudo: false
2+
language: node_js
3+
node_js:
4+
- '4'
5+
- '6'
6+
- '9'

README.md

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,32 @@
22

33
A helper to (re-)build [nodeenv](https://github.com/ekalinin/nodeenv).
44

5-
## install:
5+
## Usage
66

7-
npm install build-node-venv --save-dev
7+
First, install the package using npm:
88

9-
Add `env` to `scripts` in your `package.json` for quick rebuilds:
9+
npm install build-nodeenv --save-dev
1010

11-
```
12-
"scripts": {
13-
"env": "build-node-venv && # npm install && npm update"
14-
}
15-
```
11+
Then you can use it as a CLI to rebuild your module:
1612

17-
> Note that you will need to have [virtualenv](https://pypi.python.org/pypi/virtualenv) installed.
13+
build-nodeenv
1814

15+
You can also add it to you package.json like so:
16+
17+
"scripts": {
18+
"env": "build-nodeenv"
19+
}
20+
21+
## No Node
22+
23+
In case you have no Node running outside your virtual environment, you can download and run the build script like so:
24+
25+
curl https://raw.githubusercontent.com/ESCPP/build-node-venv/master/build-node-venv.sh > ./build-node-venv.sh && chmod +x ./build-node-venv.sh && ./build-node-venv.sh
26+
27+
This will create the virtual environment so you will be able to reset from here as normal.
28+
29+
> Note that you will need [virtualenv](https://pypi.python.org/pypi/virtualenv) installed.
30+
31+
## License
32+
33+
MIT

build-node-venv.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ if [ -e "./.venv" ] ; then
1212
rm -rf "./.venv" && deactivate
1313
fi
1414

15+
# clear node_modules if there
16+
if [ -e "./node_modules" ] ; then
17+
rm -rf "./node_modules"
18+
fi
19+
1520
# create node env
1621
virtualenv .venv && source .venv/bin/activate
1722

build-parent-node-venv.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
#!/bin/bash
2-
# https://github.com/ES-CPP/bashnips
32

43
# current folder
54
cd "${0%/*}"

package.json

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
{
22
"name": "build-node-venv",
3-
"version": "1.0.0",
3+
"version": "1.0.2",
44
"description": "Bash helper to re-build node-venv",
55
"main": "build-node-venv.sh",
66
"bin": {
77
"build-node-venv": "build-parent-node-venv.sh"
88
},
99
"scripts": {
10-
"env": "chmod +x ./build-node-venv.sh && ./build-node-venv.sh"
10+
"env":"curl https://raw.githubusercontent.com/ESCPP/build-node-venv/master/build-node-venv.sh > ./build-node-venv.sh && chmod +x ./build-node-venv.sh && ./build-node-venv.sh",
11+
"test": "cd test && npm install && build-node-venv"
1112
},
1213
"repository": {
1314
"type": "git",
14-
"url": "git+https://github.com/GitBruno/build-node-venv.git"
15+
"url": "git+https://github.com/ESCPP/build-node-venv.git"
1516
},
1617
"keywords": [
1718
"nodeenv",
@@ -22,7 +23,7 @@
2223
"author": "Bruno Herfst",
2324
"license": "MIT",
2425
"bugs": {
25-
"url": "https://github.com/GitBruno/build-node-venv/issues"
26+
"url": "https://github.com/ESCPP/build-node-venv/issues"
2627
},
27-
"homepage": "https://github.com/GitBruno/build-node-venv"
28+
"homepage": "https://github.com/ESCPP/build-node-venv"
2829
}

0 commit comments

Comments
 (0)