Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add advanced context menu action "Dry-run Lua script from clipboard" #556

Closed
helgoboss opened this issue Apr 9, 2022 · 2 comments
Closed
Labels
enhancement New feature or request realearn Related to ReaLearn

Comments

@helgoboss
Copy link
Owner

The way Lua import works in ReaLearn is:

  1. ReaLearn executes Lua script (from clipboard)
  2. ReaLearn attempts to interpret the return value as ReaLearn API object
  3. ReaLearn loads the API object (after converting it into a data object, but that's a story for another day)

If step 1 fails, ReaLearn currently displays an error message that (hopefully) contains a line number. That's okay.

If step 2 fails, ReaLearn currently shows some validation error. This is sometimes not enough to know what went wrong.

The main problem about step 2 is that we don't even see the result of step 1 (= the data that the Lua script generated). That's why I'm going to add an action that executes the script and opens the result of step 1 in a browser or text editor - formatted as JSON.

@helgoboss helgoboss added the enhancement New feature or request label Apr 9, 2022
@vonglan
Copy link

vonglan commented Apr 9, 2022

... or it could be put into the clipboard

@helgoboss
Copy link
Owner Author

Thought about that, too. But it needs that extra step of pasting.

@helgoboss helgoboss added the realearn Related to ReaLearn label Jul 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request realearn Related to ReaLearn
Projects
None yet
Development

No branches or pull requests

2 participants