Compare commits
1 Commits
renovate/a
...
317e90544f
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
317e90544f |
@@ -6,14 +6,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
|
||||
## [Unreleased]
|
||||
|
||||
## [0.5.0] - 2024-12-15
|
||||
|
||||
### Added
|
||||
- allow taking a local path
|
||||
|
||||
### Fixed
|
||||
- *(deps)* update rust crate serde to v1.0.216
|
||||
- *(deps)* update rust crate prost to v0.13.4
|
||||
## [0.4.1] - 2024-12-06
|
||||
|
||||
### Other
|
||||
- *(deps)* update rust crate clap to v4.5.23
|
||||
|
||||
826
Cargo.lock
generated
826
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -14,16 +14,16 @@ tracing = { version = "0.1", features = ["log"] }
|
||||
tracing-subscriber = { version = "0.3.18", features = ["env-filter"] }
|
||||
clap = { version = "4", features = ["derive", "env"] }
|
||||
dotenv = { version = "0.15" }
|
||||
axum = { version = "0.8" }
|
||||
axum = { version = "0.7" }
|
||||
serde = { version = "1.0.202", features = ["derive"] }
|
||||
serde_json = "1.0.117"
|
||||
itertools = "0.14.0"
|
||||
itertools = "0.13.0"
|
||||
uuid = { version = "1.8.0", features = ["v4"] }
|
||||
tonic = { version = "0.12.0", features = ["tls", "tls-roots"] }
|
||||
futures = { version = "0.3.30" }
|
||||
sha2 = { version = "0.10.8" }
|
||||
hex = { version = "0.4.3" }
|
||||
toml = { version = "0.9.0" }
|
||||
toml = { version = "0.8.14" }
|
||||
|
||||
[workspace.package]
|
||||
version = "0.5.0"
|
||||
version = "0.4.1"
|
||||
|
||||
@@ -1,7 +1,5 @@
|
||||
# hyperlog
|
||||
|
||||

