mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-05-27 09:29:22 -04:00
Merge pull request #4202 from alphagov/node_16
Add package-lock.json & update to Node 16 LTS
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -107,7 +107,6 @@ environment.sh
|
||||
|
||||
# CloudFoundry
|
||||
.cf
|
||||
package-lock.json
|
||||
|
||||
# Files/folders created by build so not present in .cfignore
|
||||
app/version.py
|
||||
|
||||
6
Makefile
6
Makefile
@@ -25,8 +25,8 @@ VIRTUALENV_ROOT := $(shell [ -z $$VIRTUAL_ENV ] && echo $$(pwd)/venv || echo $$V
|
||||
.PHONY: bootstrap
|
||||
bootstrap: generate-version-file ## Set up everything to run the app
|
||||
pip3 install -r requirements_for_test.txt
|
||||
npm install
|
||||
. environment.sh; npm run build
|
||||
source $(HOME)/.nvm/nvm.sh && nvm install && npm ci
|
||||
. environment.sh; source $(HOME)/.nvm/nvm.sh && npm run build
|
||||
|
||||
.PHONY: watch-frontend
|
||||
watch-frontend: ## Build frontend and watch for changes
|
||||
@@ -56,7 +56,7 @@ generate-version-file: ## Generates the app version file
|
||||
test: ## Run tests
|
||||
flake8 .
|
||||
isort --check-only ./app ./tests
|
||||
npm test
|
||||
source $(HOME)/.nvm/nvm.sh && npm test
|
||||
py.test -n auto --maxfail=10 tests/
|
||||
|
||||
.PHONY: fix-imports
|
||||
|
||||
13
README.md
13
README.md
@@ -13,17 +13,21 @@ GOV.UK Notify admin application - https://www.notifications.service.gov.uk/
|
||||
|
||||
At the moment we run Python 3.9 in production.
|
||||
|
||||
### NPM packages
|
||||
### NodeJS & NPM
|
||||
|
||||
If you don't have NodeJS on your system, install it with homebrew.
|
||||
|
||||
```shell
|
||||
brew install node
|
||||
```
|
||||
|
||||
[NPM](npmjs.org) is Node's package management tool. `n` is a tool for managing different versions of Node. The following installs `n` and uses the long term support (LTS) version of Node.
|
||||
`nvm` is a tool for managing different versions of NodeJS. Follow [the guidance on nvm's github repository](https://github.com/nvm-sh/nvm#installing-and-updating) to install it.
|
||||
|
||||
Once installed, run the following to switch to the version of NodeJS for this project. If you don't
|
||||
have that version, it should tell you how to install it.
|
||||
|
||||
```shell
|
||||
npm install -g n
|
||||
n lts
|
||||
nvm use
|
||||
```
|
||||
|
||||
### `environment.sh`
|
||||
@@ -75,4 +79,5 @@ To run a specific JavaScript test, you'll need to copy the full command from `pa
|
||||
## Further docs
|
||||
|
||||
- [Working with static assets](docs/static-assets.md)
|
||||
- [JavaScript documentation](https://github.com/alphagov/notifications-manuals/wiki/JavaScript-Documentation)
|
||||
- [Updating dependencies](https://github.com/alphagov/notifications-manuals/wiki/Dependencies)
|
||||
|
||||
24253
package-lock.json
generated
Normal file
24253
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user