Page MenuHomePhabricator

No way to skip rule arc:prompt
Closed, ResolvedPublic

Description

The arc diff takes some rules as input with --base. Due to our workflow, I am using a script that holds three rules. If one fails, the next will be performed. Unfortunately, I am not able to find a way to skip the arc:prompt rule. If no valid commit ID was entered, the rule should fail and the following rule should be executed. My example is the following:

arc diff --base "arc:exec(type .bookmark), arc:prompt, arc:upstream" --no-amend

.bookmark is a file containing a stored commit id. (find is cat in Windows.) I would like to take a look at this for my self and diff it to the repository, but I was not able to find the code where the rules are evaluated.

Event Timeline

clloos updated the task description. (Show Details)
clloos added a project: Arcanist.
clloos added a subscriber: clloos.
epriestley triaged this task as Normal priority.

After D14187, we will continue evaluation if you enter no text (i.e., just hit enter at the prompt).

(If you enter some text and that text does not resolve to a valid commit (e.g., type "marshtar" instead of "master") we'll still abort, but I think this is correct.)