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

Export in a format compatible with cheat #2

Open
veracioux opened this issue Aug 22, 2021 · 0 comments
Open

Export in a format compatible with cheat #2

veracioux opened this issue Aug 22, 2021 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers hacktoberfest

Comments

@veracioux
Copy link
Owner

veracioux commented Aug 22, 2021

I think it would be great if we could export tuterm scripts in a format suitable
for the cheat program. To enable exporting, the user should pass a
-x/--export option or similar.

Even then, not all commands should be exported, but only specific ones. I
suggest that we add a cmdline-export shell function along with an alias
C or cx. Only command lines specified using this function should be exported.

To export messages, they should be declared using message-export or
Message-export instead of the usual message and Message respectively.
Naturally, two new aliases would be added: mx and Mx. Alternatively,
exportable messages could be declared using the usual message/Message by
passing a -x option. In the latter approach, parsing the -x option could
prove painful, so I am inclined toward the former, which is also consistent
with the cmdline-export approach.

Note that even if a commandline or message are declared as exportable, they
should not be exported unless tuterm was called with the --export option.

The following question arises: should we allow a tuterm script to both be run
and exported at the same time? I think we should, but we should also add a
-r/--run option. If --export is absent, --run is not necessary, as the
script will run anyway. If the --export option is given, the script will run
only if --run is specified.

@veracioux veracioux added the enhancement New feature or request label Aug 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers hacktoberfest
Projects
None yet
Development

No branches or pull requests

1 participant