Tampermonkey - Old Wiki Link Redirector (for new DevCentral Site)
Problem this snippet solves:
With the rollout of the new DevCentral Wiki, a lot of the old questions, answers and comments on DC include links to wiki articles that not longer work.
In order to mitigate this, I've put together a quick Tampermonkey script to help mitigate this.
This Tampermonkey script matches web requests to the old DevCentral Wiki site (on https://devcentral.f5.com/wiki) and attempts to parse out the pieces in order to redirect the user to the new API docs (on https://clouddocs.f5.com/api) automatically.
If you're using a bookmark for any old wiki pages, be sure to update the links once you're redirected.
How to use this snippet:
- You'll need to install Tampermonkey (if it's not already installed)
- Create a new userscript and paste the content from the CodeShare link.
- If you don't want to to risk the userscript auto updating if the gist gets updated on Github, remove the @updateURL and @downloadURL references in the header*
- Save the file, and open up an old Wiki page to test it (test link). Notice the url changes to the new API docs.
* I will be working on updates to help with links that don't redirect correctly or result in a 404 error.
Tested this on version:No Version Found