Organized Asset Export Script to put resources in image/ media/ and js/ folders

I had an issue with an export script as well. I had to remove it and reload it. After that it worked for me again. Hope it helps for you.

1 Like

To clarify these instructions:

  1. Choose the Hype > Preferences… menu item
  2. Click the Exporting Preference pane
  3. Click Show Export Scripts Folder in Finder
  4. Throw the com.tumult.Hype4 folder in the Trash (this will remove all export scripts)
  5. Re-download the latest Organized Asset Export script and install it
    :arrow_right: OrganizedAssets.pkg

If that doesn't solve it for you, let me know and there are some logs I'd like to collect to see what the problem might be.

Maybe Node.js could replace Python eventually? Would that be an option?

1 Like

My issue with export scripts is resolved.

Apologies, I realized I was running Hype 4.1.7 on the machine I was using - after updating all was fine.

Okay, glad you figured it out!

Sorry about the delay - I had to investigate why we didn't originally get your emails/reports (it was from an overzealous configuration option in our spam filter).

Theoretically I do think this is the best solution, but there's practical hurdles.

You could use export scripts with node.js right now if you wanted to; the interface is via command line arguments. Python was chosen for all of Tumult's and the initial examples because it is a pretty clear language and was shipped on the system by default. Node unfortunately isn't, and I don't really like having to build/ship runtimes with our apps :frowning: (Whisk has Java).

Export scripts use the macOS Application Script feature as a way to escape the security sandbox so you can do arbitrary things. It turns out most export scripts don't need this ability at all. Further, JavaScript would be the best language to use to interact with the Hype UI, and could be run the Hype editor WebView even. So there might be some middle ground we can do that either gives appropriate instructions to get node, or provide a minimal amount of functionality found in node for the types of things common in export scripts.

3 Likes

What would a node.js script look like in construction and use?

One using the current infrastructure would look pretty much the same as python scripts, but in javascript. You can even use a node shebang so there's no need for any tramplining to a different file.

A next generation one that's run within the app would call named functions and expect returned objects instead of shell script arguments/console output.

1 Like

Assume we are talking normal JS and not JXA

Correct.

2 Likes