ghzinga 0.5.0

Terminal UI for monitoring GitHub pull requests and issues.
Documentation
use std::{fs, path::Path};

use anyhow::Context;

use crate::domain::Resource;

pub mod api;
mod auth;
pub mod mutations;
mod public_rest;
mod queries;
mod transport;

pub fn load_fixture(path: &Path) -> anyhow::Result<Resource> {
    let raw = fs::read_to_string(path)
        .with_context(|| format!("failed to read fixture {}", path.display()))?;
    serde_json::from_str(&raw)
        .with_context(|| format!("failed to parse fixture {}", path.display()))
}