Azarr Console for VS Code
Pull and push a project's README.md, CHANGELOG.md and source code to the Azarr Console without leaving VS Code. For Azarr staff.
This extension is a thin wrapper around the azarr command (the Azarr CLI). Every action runs the CLI in the project's folder, so it behaves exactly like the terminal and keeps the same safety rules (a push never overwrites someone's console edit silently, an empty file never clears a document, viewers cannot push, a project on hold cannot be changed).
Set up (once)
- Install Node.js 18 or newer, then in any terminal:
npm install -g @azarrapps/console-cli. (If it is missing, the extension offers to install it.)
- Install this extension (see "Install" below).
- In the Console open Settings > Access tokens, create a token and copy it.
- In VS Code run Azarr: Sign in with an access token and paste it. The token is kept in VS Code's secret storage. If you already ran
azarr login in a terminal, you can skip this step.
- Open the project's folder and run Azarr: Link this folder to a project.
Every day
Click Azarr: in the status bar (bottom left) for the list of actions, or use the Command Palette (Ctrl/Cmd + Shift + P, type "Azarr"). While README.md or CHANGELOG.md is open, the title bar has Pull and Push buttons.
| Action |
What it does |
| Pull ReadMe and ChangeLog |
Fetch them into README.md / CHANGELOG.md (and download pictures into assets/) |
| Push ReadMe and ChangeLog |
Save your open files, ask for an optional note, publish, and tell the project |
| Push source code |
Upload the project's source as one archive (secrets such as .env files, keys and certificates are never included) |
| Push ReadMe, ChangeLog and source code |
Both at once |
| Preview a push |
Shows what would be sent, sends nothing |
| Check what is in sync / who changed what |
Same as azarr status and azarr history (shown in the Azarr output panel) |
| Open the project / its source in the Console |
Opens the page in your browser |
The status bar shows the project and a small mark: ↑ you have changes to push, ↓ the console has changes to pull, ↑↓ both. A push never signs off a phase; staff owners see an "Action needed" notice and do that themselves.
Confirmation
Because a pull overwrites files on this computer and a push overwrites what is on the Console, every action that changes something asks first, naming the project it will affect. By default you must type a word (pull, push, push source, push all, overwrite, link) to go ahead; Esc or a wrong word cancels. Previews, status, history and the Open links never ask. Set azarr.confirmActions to dialog for a dialog with a button instead. Confirmation cannot be turned off.
Settings
azarr.cliPath: the full path to the azarr command (or to its azarr.js) if it is not found automatically (for example Node installed with nvm and VS Code started from the dock).
azarr.apiUrl: the Console API address, when it is not the default.
azarr.confirmActions: typeToConfirm (default) or dialog; how pulls, pushes and linking are confirmed.
azarr.consoleUrl: the Console address that "Open in the Console" uses.
Install
Open the Extensions view (Ctrl/Cmd + Shift + X), search for Azarr Console (publisher azarrapps) and press Install.
From a .vsix file instead: in the Extensions view click the ... menu at its top right, choose Install from VSIX... and pick the file (or run code --install-extension <file>.vsix). To build the file: npm run package in this folder.
Develop
Open this folder in VS Code and press F5. npm test runs the tests (the CLI wrapper, and the extension against a stand-in for the VS Code API and a fake azarr).