-
-
Notifications
You must be signed in to change notification settings - Fork 112
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
chore(common): Allow to build offline #12439
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -267,7 +267,12 @@ verify_npm_setup() { | |
|
||
pushd "$KEYMAN_ROOT" > /dev/null | ||
|
||
try_multiple_times npm ci | ||
offline_param= | ||
if builder_try_offline; then | ||
builder_echo "Trying offline build" | ||
offline_param=--prefer-offline | ||
fi | ||
try_multiple_times npm ${offline_param} ci | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We could consider to always pass There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't know if that's a good idea for build agents? |
||
|
||
popd > /dev/null | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is
~/.cache
a safe path? We have already a ~/.keyman path used for nvm (seekeyman/docs/build/node.md
Line 33 in aa50672
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
~/.cache
is the default location for caches on Linux. In contrast to the path for nvm (where the directory contains links to the actual executable).MESON_PACKAGE_CACHE_DIR
serves as a real cache that caches the files we have to download. If the files don't exist they'll get downloaded (again). In either case they get extracted/copied to thesubprojects
folder in e.g.core/src
. This means it's safe to delete the files from~/.cache/keyman/builder
, whereas I think the build will fail if~/.keyman/node
doesn't exist. So I'd prefer to put the files under~/.cache/...
.