Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(403)

Issue 7571043: adding search_term to AttachList macro

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 1 month ago by ReimarBauer
Modified:
11 years, 1 month ago
Reviewers:
thomas.j.waldmann
Visibility:
Public.

Description

adding search_term to AttachList macro

Patch Set 1 #

Total comments: 6
Unified diffs Side-by-side diffs Delta from patch set Stats (+9 lines, -5 lines) Patch
M MoinMoin/action/AttachFile.py View 3 chunks +4 lines, -2 lines 2 comments Download
M MoinMoin/macro/AttachList.py View 1 chunk +5 lines, -3 lines 4 comments Download

Messages

Total messages: 4
ReimarBauer
info https://codereview.appspot.com/7571043/diff/1/MoinMoin/macro/AttachList.py File MoinMoin/macro/AttachList.py (right): https://codereview.appspot.com/7571043/diff/1/MoinMoin/macro/AttachList.py#newcode19 MoinMoin/macro/AttachList.py:19: def macro_AttachList(macro, pagename=None, mime_type=u'*', search_term=u'.+'): For my use ...
11 years, 1 month ago (2013-03-07 15:14:32 UTC) #1
Thomas.J.Waldmann
https://codereview.appspot.com/7571043/diff/1/MoinMoin/action/AttachFile.py File MoinMoin/action/AttachFile.py (right): https://codereview.appspot.com/7571043/diff/1/MoinMoin/action/AttachFile.py#newcode324 MoinMoin/action/AttachFile.py:324: files = [fname for fname in files if filterfn(fname)] ...
11 years, 1 month ago (2013-03-07 22:39:20 UTC) #2
ReimarBauer
answered https://codereview.appspot.com/7571043/diff/1/MoinMoin/action/AttachFile.py File MoinMoin/action/AttachFile.py (right): https://codereview.appspot.com/7571043/diff/1/MoinMoin/action/AttachFile.py#newcode324 MoinMoin/action/AttachFile.py:324: files = [fname for fname in files if ...
11 years, 1 month ago (2013-03-07 22:51:59 UTC) #3
ReimarBauer
11 years, 1 month ago (2013-03-08 07:35:03 UTC) #4
decided to use .search

https://codereview.appspot.com/7571043/diff/1/MoinMoin/macro/AttachList.py
File MoinMoin/macro/AttachList.py (right):

https://codereview.appspot.com/7571043/diff/1/MoinMoin/macro/AttachList.py#ne...
MoinMoin/macro/AttachList.py:23: filterfn = re.compile(search_term, re.U).search
On 2013/03/07 22:39:21, Thomas.J.Waldmann wrote:
> check whether you want .search or .match

.search is appropriate one can add ^ to start from the beginning.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b