Skip to content

Add shebang support for "cargo script" #15318

@victor-timofei

Description

@victor-timofei

Add an initial shebang support for "cargo script".

Cargo script is an experimental feature for single-file packages described in eRFC-3424.

The initial support would require to recognize and parse the shebang and handle the entire file as a single-file package.

Parsing the manifest would be out of the scope for the moment since it hasn't been stabilized yet. So there would not be support for external packages from crates.io at the moment.

As an extra this initial support could be be beneficial also for other third party alternatives.

I am willing to help with this feature.

Cargo script tracking issue here.

Relates to: #9609

cc: @epage

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-cargocargo related issuesA-project-modelproject model and workspace related issuesB-unstableunstable featureC-featureCategory: feature request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions