windingwind / zotero-actions-tags

Customize your Zotero workflow.
GNU Affero General Public License v3.0
1.83k stars 48 forks source link

[Feature] Let actions load external script as `data` #402

Closed zubairy closed 1 day ago

zubairy commented 1 day ago

Is there an existing issue for this?

Environment

Describe the feature request

Is your feature request related to a problem? Please describe.

A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

In #176, we can export Actions code to synchronize configurations between different computers. However, this still requires manual operation. Is it possible to achieve automatic synchronization, for example: 1) I store the written JavaScript code as an item attachment in Zotero; 2) Create an Action and read the content of this attachment as data to execute.

Why do you need this feature?

A clear and concise description of why you need this feature.

In this way, I only need to update the JS code stored in Zotero, and use Zotero's synchronization function to seamlessly execute Actions in different terminals (Of course, the differences in compatibility with multiple terminal configurations must be taken into account in the JS code script). This is especially useful when I just start to create and debug a code, because at this time I often need to frequently modify and test code.

Describe the solution you'd like

The solution you'd like

A clear and concise description of what you want to happen.

As stated above, let Actions read external synced script as data, similar to the operation Trigger Other Actions, but Exec External Script.

Alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

In short, what I want is to achieve automatic synchronization of multi-terminal configurations of the Actions. Haven't alternative solutions yet.

Anything else?

No response

windingwind commented 1 day ago

You can read and execute external JS files in action.

zubairy commented 1 day ago

It would be appreciated if you could leave a snippet, or some instructions, showing how to do it.

zubairy commented 1 day ago

Searched and know how, cheers.

You can read and execute external JS files in action.