Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Proposal: per-task shell/interpreter selection (bash/zsh/pwsh/node) + explicit script mode

オープン
#275 コメント 1 件 リアクション 1 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
42/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
静か
技術スタック
rust, shell
領域
cli, tooling

調査の方向性

crates/vite_task_plan/src/plan.rs と PR #100 から始めて、既存のフォールバックおよびシェル引数の処理を理解します。MVP は、タスクごとにオプションで指定できるシェルがコマンドを 1 つのスクリプトとして実行し、デフォルトの動作を維持できれば完了です。構文と他のモードとの相互作用については、まだ設計上の決定が必要です。

索引モデルが issue の本文から書いたものです。

説明

Problem

Vite Tasks currently tries to parse commands statically (e.g. && lists) and otherwise falls back to running a shell (/bin/sh -c on Unix or cmd.exe /c on Windows).
However, many real-world tasks need:

  • PowerShell on Windows,
  • bash-specific features on Unix (vs /bin/sh),
  • or explicit “always run as script” mode (never try to split/parse).

Not being able to choose the interpreter makes scripts less portable and pushes authors to wrap everything manually.

Evidence (primary)

  • Plan has a hard-coded fallback to /bin/sh -c or cmd.exe /c.

Refs:

Proposed behavior (Unspecified syntax)

Add an optional per-task configuration, e.g.:

  • shell: "bash -c" or shell: ["powershell.exe","-NoLogo","-Command"]
    and/or an execution mode:
  • mode: "auto" (current behavior),
  • mode: "shell" (always run as script via chosen shell),
  • mode: "spawn" (strict direct spawn; fail if not representable)

Use cases

  • Windows repos standardizing on PowerShell scripts
  • bash-only constructs (process substitution, arrays, [[ ... ]], etc.)
  • Avoiding accidental fallback when a task should be strictly spawnable

Backward compatibility

  • Default remains current behavior (auto).
  • Opt-in only changes behavior for tasks that specify shell/mode.

Minimal implementation suggestion (MVP)

  • Implement shell override for the existing fallback pipeline first:
    if shell is set, run the task command as one script in that shell (no splitting).
  • Later iterations can decide whether/how to combine with && splitting and caching.
主要言語
Rust
スター
466
フォーク
42
平均マージ
2日 6時間
マージ済み PR(30日)
30

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

voidzero-dev/vite-task のほかの issue

voidzero-dev/vite-task の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。