Configuration
Environment variables and settings for CROP Linear Archive
All configuration is done via the .env file.
Environment Variables
| Variable | Required | Default | Description |
|---|---|---|---|
LINEAR_API_KEY | Yes | - | Your Linear API key (starts with lin_api_) |
ARCHIVE_DAYS_OLD | No | 7 | Archive issues not updated for N days |
ARCHIVE_STATUSES | No | Archive,Canceled | Comma-separated status names |
Getting Linear API Key
- Go to https://linear.app/settings/api
- Click "Create new API key"
- Give it a name (e.g., "Archive Tool")
- Copy the key (starts with
lin_api_)
Status Names
Common Linear status names:
| Status | Description |
|---|---|
Backlog | Unstarted items |
Todo | Ready to start |
In Progress | Currently being worked on |
Done | Completed |
Canceled | Canceled items |
Archive | Archived items |
Example Configurations
Archive only old archived issues (recommended)
ARCHIVE_DAYS_OLD=14
ARCHIVE_STATUSES=Archive,CanceledArchive all closed issues after 30 days
ARCHIVE_DAYS_OLD=30
ARCHIVE_STATUSES=Done,Archive,CanceledQuick cleanup (7 days)
ARCHIVE_DAYS_OLD=7
ARCHIVE_STATUSES=Archive