|
||||
|
||||
- [x] Display todos as todos
|
||||
- [x] Create sections
|
||||
- [x] Edit todos
|
||||
|
||||
BIN
assets/demo.gif
BIN
assets/demo.gif
Binary file not shown.
|
Before Width: | Height: | Size: 472 KiB |
@@ -2,7 +2,7 @@
|
||||
name = "hyperlog-tui"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
repository = "https://git.kjuulh.io/kjuulh/hyperlog"
|
||||
repository = "https://git.front.kjuulh.io/kjuulh/hyperlog"
|
||||
|
||||
[dependencies]
|
||||
hyperlog-core.workspace = true
|
||||
@@ -23,12 +23,12 @@ hex.workspace = true
|
||||
toml.workspace = true
|
||||
|
||||
ratatui = "0.29.0"
|
||||
crossterm = { version = "0.29.0", features = ["event-stream"] }
|
||||
directories = "6.0.0"
|
||||
crossterm = { version = "0.28.0", features = ["event-stream"] }
|
||||
directories = "5.0.1"
|
||||
human-panic = "2.0.0"
|
||||
ropey = "1.6.1"
|
||||
bus = "2.4.1"
|
||||
dirs = "6.0.0"
|
||||
dirs = "5.0.1"
|
||||
|
||||
[dev-dependencies]
|
||||
similar-asserts = "1.5.0"
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
use std::path::PathBuf;
|
||||
|
||||
use tonic::transport::{Channel, ClientTlsConfig};
|
||||
|
||||
use crate::{
|
||||
@@ -16,18 +14,15 @@ pub struct State {
|
||||
}
|
||||
|
||||
pub enum Backend {
|
||||
Local { path_override: Option<PathBuf> },
|
||||
Local,
|
||||
Remote { url: String },
|
||||
}
|
||||
|
||||
impl State {
|
||||
pub async fn new(backend: Backend) -> anyhow::Result<Self> {
|
||||
let (querier, commander) = match &backend {
|
||||
Backend::Local { path_override } => {
|
||||
let mut storage = Storage::new();
|
||||
if let Some(path_override) = path_override {
|
||||
storage.with_base(path_override);
|
||||
}
|
||||
Backend::Local => {
|
||||
let storage = Storage::new();
|
||||
let engine = storage.load()?;
|
||||
let events = Events::default();
|
||||
let engine = SharedEngine::from(engine);
|
||||
@@ -58,21 +53,15 @@ impl State {
|
||||
}
|
||||
|
||||
pub fn unlock(&self) {
|
||||
if let Backend::Local { path_override } = &self.backend {
|
||||
let mut storage = Storage::new();
|
||||
if let Some(path_override) = path_override {
|
||||
storage.with_base(path_override);
|
||||
}
|
||||
if let Backend::Local = &self.backend {
|
||||
let storage = Storage::new();
|
||||
storage.clear_lock_file();
|
||||
}
|
||||
}
|
||||
|
||||
pub fn info(&self) -> Option<anyhow::Result<String>> {
|
||||
if let Backend::Local { path_override } = &self.backend {
|
||||
let mut storage = Storage::new();
|
||||
if let Some(path_override) = path_override {
|
||||
storage.with_base(path_override);
|
||||
}
|
||||
if let Backend::Local = &self.backend {
|
||||
let storage = Storage::new();
|
||||
return Some(storage.info());
|
||||
}
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
name = "hyperlog"
|
||||
version = "0.1.0"
|
||||
edition = "2021"
|
||||
repository = "https://git.kjuulh.io/kjuulh/hyperlog"
|
||||
repository = "https://git.front.kjuulh.io/kjuulh/hyperlog"
|
||||
|
||||
[dependencies]
|
||||
hyperlog-core.workspace = true
|
||||
@@ -21,7 +21,7 @@ serde_json.workspace = true
|
||||
uuid.workspace = true
|
||||
|
||||
bus = "2.4.1"
|
||||
dirs = "6.0.0"
|
||||
dirs = "5.0.1"
|
||||
|
||||
[dev-dependencies]
|
||||
similar-asserts = "1.5.0"
|
||||
|
||||
@@ -1,5 +1,3 @@
|
||||
use std::path::PathBuf;
|
||||
|
||||
use clap::{Parser, Subcommand, ValueEnum};
|
||||
use hyperlog_tui::{
|
||||
commander,
|
||||
@@ -17,9 +15,6 @@ struct Command {
|
||||
|
||||
#[arg(long = "backend-url", required_if_eq("backend", "remote"))]
|
||||
backend_url: Option<String>,
|
||||
|
||||
#[arg(long = "local-path")]
|
||||
local_path: Option<PathBuf>,
|
||||
}
|
||||
|
||||
#[derive(ValueEnum, Clone)]
|
||||
@@ -95,9 +90,7 @@ pub async fn execute() -> anyhow::Result<()> {
|
||||
let backend_url = cli.backend_url;
|
||||
|
||||
let backend = match backend {
|
||||
BackendArg::Local => Backend::Local {
|
||||
path_override: cli.local_path.clone(),
|
||||
},
|
||||
BackendArg::Local => Backend::Local,
|
||||
BackendArg::Remote => Backend::Remote {
|
||||
url: backend_url.expect("backend-url to be set"),
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# yaml-language-server: $schema=https://git.kjuulh.io/kjuulh/cuddle/raw/branch/main/schemas/base.json
|
||||
# yaml-language-server: $schema=https://git.front.kjuulh.io/kjuulh/cuddle/raw/branch/main/schemas/base.json
|
||||
|
||||
base: "git@git.kjuulh.io:kjuulh/cuddle-rust-service-plan.git"
|
||||
base: "git@git.front.kjuulh.io:kjuulh/cuddle-rust-service-plan.git"
|
||||
|
||||
vars:
|
||||
service: "hyperlog"
|
||||
@@ -35,7 +35,7 @@ please:
|
||||
repository: hyperlog
|
||||
branch: main
|
||||
settings:
|
||||
api_url: https://git.kjuulh.io
|
||||
api_url: https://git.front.kjuulh.io
|
||||
actions:
|
||||
rust:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user