Guidance for coding agents working in org-gcal.el.
- This repo provides Emacs Lisp integration between Org mode and Google Calendar.
- Main implementation files:
org-gcal.el(sync, fetch, post, delete, OAuth/token flow, entry updates)org-generic-id.el(generic Org property ID index/find/update support)
- Main docs:
README.org. - Tests:
test/org-gcal-test.el,test/org-generic-id-test.el.
- Install/update dependencies:
make elpa
- Compile:
make compile
- Run tests:
make test
- Clean generated artifacts/deps cache:
make clean
- Full local check (same default as CI intent):
make
Notes:
- The project uses Cask (
Cask,maketargets). - Prefer running
make compileandmake testbefore finishing changes.
- Keep
-*- lexical-binding: t -*-in source/test files. - Public names use repo prefixes:
org-gcal-...org-generic-id-...
- Internal helpers use double-dash names:
org-gcal--...org-generic-id--...
- User-facing configuration belongs in
defcustomunder existing groups (org-gcal,org-generic-id) with clear docstrings and correct:type. - Preserve standard file structure: headers,
;;; Commentary:,;;; Code:, and(provide '...)footer.
- Preserve Org entry semantics documented in
README.org:- Property keys such as
calendar-id,ETag,ID/entry-idsemantics. - Drawer semantics for
org-gcalcontents and timestamps.
- Property keys such as
- Avoid changing persisted token/id data format unless explicitly required.
- Keep compatibility with supported Emacs versions in CI matrix (Emacs 26+).
- Existing async stack uses
aio,deferred, andrequest-deferred; follow local patterns instead of introducing new async abstractions. - In tests, mock network/OAuth boundaries (
request-deferred, token refresh/getters). Do not require live Google API access.
- Prefer ERT coverage for behavior changes in parsing, entry mutation, sync/post/delete logic, and ID lookup behavior.
- Reuse existing test helpers/macros and patterns (
with-temp-buffer,org-mode,with-mock, temp files). test/org-gcal-test.elintentionally includes tests marked:expected-result :failed; do not treat them as accidental breakage without confirming intent.
- Make the smallest viable change.
- Update or add tests when behavior changes.
- Run:
make compilemake test
- If behavior visible to users changes, update
README.orgaccordingly. - Do not edit generated
.elcfiles by hand. - If modifying
.github/workflows/main.ymlor other Github Action files, useactionlintto check for errors, attempting to install it if not present.