chore(meetup): replace in-repo Meetup scripts with published coopkit action#62
Open
duxi90 wants to merge 1 commit into
Open
chore(meetup): replace in-repo Meetup scripts with published coopkit action#62duxi90 wants to merge 1 commit into
duxi90 wants to merge 1 commit into
Conversation
…action Dogfood our published Marketplace action cppserbia/coopkit-meetup-action@v1 (v1.1.0, wrapping @coopkit/meetup) instead of maintaining a duplicate copy of the OAuth/GraphQL event-creation code in-repo. The PR-driven flow is preserved exactly: label `meetup-event` -> create draft -> write event_url/event_id back -> commit -> comment. v1.1.0 now exposes status/event-id/event-url outputs, so the writeback works with the composite action. - coopkit.config.json: group + venue map (ported from scripts/meetup/venues.ts) - scripts/meetup-pr-event.ts (+test): thin glue, no Meetup API code — `inputs` maps frontmatter to action inputs (+ already-created idempotency flag), `writeback` persists the action outputs to the event file - .github/workflows/meetup-event-draft.yml: calls the action, consumes outputs - download-meetup-images.ts: now imports createMeetupClient from @coopkit/meetup - delete scripts/meetup/ and scripts/create-meetup-event.ts (+test) - package.json: add @coopkit/meetup; drop jsonwebtoken (+types), now transitive - docs (CLAUDE.md, scripts/README.md, CONTRIBUTING.md) + cspell terms Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What & why
We published
cppserbia/coopkit-meetup-action(Marketplace) wrapping the@coopkit/meetupnpm package — itself an extraction of this repo'sscripts/meetup/*+scripts/create-meetup-event.ts. Keeping both was pure duplication. This PR dogfoods the published action and deletes the redundant in-repo Meetup OAuth/GraphQL code (~1000 lines).The PR-driven flow is preserved exactly: label
meetup-event→ create draft → writeevent_url/event_idback → commit → comment. This is possible becausecoopkit-meetup-action@v1.1.0now exposesstatus/event-id/event-url/photo-attachedoutputs (running@coopkit/meetup@0.2.0with--output), so the writeback works with the composite action.Changes
coopkit.config.json(new) —meetup.groupUrlname(cpp-serbia) + venue map, ported verbatim fromscripts/meetup/venues.ts.scripts/meetup-pr-event.ts(+test, new) — thin glue, no Meetup API code.inputs <file>maps frontmatter → action inputs (canonical UTC date, H1-stripped description) and flagsalready-createdfor idempotency (the action'screate-from-jsonis not idempotent);writeback <file>persists the action's outputs into the event frontmatter. ReusesstripLeadingHeading/isEventAlreadyCreatedfrom@coopkit/meetup..github/workflows/meetup-event-draft.yml— keeps trigger/gating/find-file; drops the manual PEM handling (the action takes the key as input); callscppserbia/coopkit-meetup-action@v1; writeback + commit + comment gated onstatus == 'created'; create step skipped whenalready-created.scripts/download-meetup-images.ts— importscreateMeetupClientfrom@coopkit/meetup(+loadEnvFile()); sameMEETUP_*env contract.scripts/meetup/andscripts/create-meetup-event.ts(+test).package.json— add@coopkit/meetup ^0.2.0; removejsonwebtoken+@types/jsonwebtoken(now transitive). Lockfile regenerated with pnpm 9 (lockfileVersion 9.0).coopkit,bunx,writeback).Verification
typecheck·test(660) ·spell·lint·format:checkpnpm install --frozen-lockfile(CI parity)already-createdflagReviewer notes / before merge
MEETUP_GROUP_URLNAMErepo variable is now unused (group lives in config) — safe to remove from repo settings.MEETUP_*secrets are unchanged; they're piped into the action.meetup-eventto confirm draft + writeback commit + comment, then delete the resulting draft.🤖 Generated with Claude Code