Repository navigation
Releases
Releases · setdef/Alibi
Alibi 0.5.3
Added
- Builds for Linux with musl, such as Alpine, on x86-64 and ARM64: each release has
alibi-x86_64-linux-musl.tar.gzand
alibi-aarch64-linux-musl.tar.gz, as 0.3.0 had. The README gives themiserecipe for them.
Alibi 0.5.2
Changed
- The messages that show a command line with a glob or a pattern in it now write
--files=GLOBand--pattern=REGEX,
which works in every shell on Windows. Ruby on Windows expands a wildcard in an argument, whatever the quotes
around it, unless the word starts with--, so--files GLOB, with a space, could reach Alibi as the names of
several files, or as the name of one. The messages are the ones Alibi prints for an alibi file written by hand, for
an alibi file that doesn't exist, and for analibi initthat leaves out--filesor--pattern.
The examples and the descriptions of--filesand--patterninalibi init --helpshow the same form. The form
with a space is still accepted.
Alibi 0.5.1
Changed
- When an alibi file written by hand has the glob and the pattern of an example in
examples/alibi/, whatever the
file is called, the line that refuses it says to runalibi init FILE.kdl --example NAME, with that example's name,
in place ofalibi init FILE.kdl --files GLOB --pattern REGEX. 0.5.0 gave the second for a copy of an example too. - The line that refuses an alibi file written by hand says that Alibi reads only an alibi file that it wrote and sealed,
where 0.5.0 said that the file was written by hand, which Alibi no longer reads. - A walk of
alibi add FILE.kdlchecks the project once for each alibi it writes, where 0.5.0 checked it twice, so it
waits less on a project whose check is slow. When someone changes the alibi file between two alibis of a walk, the
walk refuses at the next write, withFILE changed since Alibi read it, so nothing was written: run the command again,
and the alibis written before stay, where 0.5.0 read the changed file and went on with it.
Fixed
alibi --version=1 --helpprints the version first and then how to use Alibi, asalibi --version --helpdoes.
0.5.0 printed how to use Alibi alone.
Alibi 0.5.0
Added
alibi amend FILE.kdl IDasks the four questions of one alibi in an alibi file thatalibi initwrote again, and
writes the answers in its place, whole, sealed, and says which alibi it amended, by its ID, which answers changed, and
the command that checks the alibi file. Each answer comes from the file given to--tried-file,--evidence-file,
--unfixable-file, or--reason-file,-for standard input, or, at a terminal, from the editor, which starts with
the old answer. With no terminal, or with--no-input, an answer that no flag gives stays as it was. The alibi keeps
its ID, since its path, snippet, and occurrence stay. The editor's file of each question shows the alibi as
alibi ID PATH, above the question. The editor's file marks its comment lines with#, or, when a line of the old
answer starts with#, with the first of; @ ! $ % ^ & | :that starts no line of it, so that no line of an old
answer is dropped, as git does withcore.commentChar=auto. It reads no project, so it needs nogit. It refuses,
with exit status 2 and nothing written, an alibi file that is missing, written by hand, or not valid, a command line
with no ID, an ID that picks no alibi, or several, or that several alibis share, an answer with nothing in it, answers
that are all as they were, and a reason that another alibi has.alibi add FILE.kdl, with no match address, goes through each match of an alibi file thatalibi initwrote that has
no alibi, in the order the check prints them, when standard input is a terminal. For each match it shows
PATH:LINE: TEXTand how many matches are left, asks the four questions ofalibi addin the editor, and writes the
alibi as soon as its four answers are in, so Ctrl-C keeps the alibis already written. An answer with nothing in it
writes nothing for that match, says the match is left for a fix of the code, and goes on to the next. At the end it
says how many alibis it wrote and how many matches it left, and the command that checks the alibi file. With no
terminal, or with--no-input, it asks nothing and writes nothing, and exits with 2 with the command line of
alibi addfor the first match with no alibi and how many there are. An editor that ends with a status other than 0,
such as:cqin vim, ends the walk with exit status 2 and says that nothing was written for that match, and how many
alibis the walk had added before it, which stay in the alibi file. An alibi file with no match that lacks an alibi
gets a line that says so and exit status 0, with or without a terminal.--tried-file,--evidence-file,
--unfixable-file, and--reason-filewith no match address are an error, since one file of answers is for one
match. The editor's file of each question shows the match, as foralibi add FILE.kdl PATH:LINEbelow. Before this,
alibi add FILE.kdlwas an error that asked for a match address.
Changed
- The file that the editor opens for a question of
alibi add FILE.kdl PATH:LINEshows the match as the check prints
it,PATH:LINE: TEXT, in a comment line above the question, so that the match stays in view when the editor fills
the screen. Alibi drops the line from the answer, as it drops the question. It shows a control character from a
project file as an escape such as\x1B, so that no text of a project file can end the comment line or become part
of the answer. 0.4.17 showed the question alone. - Breaking: An alibi file with no
formatnode, which someone wrote by hand, is an error with exit status 2 for a
check, foralibi list, and foralibi add,alibi amend, andalibi remove. Its line says the alibi file was
written by hand, which Alibi no longer reads, and gives the two command lines that create it anew, with the alibi
file's name as you gave it:alibi init FILE.kdl --files GLOB --pattern REGEX, with the glob and the pattern of the
old file, after you move it aside, andalibi add FILE.kdl, which walks each match that has no alibi. 0.4.16 read such
a file, with no seal and noid, and its alibis, which had areasonand none of the other three answers. Alibi
files that Alibi wrote, in format 1, are read as before. The alibi files inexamples/alibi/are still written by
hand, so a copy of one in.config/alibi/is an error too: start from one with
alibi init FILE.kdl --example NAME. - The line of a failed check about a stale alibi says
matches nothing: run alibi remove FILE.kdl ID, and, if its match is still there, alibi add FILE.kdl PATH:LINE for it,
with the alibi file's name as you gave it and the alibi's ID, where 0.4.16 said
matches nothing: remove it, or bring its path and snippet up to date. Nobody can bring the snippet of an alibi in
an alibi file thatalibi initwrote up to date, since an edit by hand breaks its seal. --helpanywhere on a command line prints how to use the command that the command line starts with, or Alibi, and
exits with 0, whatever else is on it: an alibi file, other options, or a mistake such as an unknown option or an
option with no value.alibi add todo.kdl lib/invoice.rb:2 --help,alibi list a.kdl --help, and
alibi todo.kdl --helpprintedalibi: Invalid flag `FILE`: conflicts with --helpand exited with 2 in 0.4.17,
andalibi add todo.kdl --bogus --helpprinted the fault for--bogus. A word after--is still a file, and
--versionbeside an alibi file without--helpis still an error.
Fixed
alibi init --help --files a --files b, andalibi add --help --tried-file a --tried-file b, print how to use the
command and exit with 0, asalibi list --id ID --helpdoes, where they said the flag was given 2 times and exited
with 2. A command line with a flag given twice and no--helpis as it was.
Alibi 0.4.18
Added
alibi amend FILE.kdl IDasks the four questions of one alibi in an alibi file thatalibi initwrote again, and
writes the answers in its place, whole, sealed, and says which alibi it amended, by its ID, which answers changed, and
the command that checks the alibi file. Each answer comes from the file given to--tried-file,--evidence-file,
--unfixable-file, or--reason-file,-for standard input, or, at a terminal, from the editor, which starts with
the old answer. With no terminal, or with--no-input, an answer that no flag gives stays as it was. The alibi keeps
its ID, since its path, snippet, and occurrence stay. It reads no project, so it needs nogit. It refuses, with
exit status 2 and nothing written, an alibi file that is missing, written by hand, or not valid, a command line
with no ID, an ID that picks no alibi, or several, or that several alibis share, an answer with nothing in it, answers
that are all as they were, and a reason that another alibi has.alibi add FILE.kdl, with no match address, goes through each match of an alibi file thatalibi initwrote that has
no alibi, in the order the check prints them, when standard input is a terminal. For each match it shows
PATH:LINE: TEXTand how many matches are left, asks the four questions ofalibi addin the editor, and writes the
alibi as soon as its four answers are in, so Ctrl-C keeps the alibis already written. An answer with nothing in it
writes nothing for that match, says the match is left for a fix of the code, and goes on to the next. At the end it
says how many alibis it wrote and how many matches it left, and the command that checks the alibi file. With no
terminal, or with--no-input, it asks nothing and writes nothing, and exits with 2 with the command line of
alibi addfor the first match with no alibi and how many there are. An alibi file with no match that lacks an alibi
gets a line that says so and exit status 0, with or without a terminal.--tried-file,--evidence-file,
--unfixable-file, and--reason-filewith no match address are an error, since one file of answers is for one
match. Before this,alibi add FILE.kdlwas an error that asked for a match address.alibi remove FILE.kdl ID ...takes the alibis whose IDs it is given out of an alibi file thatalibi initwrote,
writes the alibi file whole, sealed, and says which alibis it removed, by their IDs, and the command that checks the
alibi file. An ID is an ID start, asalibi list --idtakes it: seven to 64 hexadecimal digits that an alibi's ID
starts with. It asks no question and reads no project, so it needs nogit. It refuses, with exit status 2 and
nothing written, an alibi file that is missing, written by hand, or not valid, a command line with no ID, and any ID
that picks no alibi, or several, or isn't seven to 64 hexadecimal digits, with a line for each, in the words of
alibi list --id. Alibis with the same path, snippet, and occurrence share an ID, andalibi removetakes out
every one that has it, and says so.alibi remove FILE.kdl --staletakes out every alibi of an alibi file thatalibi initwrote that matches nothing, the
ones a check calls stale: its snippet occurs nowhere in its file, or the glob doesn't match its file. It finds them
by checking the alibi file against its project, asalibi FILE.kdldoes, so it needsgit. It says which alibis it
removed, by their IDs, and refuses, with exit status 2 and nothing written, an alibi file with no stale alibi, and a
command line that has both--staleand an ID, or neither.
Changed
- The line of a failed check about a stale alibi, in an alibi file that
alibi initwrote, says
matches nothing: run alibi remove FILE.kdl ID, and, if its match is still there, alibi add FILE.kdl PATH:LINE for it,
with the alibi file's name as you gave it and the alibi's ID, where 0.4.16 said
matches nothing: remove it, or bring its path and snippet up to date. Nobody can bring the snippet of an alibi in
such a file up to date, since an edit by hand breaks its seal. For an alibi file written by hand, the line is as it
was. - When
alibi addfinds its alibi file changed since it read it, it writes
alibi: todo.kdl changed since Alibi read it, so nothing was written: run the command again, where 0.4.16 said it
changedwhile the questions were asked. The exit status, 2, and the refusal to write anything are as in 0.4.16.
Fixed
alibi addrefuses a match that ends on a blank line that no line of text follows, such as a match of a pattern for
two line breaks at the end of a file, before it asks its first question, and says that no alibi can excuse it. 0.4.16
asked all four questions, and then failed with a request to report a fault. A match that ends on a blank line with
text after it gets a snippet that runs on to that text, where 0.4.16 failed the same way.- The command line that
alibi addshows with each question after the first hasPATHwhere an answer came from
standard input, as--tried-file PATH. 0.4.16 wrote--tried-file -, which gave the next run no answer, since
standard input is read once, and stopped it with a message to fix the code. alibi addwrites the alibi into the file that a symlink links to, and leaves the symlink as it is. 0.4.16 replaced
the symlink with a copy of the alibi file that held the new alibi, and left the file it linked to as it was.alibi init --help --files a --files b, andalibi add --help --tried-file a --tried-file b, print how to use the
command and exit with 0, asalibi list --id ID --helpdoes, where they said the flag was given 2 times and exited
with 2.--helpbeside an alibi file is still an error, and a command line with a flag given twice and no--help
is as it was.
Alibi 0.4.17
Changed
- The first line of a failed check, for an alibi file that
alibi initwrote, ends with
fix the code, or run alibi add FILE.kdl PATH:LINE for each match with no alibi, with the alibi file's name as you
gave it, when a match has no alibi. 0.4.15 said to write an alibi, which an edit by hand to such a file can't do,
since it breaks the seal. For an alibi file written by hand, whichalibi addrefuses, the line still says
fix the code, or write an alibi for each match with no alibi. The line for each match is stillPATH:LINE: TEXT.
Alibi 0.4.16
Changed
- When the command line of
alibi inithas--files,--pattern,--example, or--about-filemore than once,
Alibi writesalibi: --files was given 2 times: give it once, which names the flag and says how many times it was
given, where 0.4.14 wrotealibi: Variadic flag --files accepts at most 1 value(s), got 2. The hint, exit status 2,
and the refusal to write anything are as in 0.4.14.
Alibi 0.4.15
Added
alibi add FILE.kdl PATH:LINEwrites an alibi for one match into an alibi file thatalibi initwrote, and says which
alibi it added, by its ID, and the command that checks it.PATH:LINEis the start of the line that the check prints
for the match, andPATH:LINE:COLUMNpicks one of several matches that start on that line. Before it writes, it asks
four questions, one at a time: what was tried, to fix the code instead (tried), the evidence (evidence), why a
fix is impossible (unfixable), and the reason (reason), and keeps each answer in the alibi. Each answer comes from
the file given to--tried-file,--evidence-file,--unfixable-file, or--reason-file,-for standard input,
or from the editor at a terminal. A run with no answer to a question shows that question, the command line to
run with its flag, and how to stop, and exits with 2. An answer with nothing in it stops the command.alibi add
chooses the snippet, the fewest lines around the match that occur once in its file, and the occurrence when they
hold other matches. It refuses, with exit status 2 and nothing written, an alibi file that is missing or written by
hand, a match address where no match starts, or several, or one that an alibi excuses already, and an alibi file that
changed while the questions were asked.
Changed
alibi initrefuses a--files,--pattern,--example, or--about-filethat the command line gives twice, as a
command line it can't use: it writesalibi: --files was given 2 times: give it once, naming the flag and how many
times the command line gave it, then the hint, exits with 2, and writes nothing. 0.4.12 kept the last and ignored the
first without a word.
Alibi 0.4.14
Changed
alibi initrefuses a--files,--pattern,--example, or--about-filethat the command line gives twice, as a
command line it can't use: it writesalibi: Variadic flag --files accepts at most 1 value(s), got 2, naming the
flag, then the hint, exits with 2, and writes nothing. 0.4.12 kept the last and ignored the first without a word.- A bare
alibi init, with no argument at all, prints the help page ofiniton standard error, asalibi init --help
prints it on standard output, and exits with 2, where 0.4.12 wrote a line for each thing the command line leaves out,
then the hint. Any otheralibi initcommand line that is incomplete still gets those lines and the hint.
Alibi 0.4.13
Fixed
alibi initnever replaces a file. 0.4.12 checked that the alibi file didn't exist, and then replaced whatever stood at
its name when it finished writing, so a file that appeared in between was lost. Now the system refuses a name that is
taken, at the step that gives the alibi file its name, andalibi initsays the file exists already and leaves it as
it is. On a file system that has no hard links, it still checks once more and then replaces, so a file that appears in
that instant is lost there.