ConfluencePS is a PowerShell module that interacts with Atlassian’s wiki product, Confluence. It helps automate bulk operations and repetitive tasks from the command line. For example:
- Create new pages for each row in a CSV
- Move all pages below “Parent Page A” to “Parent Page B” instead
- Delete all pages labeled
- When your environment changes, update the relevant wiki page(s)
There will be a future blog post with a walkthrough of ConfluencePS 2.0, featuring use cases and code examples. But that’ll have to wait until sometime after VMworld 2017 :)
If you are a current user of v1.0, please review the changelog for hopefully all of the details anyone could want.
History and Perspective
In November 2015, I started writing ConfluencePS. I had three main motivations:
- Automating documentation was a huge pain point I was feeling at work
- I hadn’t written/maintained a big-boy PowerShell module yet, and wanted to learn the ins and outs
- I don’t think I’d interacted with any REST API endpoints yet
Let me tell you, writing a module that hits a REST API is a pretty good way to learn how to write modules and how to interact with REST APIs.
In November 2016, ConfluencePS 1.0 finally appeared on the PowerShell Gallery. I held out because I was being a stubborn purist, and wanted to create an automated deployment procedure to publish when the repo was updated. (SPOILER: It worked, but it wasn’t worth the long wait. You should manually publish your repos until that process becomes painful enough to be automated.)
In April 2017, @lipkau found the module. He was already familiar with JiraPS, and started overhauling the ConfluencePS code base (after receiving my enthusiastic blessing). This removed repeat code, made what was left more testable, and aligned it more closely with current-day best practices for API module design. v2.0 is here because of his efforts, which are greatly appreciated.
I was in charge of reviewing the changes and updating the documentation…and here we are in the middle of August, haha.
(Like the open source modules, the org is not affiliated with Atlassian in any way.)
This has been excellent. Friends of the blog know that I love diversity in open source projects and sustainability built into teams, and this change has definitely helped both of those areas.
I’m excited to already see the potential of the AtlassianPS modules coming under a shared stewardship, and am looking forward to what’s next with 2.0 finally out in the world!
Test Drive 2.0
# PowerShell version 5 provides cmdlets to interact with the Gallery: Install-Module ConfluencePS # or Update-Module ConfluencePS Get-Command -Module ConfluencePS Get-Help about_ConfluencePS Get-Help Set-ConfluenceInfo -Full Set-ConfluenceInfo -BaseUri 'https://wiki.example.com' -PromptCredentials Get-ConfluenceSpace
Hope you enjoy, and we’d love to hear from you if you end up trying it out!