Metadata-Version: 2.4
Name: astro-tasks
Version: 0.2.3
Summary: Pre-flight checklist for developers — GitHub status, coding stats, repo health in one command
Home-page: https://github.com/3ni8ma/astro-tasks
Author: Aarush Karak
License: MIT
Project-URL: Homepage, https://github.com/3ni8ma/astro-tasks
Project-URL: Bug Reports, https://github.com/3ni8ma/astro-tasks/issues
Project-URL: Source, https://github.com/3ni8ma/astro-tasks
Keywords: cli,developer-tools,github,wakatime,productivity,dashboard
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Environment :: Console
Classifier: Topic :: Software Development
Classifier: Topic :: Utilities
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: colorama>=0.4.6
Dynamic: author
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: keywords
Dynamic: license
Dynamic: license-file
Dynamic: project-url
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# Astro Tasks

[![PyPI version](https://img.shields.io/pypi/v/astro-tasks)](https://pypi.org/project/astro-tasks/)
[![Python](https://img.shields.io/pypi/pyversions/astro-tasks)](https://pypi.org/project/astro-tasks/)
[![Downloads](https://static.pepy.tech/badge/astro-tasks)](https://pepy.tech/project/astro-tasks)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![GitHub stars](https://img.shields.io/github/stars/3ni8ma/astro-tasks)](https://github.com/3ni8ma/astro-tasks/stargazers)
[![RepoRanker](https://reporanker.com/badge/3ni8ma/astro-tasks)](https://reporanker.com/repos/3ni8ma/astro-tasks)

> Pre-flight checklist for developers. One command to check GitHub status,
> coding stats, and local repo health before starting work.

![Astro Tasks](https://raw.githubusercontent.com/3ni8ma/astro-tasks/main/docs/Astro-Tasks-thumbnail.png)

## Features

- GitHub notifications + open PRs via `gh` CLI
- Coding stats from WakaTime (last 7 days, top projects, languages)
- Local repo health scan (dirty branches, unpushed commits)

## Quick Start

```bash
pip install astro-tasks
astro check
```

## Commands

| Command | Description |
|---------|-------------|
| `astro check` | Full dashboard: GitHub notifications, open PRs, coding stats, repo health |
| `astro check --json` | Same info as JSON (for piping into other tools) |
| `astro scan` | Scan local repos for dirty branches and unpushed commits |
| `astro log` | Show coding stats from WakaTime (last 7 days) |
| `astro config` | Show current configuration (WakaTime, GitHub auth, tracked repos) |
| `astro --version` | Print version |

## Example

```
>>> ASTRO TASKS <<<
  pre-flight checklist

  [*] GitHub Status
  ------------------------------------------
    [+] Unread notifications: 3
    [+] Open PRs: 1

  [*] Coding Stats (Last 7 Days)
  ------------------------------------------
    [+] Total time: 40 hrs 12 mins
    [+] Daily average: 10 hrs 4 mins
    [+] Active days: 4

  [*] Top Projects
  ------------------------------------------
    [+]   react-hooks: 11 hrs 39 mins
    [+]   TheCoderBros-Website: 10 hrs 23 mins

  [*] Languages
  ------------------------------------------
    [+]   TypeScript: 35 hrs 12 mins
    [+]   Python: 7 hrs 53 mins

  [*] Local Repo Scan
  ------------------------------------------
    [+] cli-tool: branch: main
    [!] 3ni8ma: branch: main | 2 unpushed
```

`astro scan` — repos only, no API calls:

```
  [*] Local Repo Scan
  ------------------------------------------
    [+] 3ni8ma: branch: main | dirty
    [+] cli-tool: branch: main | dirty
    [+] TheCoderBros-Website: branch: main
    [+] aarushkarak-website: branch: main
    [+] react-hooks: branch: main
    [+] tailwind-plugin: branch: main | dirty
    [+] vite-plugin: branch: main | dirty
    [+] astro-tasks: branch: main
```

`astro check --json` — same data, machine-readable (truncated):

```json
{
  "github": {
    "unread_notifications": 3,
    "open_prs_count": 1,
    "open_prs": [
      {"number": 1, "title": "...", "headRefName": "feat", "baseRefName": "main"}
    ],
    "errors": {"notifications": null, "prs": null}
  },
  "coding_stats": {"human_readable_total": "40 hrs 12 mins"},
  "coding_stats_error": null,
  "repos": [
    {"name": "astro-tasks", "branch": "main", "unpushed": 0, "dirty": false, "error": null}
  ]
}
```

## Requirements

- Python 3.8+
- `gh` CLI authenticated (`gh auth status`)
- WakaTime API key in `~/.wakatime.cfg` (`api_url` optional — defaults to `https://wakatime.com/api/v1`)

## Configuration

Out of the box astro-tasks tracks a built-in repo list. To make it yours,
create `~/.config/astro-tasks/config.json`:

```json
{
  "github_user": "octocat",
  "machine_name": "My-Mac",
  "repos": [
    {"name": "demo", "dir": "~/code/demo"}
  ]
}
```

All fields are optional — anything missing falls back to the built-ins.
Environment variables override everything:

| Variable | Overrides |
|----------|-----------|
| `ASTRO_GITHUB_USER` | `github_user` |
| `ASTRO_MACHINE_NAME` | `machine_name` |

Run `astro config` to see which sources are active.

## License

MIT
