Skip to content

speedshop/cgrp-slack-export

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Slack Export Archive

Local tooling to maintain a merged Slack export archive, build browsable outputs, and publish the latest export ZIP to Cloudflare R2.

Repo layout

  • archive/ — merged Slack export data (living archive)
  • imports/ — raw export ZIPs
  • dist/ — generated viewer + markdown outputs for qmd-style indexing
  • lib/ — task implementations called by mise
  • mise.toml — tool versions + task entrypoints

1) Setup tools

mise run setup

mise run setup checks/installs tools from mise.toml (Python, AWS CLI), initializes submodules, and checks dependencies.

2) Configure secrets with .env

cp .env.example .env

Fill in real values for:

  • R2 account + upload endpoint settings
  • R2 upload keypair (Read & Write token)
  • bucket/object names (defaults already set)

mise run upload automatically loads .env.

3) Monthly workflow

One-shot publish (recommended)

mise run publish -- imports/monthly-2026-05.zip

Use mise run publish -- --skip-merge when archive/ is already up to date and you only want build + upload.

Or run steps manually

mise run merge -- imports/monthly-2026-05.zip
mise run build
mise run upload

Markdown export for qmd

mise run build now writes a qmd-friendly markdown corpus into:

  • dist/archive.md — top-level index file
  • dist/markdown/<channel>/<YYYY-MM>.md — monthly channel documents

These files are structured for local indexing tools like qmd: real headings, smaller documents, and newest-first message ordering.

Upload behavior

mise run upload creates railsperf-export-latest.zip from dist/ (falls back to .tar if zip is unavailable), then uploads via:

  1. R2_PRESIGNED_PUT_URL + curl, or
  2. AWS CLI to https://<ACCOUNT_ID>.r2.cloudflarestorage.com using:
    • R2_ACCOUNT_ID
    • R2_UPLOAD_ACCESS_KEY_ID
    • R2_UPLOAD_SECRET_ACCESS_KEY

Merge behavior

  • users.json merged by id (incoming wins)
  • channels.json merged by id (incoming wins)
  • per-day channel files merged by message ts
  • excluded channels: #random, #introductions
  • idempotent when re-merging same export

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors