File tree Expand file tree Collapse file tree 3 files changed +16
-6
lines changed Expand file tree Collapse file tree 3 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -36,10 +36,10 @@ install_cli_with_local_codegen: &install_cli
36
36
source .circleci/local_publish_helpers.sh
37
37
startLocalRegistry "$(pwd)/.circleci/verdaccio.yaml"
38
38
setNpmRegistryUrlToLocal
39
- sudo npm install -g @aws-amplify/cli-internal
40
- sudo npm install -g amplify-app
39
+ changeNpmGlobalPath
40
+ npm install -g @aws- amplify/cli-internal
41
41
amplify -v
42
- amplify-app --version
42
+ npm list --global --depth=1
43
43
unsetNpmRegistryUrl
44
44
working_directory : ~/repo
45
45
@@ -154,6 +154,8 @@ jobs:
154
154
steps :
155
155
- attach_workspace :
156
156
at : ./
157
+ - restore_cache :
158
+ key : amplify-codegen-yarn-deps-{{ .Branch }}-{{ checksum "yarn.lock" }}
157
159
- restore_cache :
158
160
key : amplify-verdaccio-cache-{{ .Branch }}-{{ .Revision }}
159
161
- run : *install_cli
Original file line number Diff line number Diff line change @@ -34,10 +34,10 @@ install_cli_with_local_codegen: &ref_3
34
34
source .circleci/local_publish_helpers.sh
35
35
startLocalRegistry "$(pwd)/.circleci/verdaccio.yaml"
36
36
setNpmRegistryUrlToLocal
37
- sudo npm install -g @aws-amplify/cli-internal
38
- sudo npm install -g amplify-app
37
+ changeNpmGlobalPath
38
+ npm install -g @aws- amplify/cli-internal
39
39
amplify -v
40
- amplify-app --version
40
+ npm list --global --depth=1
41
41
unsetNpmRegistryUrl
42
42
working_directory : ~/repo
43
43
clean_up_e2e_resources : &ref_5
@@ -157,6 +157,8 @@ jobs:
157
157
steps : &ref_4
158
158
- attach_workspace :
159
159
at : ./
160
+ - restore_cache :
161
+ key : ' amplify-codegen-yarn-deps-{{ .Branch }}-{{ checksum "yarn.lock" }}'
160
162
- restore_cache :
161
163
key : ' amplify-verdaccio-cache-{{ .Branch }}-{{ .Revision }}'
162
164
- run : *ref_3
Original file line number Diff line number Diff line change @@ -28,3 +28,9 @@ function setNpmRegistryUrlToLocal {
28
28
npm set registry " $custom_registry_url "
29
29
yarn config set registry " $custom_registry_url "
30
30
}
31
+
32
+ function changeNpmGlobalPath {
33
+ mkdir -p ~ /.npm-global
34
+ npm config set prefix ' ~/.npm-global'
35
+ export PATH=~ /.npm-global/bin:$PATH
36
+ }
You can’t perform that action at this time.
0 commit comments