Commit Graph

8 Commits

Author SHA1 Message Date
Ilan Cosman
30400f3ced Use test command instead of bracket command 2021-11-26 16:55:50 -08:00
chref
81d87d1c7f
fix Subversion prompt (#7278)
* fix Subversion prompt

- after switching to "string match", some SVN status symbols need
  proper escaping
- the __fish_svn_prompt_flag_names list was missing
  "versioned_obstructed" and was therefore not in line with
  the symbols from __fish_svn_prompt_chars
- when checking for individual SVN status symbols, use
  "string match -e" to handle the case where multiple different
  symbols appear in one status column
- use "sort -u" before merging all symbols from a column into
  one line

Fixes #6715

* use regex for SVN status matching

Using regex matching will prevent different match behaviour
depending on qmark-noglob feature.
Also, counting the resulting matches is unnecessary.

* use list instead of string for SVN status

Make $column_status a list be not removing newlines from SVN status
output. This makes checking for the individual status types within
a column easier because it doesn't require regex matching.

* added quotes for string length test (-n)
2020-08-26 18:31:23 +02:00
Fabian Homborg
9367d4ff71 Reindent functions to remove useless quotes
This does not include checks/function.fish because that currently
includes a "; end" in a message that indent would remove, breaking the test.
2020-03-09 19:46:43 +01:00
Fabian Homborg
8acff328e0 svn_prompt: Check for svnversion
MacOS Catalina apparently ships a stripped down svn that doesn't have
`svnversion`, which we use to print the revision.

For now skip the entire step to remove error spam.

Fixes #6267.

[ci skip]
2019-10-30 21:45:50 +01:00
Fabian Homborg
56e122866c fish_svn_prompt: Shorten a return 2019-07-15 21:02:08 +02:00
Fabian Homborg
c2970f9618 Reformat all files
This runs build_tools/style.fish, which runs clang-format on C++, fish_indent on fish and (new) black on python.

If anything is wrong with the formatting, we should fix the tools, but automated formatting is worth it.
2019-05-05 12:09:25 +02:00
Fabian Homborg
c5d5089871 fish_svn_prompt: Stringify
This was the only remaining use of `grep` in functions/.
2019-03-14 13:23:47 +01:00
Fabian Homborg
c29023b3e8 Rename __fish_svn_prompt -> fish_svn_prompt 2019-02-10 14:44:50 +01:00