ReplaceGuard

How to use ReplaceGuard

Install it and open it

  1. A Confluence site admin installs ReplaceGuard from the Atlassian Marketplace and accepts what it asks for.
  2. Anyone on the site opens it from Confluence’s Apps menu: ReplaceGuard.
  3. The first time, Confluence asks you to allow ReplaceGuard to work as you. It finds and changes pages as you.

Find: the preview

  1. Choose Text or A link (its address).
  2. Type what to find and what to put instead. For text, leave “Replace with” empty to remove it.
  3. For text, choose Match case, Whole words only and Page titles too if you want them. Without match case, upper and lower case are the same.
  4. For a link, choose Only this exact address, or This address and every address that starts with it when a whole site or folder moved: replacing https://old.example.com/docs with https://new.example.com/help turns https://old.example.com/docs/setup into https://new.example.com/help/setup.
  5. Choose Every space I can view, or These spaces and type their keys (a space’s key is in its address: /wiki/spaces/KEY/).
  6. Press Find (nothing changes yet). ReplaceGuard reads each page in those spaces and lists every page with a match: how many, and the words around up to three of them. A large site takes a while; you can leave the page and come back to it under “Your runs”.

Replace

Check the preview, then press Replace on … pages and confirm. ReplaceGuard reads each page again, changes what is still there, and saves it as a new version noted “Changed by ReplaceGuard (RG-…)”. Each page in the list then says what happened: changed (with its version before and after), or skipped and why. A preview can be confirmed for one day; after that, find again.

Stop ends a run after the page it is on. A stopped replace can be continued or undone.

Undo

Open the run and press Undo this run. ReplaceGuard puts each page it changed back to its version before the change: it reads that version from Confluence and saves it again as the newest, noted “Undone by ReplaceGuard”. A page someone edited after ReplaceGuard is left as it is and listed, so nobody’s later work is lost; its page history in Confluence has every version if you want to restore one by hand. Runs can be undone for 90 days, while their log is kept.

Ask the ReplaceGuard agent in Rovo

In Rovo Chat, choose the ReplaceGuard agent and ask, for example: “Replace Acme Corp with Acme Inc. in the ENG and MKT spaces”, or “Change every link to https://old.example.com to https://new.example.com”. The agent:

  1. runs Find and shows you the preview, with its code (such as RG-7K3Q9M2X); nothing is changed;
  2. asks whether to apply it, and changes the pages only when you say so (Rovo also asks you to confirm);
  3. undoes a run when you ask it to, with the run’s code.

Runs started in Rovo are in your list on ReplaceGuard’s page too. The agent needs Rovo on your site; its chat uses your site’s Rovo plan.

Bulk changes by anyone, and how to undo them

ReplaceGuard watches every page update on your site. When one account saves new versions of 20 or more different pages within 10 minutes, that is a bulk change. It may be a person, an app or an automation, or Rovo working for a person (Confluence reports Rovo’s changes under that person’s account).

  1. If you administer one of its spaces, the bulk change appears at the top of ReplaceGuard’s page, under “Bulk changes in spaces you administer”, with when it began and how many of your pages it changed. You only see pages in spaces you administer.
  2. Choose Preview undo. Every page is listed with its version before and after the bulk change, its version now, and what undo will do. Nothing has changed yet.
  3. Choose Undo this bulk change, then Put the pages back. Each page goes back to its version before the bulk change with Confluence’s own restore, as a new version, so the page history keeps the bulk change too. A page changed again since is left alone, and so is a page you cannot edit.

Every undo is logged: what happened to each page, by whom and when. Bulk changes can be undone for 90 days. In Rovo, ask the ReplaceGuard agent to list bulk changes in your spaces; undoing one is done on ReplaceGuard’s page, after its preview.

What it changes, and what it never changes

Pages it skips

Large sites

ReplaceGuard works through a large site in batches in the background and saves where it is after each one, so it carries on by itself when you close the page, and waits and tries again when Confluence asks it to slow down. If it cannot carry on by itself, the run says so: open it and press Continue here (it carries on while the page is open) or Carry on in the background.

Good to know