You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

19 lines
514 B

  1. const fs = require('fs-extra')
  2. const os = require('os')
  3. const path = require('path')
  4. /* global WIKI */
  5. module.exports = {
  6. key: 'sharp',
  7. title: 'Sharp',
  8. description: 'Process and transform images. Required to generate thumbnails of uploaded images and perform transformations.',
  9. async isCompatible () {
  10. return os.arch() === 'x64'
  11. },
  12. isInstalled: false,
  13. async check () {
  14. this.isInstalled = await fs.pathExists(path.join(WIKI.ROOTPATH, 'node_modules/sharp'))
  15. return this.isInstalled
  16. }
  17. }