Skip to content

Instantly share code, notes, and snippets.

@yurynix
Last active February 25, 2020 18:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save yurynix/5950e4906c63d015419016188d3c2321 to your computer and use it in GitHub Desktop.
Save yurynix/5950e4906c63d015419016188d3c2321 to your computer and use it in GitHub Desktop.
try {
await downloadAndExtract();
} catch (ex) {
const errorMessage = ex.message;
if (errorMessage.indexOf('ENOSPC') > -1) {
console.log('Got ENOSPC! Check out df output:\n', await exec('df -h'));
}
throw ex;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment