Regex to display all page names containing a word


I would appreciate your help with a Regex for a Bob Swift Attachments Table macro. 

I am trying to display the attachments on all pages that contain the word, for example "help" in the title.


1 answer

Hi Debra, 

The Attachment Table macro contains a number of parms for different regex values as you probably noticed in the macro editor. 

The parameter you want to look at for the attachment name is "Attachment name regex" and you want to specify a value of ".*help.*" without the double quotes to find all attachments with "help" in the name.  The dot matches any single character and the * says to match on 0 or more instances.  So .*help.* will match any number of characters before help and any number after help so your attachment name may begin with help, end in help, or have help in the middle some place.  

Depending on which spaces and pages you want to search across in your instance you can use the other regex parms as well in combination with the attachment name to widen the search out past the current page. 

Some parms, such as "Space key or space name regex", have a special value you can pass.  @all searches all spaces and @self searches the current space the page is in.  

Here is a little more help on the regex: 

How to use regular expressions

I hope this helps.



Suggest an answer

Log in or Join to answer
Community showcase
Alexey Matveev
Published Saturday in Jira

How to run Jira in a docker container

Everything below is tested on Ubuntu 17.10. I prefer to use Jira in a docker container because: 1. I can install Jira with a couple of commands. 2. I can start and stop Jira just by starting and s...

422 views 6 8
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot