-
Notifications
You must be signed in to change notification settings - Fork 129
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
Shebang args #410
Shebang args #410
Conversation
c2d85d6
to
1eea6f1
Compare
59b888f
to
4a9e910
Compare
4a9e910
to
23fb2ea
Compare
102eae9
to
5f23e44
Compare
5f23e44
to
8e8514c
Compare
def programArgs(args: RemainingArgs) = args.unparsed | ||
|
||
def inputArgs(args: RemainingArgs) = args.remaining |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NIT Do we really need those methods? They don't use any of the fields of SharedOptions
, are single-line, and are only called twice. Couldn't they just be inlined?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Done
final case class ShebangOptions( | ||
@Recurse | ||
runOptions: RunOptions = RunOptions() | ||
) {} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NIT
) {} | |
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
|
||
import caseapp._ | ||
|
||
final case class ShebangOptions( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NIT Could ShebangOptions
be moved to its own file (ShebangOptions.scala
), like we do for all other classes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
09cfe00
to
2144587
Compare
When running shebang files, the system constructs a command from by concatenating shebang line, input file name and program arguments. This means we need a special parsing mode that would accept only a single input, and treat everything that comes after the input as program arguments
2144587
to
06ceb41
Compare
No description provided.