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

src: Add option -e/-execute <code> to the fz command. #2618

Merged
merged 7 commits into from
Feb 29, 2024
Merged

src: Add option -e/-execute <code> to the fz command. #2618

merged 7 commits into from
Feb 29, 2024

Conversation

fridis
Copy link
Member

@fridis fridis commented Feb 26, 2024

With this, you can now use

   > fz -e 'say envir.args' a b c
  [./build/bin/fz, a, b, c]

instead of

   > echo 'say envir.args' | fz - a b c
  [./build/bin/fz, a, b, c]

Which is helpful for very small examples.
Also included some cleanup in this patch:

  • SourceModule no longer contains _inputFile and _defaultMain, these can be taken form FrontEndOptions.

  • Added takesAplicationArg() to undefined backend to avoid special tests for undefined backend.

maxteufel
maxteufel previously approved these changes Feb 27, 2024
@maxteufel maxteufel dismissed their stale review February 27, 2024 06:06

tests failing

With this, you can now use

   > fz -e 'say envir.args' a b c
  [./build/bin/fz, a, b, c]

instead of

   > echo 'say envir.args' | fz - a b c
  [./build/bin/fz, a, b, c]

Which is helpful for very small examples.

Also included some cleanup in this patch:

- SourceModule no longer contains _inputFile and _defaultMain, these can be
  taken form FrontEndOptions.

- Added `takesAplicationArg()` to `undefined` backend to avoid special tests for
  `undefined` backend.
Added `executeCode` argument to `FrontEndOptions`.
@maxteufel maxteufel merged commit 165e93a into main Feb 29, 2024
5 checks passed
@maxteufel maxteufel deleted the fz_-e branch February 29, 2024 06:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants