Ok, I tried to follow the instructions. I tried to use this command rake plugin:create[pocketbase-auth] inside the container (since rake would not be available outside, right). But, it fails hard because I don’t have git setup inside the container.
As I read further, it appears I need to specify the git repo of the plugin to display a plugin in the admin section. But, I have not gotten to the point where I have even a barely working version of the plugin and I don’t have things inside a git repository.
EDIT: I didn’t read carefully, and indeed this requires a dev setup, which is clearly stated up front. I’ll work on that and come back to this.
I suspect that these struggles are because typically plugins are developed against a “dev” setup of discourse, not inside the docker container which I am running. That’s fine, but I wish the plugin developer guides started with that assumption and instructions on how to run that way. The recommended way to run discourse is using docker (which I love) but I think there is a gap between how to run things inside docker and do development inside the docs.
# rake plugin:create[pocketbase-auth]
Cloning 'https://github.com/discourse/discourse-plugin-skeleton' to '/var/www/discourse/plugins/pocketbase-auth'...
Initializing git repository...
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: git branch -m <name>
Initialized empty Git repository in /var/www/discourse/plugins/pocketbase-auth/.git/
Author identity unknown
*** Please tell me who you are.
Run
git config --global user.email "you@example.com"
git config --global user.name "Your Name"
to set your account's default identity.
Omit --global to set the identity only in this repository.
fatal: unable to auto-detect email address (got 'discourse@community-public-do-vm-app.(none)')
rake aborted!
Command failed with exit 128: git
/var/www/discourse/lib/tasks/plugin.rake:356:in `system'
/var/www/discourse/lib/tasks/plugin.rake:356:in `block (2 levels) in <main>'
/var/www/discourse/lib/tasks/plugin.rake:346:in `chdir'
/var/www/discourse/lib/tasks/plugin.rake:346:in `block in <main>'
/usr/local/bin/bundle:25:in `load'
/usr/local/bin/bundle:25:in `<main>'
Tasks: TOP => plugin:create
(See full trace by running task with --trace)