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.
 
 
 
 
 
 

27 lines
685 B

  1. "use strict";
  2. const textStylingReset = "\x1b[0m";
  3. const textColorGreen = "\x1b[32m";
  4. const textColorRed = "\x1b[31m";
  5. // When the project is installed on MacOS(darwin), install the pod files.
  6. const process = require("process");
  7. const isMacOs = process.platform === "darwin";
  8. if (isMacOs) {
  9. console.log("Installing pod files...");
  10. const { exec } = require("child_process");
  11. exec("npm run ios-pod-install", error => {
  12. if (error) {
  13. console.error(
  14. `${textColorRed}error ${textStylingReset}An unexpected error occured: ${error}`
  15. );
  16. return;
  17. }
  18. console.log(
  19. `${textColorGreen}succes ${textStylingReset}Pod files installed.`
  20. );
  21. });
  22. }