Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

get-binary exits with 0 when the existing binary is kept

Đang mở Phù hợp với người mới
#69 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
2/5
Thời gian dự kiến
1-3 giờ
Mức phù hợp với người mới
82/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
php
Lĩnh vực
cli

Hướng nghiên cứu

Bắt đầu từ GetBinaryCommand::execute() và installBinary(), hai phần mà issue nêu tên: execute() chỉ trả về 1 khi installBinary() trả về null, nhưng tệp bị bỏ qua vẫn được trả về. Kiểm tra bài kiểm thử chấp nhận ExistingBinaryTest::failsWhenBinaryIsKept được nhắc đến trong #66 nếu nó có tồn tại. Hoàn thành khi việc giữ lại một binary đã có kết thúc với mã 1 và in ra cảnh báo RoadRunner has not been installed.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug

Description

When the binary already exists and is not overwritten — the overwrite question is answered "no", or the command runs with --no-interaction — rr get keeps the old file (correct) but exits with 0 and prints [OK] Your project is now ready. Scripts cannot tell that nothing was installed.

GetBinaryCommand::execute() returns 1 with RoadRunner has not been installed only when installBinary() returns null, but installBinary() returns the skipped file as well.

Expected: exit code 1 and the RoadRunner has not been installed warning when the existing binary is kept.

Steps to reproduce

  1. Put any file named rr into an empty directory.
  2. Run rr get --no-config -n there.
  3. The file is unchanged, the exit code is 0.

Additional context

Found by the acceptance tests in #66 (ExistingBinaryTest::failsWhenBinaryIsKept). The DLoad-based implementation in #49 already returns 1 in this case.

Ngôn ngữ chính
PHP
Star
30
Fork
15
Merge trung bình
45 phút
Pull request đã merge (30 ngày)
11

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của roadrunner-php/cli

Tất cả issue của roadrunner-php/cli

Issue tương tự

Thêm issue về PHP

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.