Merge pull request #3408 from makowskid/npm-check-updates

npm-check-updates CLI functionality added
This commit is contained in:
Shao Yu-Lung (Allen) 2023-07-16 16:11:52 +08:00 committed by GitHub
commit 82a135ab58
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 18 additions and 0 deletions

View File

@ -122,6 +122,7 @@ WORKSPACE_INSTALL_NPM_GULP=true
WORKSPACE_INSTALL_NPM_BOWER=false WORKSPACE_INSTALL_NPM_BOWER=false
WORKSPACE_INSTALL_NPM_VUE_CLI=true WORKSPACE_INSTALL_NPM_VUE_CLI=true
WORKSPACE_INSTALL_NPM_ANGULAR_CLI=false WORKSPACE_INSTALL_NPM_ANGULAR_CLI=false
WORKSPACE_INSTALL_NPM_CHECK_UPDATES_CLI=false
WORKSPACE_INSTALL_PHPREDIS=true WORKSPACE_INSTALL_PHPREDIS=true
WORKSPACE_INSTALL_WORKSPACE_SSH=false WORKSPACE_INSTALL_WORKSPACE_SSH=false
WORKSPACE_INSTALL_SUBVERSION=false WORKSPACE_INSTALL_SUBVERSION=false

View File

@ -1985,7 +1985,19 @@ To install NPM ANGULAR CLI in the Workspace container
3 - Re-build the container `docker-compose build workspace` 3 - Re-build the container `docker-compose build workspace`
<br>
<a name="Install-npm-check-updates"></a>
## Install npm-check-updates CLI
To install npm-check-updates CLI [here](https://www.npmjs.com/package/npm-check-updates) in the Workspace container
1 - Open the `.env` file
2 - Make sure Node is also being installed (`WORKSPACE_INSTALL_NODE` set to `true`)
3 - Search for the `WORKSPACE_INSTALL_NPM_CHECK_UPDATES_CLI` argument under the Workspace Container and set it to `true`
4 - Re-build the container `docker-compose build workspace`

View File

@ -102,6 +102,7 @@ services:
- INSTALL_NPM_BOWER=${WORKSPACE_INSTALL_NPM_BOWER} - INSTALL_NPM_BOWER=${WORKSPACE_INSTALL_NPM_BOWER}
- INSTALL_NPM_VUE_CLI=${WORKSPACE_INSTALL_NPM_VUE_CLI} - INSTALL_NPM_VUE_CLI=${WORKSPACE_INSTALL_NPM_VUE_CLI}
- INSTALL_NPM_ANGULAR_CLI=${WORKSPACE_INSTALL_NPM_ANGULAR_CLI} - INSTALL_NPM_ANGULAR_CLI=${WORKSPACE_INSTALL_NPM_ANGULAR_CLI}
- INSTALL_NPM_CHECK_UPDATES_CLI=${WORKSPACE_INSTALL_NPM_CHECK_UPDATES_CLI}
- INSTALL_DRUSH=${WORKSPACE_INSTALL_DRUSH} - INSTALL_DRUSH=${WORKSPACE_INSTALL_DRUSH}
- INSTALL_WP_CLI=${WORKSPACE_INSTALL_WP_CLI} - INSTALL_WP_CLI=${WORKSPACE_INSTALL_WP_CLI}
- INSTALL_DRUPAL_CONSOLE=${WORKSPACE_INSTALL_DRUPAL_CONSOLE} - INSTALL_DRUPAL_CONSOLE=${WORKSPACE_INSTALL_DRUPAL_CONSOLE}

View File

@ -738,6 +738,7 @@ ARG INSTALL_NPM_GULP=false
ARG INSTALL_NPM_BOWER=false ARG INSTALL_NPM_BOWER=false
ARG INSTALL_NPM_VUE_CLI=false ARG INSTALL_NPM_VUE_CLI=false
ARG INSTALL_NPM_ANGULAR_CLI=false ARG INSTALL_NPM_ANGULAR_CLI=false
ARG INSTALL_NPM_CHECK_UPDATES_CLI=false
ARG NPM_REGISTRY ARG NPM_REGISTRY
ENV NPM_REGISTRY ${NPM_REGISTRY} ENV NPM_REGISTRY ${NPM_REGISTRY}
ARG NPM_FETCH_RETRIES ARG NPM_FETCH_RETRIES
@ -780,6 +781,9 @@ RUN if [ ${INSTALL_NODE} = true ]; then \
&& if [ ${INSTALL_NPM_ANGULAR_CLI} = true ]; then \ && if [ ${INSTALL_NPM_ANGULAR_CLI} = true ]; then \
npm install -g @angular/cli \ npm install -g @angular/cli \
;fi \ ;fi \
&& if [ ${INSTALL_NPM_CHECK_UPDATES_CLI} = true ]; then \
npm install -g npm-check-updates \
;fi \
;fi ;fi
# Wouldn't execute when added to the RUN statement in the above block # Wouldn't execute when added to the RUN statement in the above block