git-annex/doc
Joey Hess f8e940eb8e Fix bug in parsing of parens in some preferred content expressions. This fixes the behavior of the manual mode group.
The current manual mode preferred content expression is:

"present and (((exclude=*/archive/* and exclude=archive/*) or (not (copies=archive:1 or copies=smallarchive:1))) or (not copies=semitrusted+:1))"

The old matcher misparsed this, to basically:

OR (present and (...)) (not copies=semitrusted+:1))

The paren handling and indeed the whole conversion from tokens to the
matcher was just wrong. The new way may not be the cleverest, but I think
it is correct, and you can see how it pattern matches structurally against
the expressions when parsing them.

That expression is now parsed to:

MAnd (MOp <function>)
  (MOr (MOr (MAnd (MOp <function>) (MOp <function>)) (MNot (MOr (MOp <function>) (MOp <function>))))
    (MNot (MOp <function>)))

Which appears correct, and behaves correct in testing.

Also threw in a simplifier, so the final generated Matcher has less
unnecessary clutter in it. Mostly so that I could more easily read &
confirm them.

Also, added a simple test of the Matcher to the test suite.

There is a small chance of badly formed preferred content expressions
behaving differently than before due to this rewrite.
2013-05-24 21:46:33 -04:00
..
Android Added a comment: Still problems with my old N1/CM7 2013-05-24 06:01:19 +00:00
android blog for the day 2013-05-06 18:09:46 -04:00
assistant update 2013-05-21 14:32:48 -04:00
backends
bare_repositories
bugs Fix bug in parsing of parens in some preferred content expressions. This fixes the behavior of the manual mode group. 2013-05-24 21:46:33 -04:00
design blog for the day 2013-05-23 19:16:29 -04:00
direct_mode
download
encryption
footer
forum Added a comment 2013-05-24 15:47:36 +00:00
install Added a comment: PPA Package Pinning 2013-05-23 21:18:14 +00:00
internals
license
links
news add news item for git-annex 4.20130521 2013-05-21 14:24:02 -04:00
not
preferred_content
special_remotes Added a comment 2013-05-24 16:45:27 +00:00
sync
templates fix log filename 2013-05-24 11:39:10 -04:00
tips Added a comment: Problems with URL ending with ".git" 2013-05-24 12:15:16 +00:00
todo Merge branch 'master' of ssh://git-annex.branchable.com 2013-05-24 12:46:57 -04:00
upgrades
use_case
users Add homepage and convert a few links to HTTPS 2013-04-28 22:17:45 +00:00
videos
walkthrough link direct mode 2013-04-18 15:59:57 -04:00
Android.mdwn remove disk space usage note 2013-05-23 13:56:53 -04:00
assistant.mdwn wording 2013-05-16 12:21:56 -04:00
backends.mdwn
bare_repositories.mdwn
bugs.mdwn header 2013-04-23 18:47:35 -04:00
coding_style.mdwn
comments.mdwn
contact.mdwn fix typo 2013-04-17 09:58:24 +00:00
copies.mdwn
design.mdwn
direct_mode.mdwn update for Windows 2013-05-13 13:46:03 -04:00
distributed_version_control.mdwn
download.mdwn
encryption.mdwn To enable an existing special remote, the new enableremote command must be used. The initremote command now is used only to create new special remotes. 2013-04-26 18:22:52 -04:00
favicon.ico
feeds.mdwn
forum.mdwn
future_proofing.mdwn future_proofing.mdwn: Typo fix 2013-05-22 21:42:25 +02:00
git-annex-shell.mdwn
git-annex.mdwn note about initremote --fast 2013-05-24 12:12:00 -04:00
git-union-merge.mdwn
how_it_works.mdwn
index.mdwn
install.mdwn update 2013-05-16 12:09:13 -04:00
internals.mdwn
license.mdwn
location_tracking.mdwn
logo-bw.svg
logo.png
logo.svg
logo_small.png
meta.mdwn
news.mdwn
not.mdwn
preferred_content.mdwn per-IA-item content directories 2013-04-25 23:44:55 -04:00
related_software.mdwn
repomap.png
scalability.mdwn
sidebar.mdwn
sitemap.mdwn
special_remotes.mdwn gar 2013-05-23 19:29:48 -04:00
summary.mdwn
sync.mdwn
testimonials.mdwn
tips.mdwn
todo.mdwn
transferring_data.mdwn
trust.mdwn
upgrades.mdwn
users.mdwn
videos.mdwn
walkthrough.mdwn