Author SHA1 Message Date
reya e3c2dd280c ngit compatible
Rust / build (macos-latest, stable) (push) Canceled after 0s
Rust / build (ubuntu-latest, stable) (push) Canceled after 0s
Rust / build (windows-latest, stable) (push) Canceled after 0s
2026-09-14 09:12:35 +07:00
reya 9fbd1c9dfa update 2026-09-14 09:05:57 +07:00
reya c6ada10afa update sidebar 2026-09-14 08:56:32 +07:00
reya 1a13d4e0d7 update 2026-09-14 08:50:15 +07:00
reya e556654be8 add nip34 detector 2026-09-14 08:44:19 +07:00
reya 037728ffe9 extract local repos 2026-09-14 08:08:19 +07:00
21 changed files with 410 additions and 514 deletions
Vendored
BIN
View File
Binary file not shown.
+1 -1
View File
@@ -159,7 +159,7 @@ jobs:
id: create_release id: create_release
uses: akkuman/gitea-release-action@v1 uses: akkuman/gitea-release-action@v1
with: with:
server_url: "https://git.reya.info/" server_url: "https://git.reya.su/"
repository: "reya/signed" repository: "reya/signed"
token: ${{ secrets.GITEA_TOKEN }} token: ${{ secrets.GITEA_TOKEN }}
draft: true draft: true
+1 -1
View File
@@ -6,7 +6,7 @@ dist/
# Snap and Flatpak local build output # Snap and Flatpak local build output
/snap /snap
/info.reya.signed.json /su.reya.signed.json
/linux-artifacts /linux-artifacts
# Vendored dependencies + cargo config generated by script/prepare-flathub # Vendored dependencies + cargo config generated by script/prepare-flathub
+174
View File
@@ -0,0 +1,174 @@
# Rust coding guidelines
* Prioritize code correctness and clarity. Speed and efficiency are secondary priorities unless otherwise specified.
* Do not write organizational or comments that summarize the code. Comments should only be written in order to explain "why" the code is written in some way in the case there is a reason that is tricky / non-obvious.
* Prefer implementing functionality in existing files unless it is a new logical component. Avoid creating many small files.
* Avoid using functions that panic like `unwrap()`, instead use mechanisms like `?` to propagate errors.
* Be careful with operations like indexing which may panic if the indexes are out of bounds.
* Never silently discard errors with `let _ =` on fallible operations. Always handle errors appropriately:
- Propagate errors with `?` when the calling function should handle them
- Use `.log_err()` or similar when you need to ignore errors but want visibility
- Use explicit error handling with `match` or `if let Err(...)` when you need custom logic
- Example: avoid `let _ = client.request(...).await?;` - use `client.request(...).await?;` instead
* When implementing async operations that may fail, ensure errors propagate to the UI layer so users get meaningful feedback.
* Avoid creative additions unless explicitly requested
* Use full words for variable names (no abbreviations like "q" for "queue")
* Use variable shadowing to scope clones in async contexts for clarity, minimizing the lifetime of borrowed references.
Example:
```rust
executor.spawn({
let task_ran = task_ran.clone();
async move {
*task_ran.borrow_mut() = true;
}
});
```
# Timers in tests
* In GPUI tests, prefer GPUI executor timers over `smol::Timer::after(...)` when you need timeouts, delays, or to drive `run_until_parked()`:
- Use `cx.background_executor().timer(duration).await` (or `cx.background_executor.timer(duration).await` in `TestAppContext`) so the work is scheduled on GPUI's dispatcher.
- Avoid `smol::Timer::after(...)` for test timeouts when you rely on `run_until_parked()`, because it may not be tracked by GPUI's scheduler and can lead to "nothing left to run" when pumping.
# GPUI
GPUI is a UI framework which also provides primitives for state and concurrency management.
## Context
Context types allow interaction with global state, windows, entities, and system services. They are typically passed to functions as the argument named `cx`. When a function takes callbacks they come after the `cx` parameter.
* `App` is the root context type, providing access to global state and read and update of entities.
* `Context<T>` is provided when updating an `Entity<T>`. This context dereferences into `App`, so functions which take `&App` can also take `&Context<T>`.
* `AsyncApp` and `AsyncWindowContext` are provided by `cx.spawn` and `cx.spawn_in`. These can be held across await points.
## `Window`
`Window` provides access to the state of an application window. It is passed to functions as an argument named `window` and comes before `cx` when present. It is used for managing focus, dispatching actions, directly drawing, getting user input state, etc.
## Entities
An `Entity<T>` is a handle to state of type `T`. With `thing: Entity<T>`:
* `thing.entity_id()` returns `EntityId`
* `thing.downgrade()` returns `WeakEntity<T>`
* `thing.read(cx: &App)` returns `&T`.
* `thing.read_with(cx, |thing: &T, cx: &App| ...)` returns the closure's return value.
* `thing.update(cx, |thing: &mut T, cx: &mut Context<T>| ...)` allows the closure to mutate the state, and provides a `Context<T>` for interacting with the entity. It returns the closure's return value.
* `thing.update_in(cx, |thing: &mut T, window: &mut Window, cx: &mut Context<T>| ...)` takes a `AsyncWindowContext` or `VisualTestContext`. It's the same as `update` while also providing the `Window`.
Within the closures, the inner `cx` provided to the closure must be used instead of the outer `cx` to avoid issues with multiple borrows.
Trying to update an entity while it's already being updated must be avoided as this will cause a panic.
`WeakEntity<T>` is a weak handle. It has `read_with`, `update`, and `update_in` methods that work the same, but always return an `anyhow::Result` so that they can fail if the entity no longer exists. This can be useful to avoid memory leaks - if entities have mutually recursive handles to each other they will never be dropped.
## Concurrency
All use of entities and UI rendering occurs on a single foreground thread.
`cx.spawn(async move |cx| ...)` runs an async closure on the foreground thread. Within the closure, `cx` is `&mut AsyncApp`.
When the outer cx is a `Context<T>`, the use of `spawn` instead looks like `cx.spawn(async move |this, cx| ...)`, where `this: WeakEntity<T>` and `cx: &mut AsyncApp`.
To do work on other threads, `cx.background_spawn(async move { ... })` is used. Often this background task is awaited on by a foreground task which uses the results to update state.
Both `cx.spawn` and `cx.background_spawn` return a `Task<R>`, which is a future that can be awaited upon. If this task is dropped, then its work is cancelled. To prevent this one of the following must be done:
* Awaiting the task in some other async context.
* Detaching the task via `task.detach()` or `task.detach_and_log_err(cx)`, allowing it to run indefinitely.
* Storing the task in a field, if the work should be halted when the struct is dropped.
A task which doesn't do anything but provide a value can be created with `Task::ready(value)`.
## Elements
The `Render` trait is used to render some state into an element tree that is laid out using flexbox layout. An `Entity<T>` where `T` implements `Render` is sometimes called a "view".
Example:
```
struct TextWithBorder(SharedString);
impl Render for TextWithBorder {
fn render(&mut self, _window: &mut Window, _cx: &mut Context<Self>) -> impl IntoElement {
div().border_1().child(self.0.clone())
}
}
```
Since `impl IntoElement for SharedString` exists, it can be used as an argument to `child`. `SharedString` is used to avoid copying strings, and is either an `&'static str` or `Arc<str>`.
UI components that are constructed just to be turned into elements can instead implement the `RenderOnce` trait, which is similar to `Render`, but its `render` method takes ownership of `self` and receives `&mut App` instead of `&mut Context<Self>`. Types that implement this trait can use `#[derive(IntoElement)]` to use them directly as children.
The style methods on elements are similar to those used by Tailwind CSS.
If some attributes or children of an element tree are conditional, `.when(condition, |this| ...)` can be used to run the closure only when `condition` is true. Similarly, `.when_some(option, |this, value| ...)` runs the closure when the `Option` has a value.
## Input events
Input event handlers can be registered on an element via methods like `.on_click(|event, window, cx: &mut App| ...)`.
Often event handlers will want to update the entity that's in the current `Context<T>`. The `cx.listener` method provides this - its use looks like `.on_click(cx.listener(|this: &mut T, event, window, cx: &mut Context<T>| ...)`.
## Actions
Actions are dispatched via user keyboard interaction or in code via `window.dispatch_action(SomeAction.boxed_clone(), cx)` or `focus_handle.dispatch_action(&SomeAction, window, cx)`.
Actions with no data are defined with the `actions!(some_namespace, [SomeAction, AnotherAction])` macro call. Otherwise the `Action` derive macro is used. Doc comments on actions are displayed to the user.
Action handlers can be registered on an element via the event handler `.on_action(|action, window, cx| ...)`. Like other event handlers, this is often used with `cx.listener`.
## Notify
When a view's state has changed in a way that may affect its rendering, it should call `cx.notify()`. This will cause the view to be rerendered. It will also cause any observe callbacks registered for the entity with `cx.observe` to be called.
## Entity events
While updating an entity (`cx: Context<T>`), it can emit an event using `cx.emit(event)`. Entities register which events they can emit by declaring `impl EventEmitter<EventType> for EntityType {}`.
Other entities can then register a callback to handle these events by doing `cx.subscribe(other_entity, |this, other_entity, event, cx| ...)`. This will return a `Subscription` which deregisters the callback when dropped. Typically `cx.subscribe` happens when creating a new entity and the subscriptions are stored in a `_subscriptions: Vec<Subscription>` field.
# Pull request hygiene
When an agent opens or updates a pull request, it must:
- Use a clear, correctly capitalized, imperative PR title (for example, `Fix crash in project panel`).
- Avoid conventional commit prefixes in PR titles (`fix:`, `feat:`, `docs:`, etc.).
- Avoid trailing punctuation in PR titles.
- Optionally prefix the title with a crate name when one crate is the clear scope (for example, `git_ui: Add history view`).
- Include a `Release Notes:` section as the final section in the PR body.
- Use one bullet under `Release Notes:`:
- `- Added ...`, `- Fixed ...`, or `- Improved ...` for user-facing changes, or
- `- N/A` for docs-only and other non-user-facing changes.
- Format release notes exactly with a blank line after the heading, for example:
```
Release Notes:
- N/A
```
# Rules Hygiene
These `.rules` files are read by every agent session. Keep them high-signal.
## After any agentic session
If you discover a non-obvious pattern that would help future sessions, include a **"Suggested .rules additions"** heading in your PR description with the proposed text. Do **not** edit `.rules` inline during normal feature/fix work. Reviewers decide what gets merged.
## High bar for new rules
Editing or clarifying existing rules is always welcome. New rules must meet **all three** criteria:
1. **Non-obvious** — someone familiar with the codebase would still get it wrong without the rule.
2. **Repeatedly encountered** — it came up more than once (multiple hits in one session counts).
3. **Specific enough to act on** — a concrete instruction, not a vague principle.
Rules that apply to a single crate belong in that crate's own `.rules` file, not the repo root.
## What NOT to put in `.rules`
Avoid architectural descriptions of a crate (module layout, data flow, key types). These go stale fast and the agent can gather them by reading the code. Rules should be **traps to avoid**, not **maps to follow**.
## No drive-by additions
Rules emerge from validated patterns, not one-off observations. The workflow is:
1. Agent notes a pattern during a session.
2. Team validates the pattern in code review.
3. A dedicated commit adds the rule with context on *why* it exists.
+1 -150
View File
@@ -1,150 +1 @@
# Rust coding guidelines .rules
* Prioritize code correctness and clarity. Speed and efficiency are secondary priorities unless otherwise specified.
* Do not write organizational or comments that summarize the code. Comments should only be written in order to explain "why" the code is written in some way in the case there is a reason that is tricky / non-obvious.
* Prefer implementing functionality in existing files unless it is a new logical component. Avoid creating many small files.
* Avoid using functions that panic like `unwrap()`, instead use mechanisms like `?` to propagate errors.
* Be careful with operations like indexing which may panic if the indexes are out of bounds.
* Never silently discard errors with `let _ =` on fallible operations. Always handle errors appropriately:
- Propagate errors with `?` when the calling function should handle them
- Use `.log_err()` or similar when you need to ignore errors but want visibility
- Use explicit error handling with `match` or `if let Err(...)` when you need custom logic
- Example: avoid `let _ = client.request(...).await?;` - use `client.request(...).await?;` instead
* When implementing async operations that may fail, ensure errors propagate to the UI layer so users get meaningful feedback.
* Avoid creative additions unless explicitly requested
* Use full words for variable names (no abbreviations like "q" for "queue")
* Use variable shadowing to scope clones in async contexts for clarity, minimizing the lifetime of borrowed references.
Example:
```rust
executor.spawn({
let task_ran = task_ran.clone();
async move {
*task_ran.borrow_mut() = true;
}
});
```
# Timers in tests
* In GPUI tests, prefer GPUI executor timers over `smol::Timer::after(...)` when you need timeouts, delays, or to drive `run_until_parked()`:
- Use `cx.background_executor().timer(duration).await` (or `cx.background_executor.timer(duration).await` in `TestAppContext`) so the work is scheduled on GPUI's dispatcher.
- Avoid `smol::Timer::after(...)` for test timeouts when you rely on `run_until_parked()`, because it may not be tracked by GPUI's scheduler and can lead to "nothing left to run" when pumping.
# GPUI
GPUI is a UI framework which also provides primitives for state and concurrency management.
## Context
Context types allow interaction with global state, windows, entities, and system services. They are typically passed to functions as the argument named `cx`. When a function takes callbacks they come after the `cx` parameter.
* `App` is the root context type, providing access to global state and read and update of entities.
* `Context<T>` is provided when updating an `Entity<T>`. This context dereferences into `App`, so functions which take `&App` can also take `&Context<T>`.
* `AsyncApp` and `AsyncWindowContext` are provided by `cx.spawn` and `cx.spawn_in`. These can be held across await points.
## `Window`
`Window` provides access to the state of an application window. It is passed to functions as an argument named `window` and comes before `cx` when present. It is used for managing focus, dispatching actions, directly drawing, getting user input state, etc.
## Entities
An `Entity<T>` is a handle to state of type `T`. With `thing: Entity<T>`:
* `thing.entity_id()` returns `EntityId`
* `thing.downgrade()` returns `WeakEntity<T>`
* `thing.read(cx: &App)` returns `&T`.
* `thing.read_with(cx, |thing: &T, cx: &App| ...)` returns the closure's return value.
* `thing.update(cx, |thing: &mut T, cx: &mut Context<T>| ...)` allows the closure to mutate the state, and provides a `Context<T>` for interacting with the entity. It returns the closure's return value.
* `thing.update_in(cx, |thing: &mut T, window: &mut Window, cx: &mut Context<T>| ...)` takes a `AsyncWindowContext` or `VisualTestContext`. It's the same as `update` while also providing the `Window`.
Within the closures, the inner `cx` provided to the closure must be used instead of the outer `cx` to avoid issues with multiple borrows.
Trying to update an entity while it's already being updated must be avoided as this will cause a panic.
`WeakEntity<T>` is a weak handle. It has `read_with`, `update`, and `update_in` methods that work the same, but always return an `anyhow::Result` so that they can fail if the entity no longer exists. This can be useful to avoid memory leaks - if entities have mutually recursive handles to each other they will never be dropped.
## Concurrency
All use of entities and UI rendering occurs on a single foreground thread.
`cx.spawn(async move |cx| ...)` runs an async closure on the foreground thread. Within the closure, `cx` is `&mut AsyncApp`.
When the outer cx is a `Context<T>`, the use of `spawn` instead looks like `cx.spawn(async move |this, cx| ...)`, where `this: WeakEntity<T>` and `cx: &mut AsyncApp`.
To do work on other threads, `cx.background_spawn(async move { ... })` is used. Often this background task is awaited on by a foreground task which uses the results to update state.
Both `cx.spawn` and `cx.background_spawn` return a `Task<R>`, which is a future that can be awaited upon. If this task is dropped, then its work is cancelled. To prevent this one of the following must be done:
* Awaiting the task in some other async context.
* Detaching the task via `task.detach()` or `task.detach_and_log_err(cx)`, allowing it to run indefinitely.
* Storing the task in a field, if the work should be halted when the struct is dropped.
A task which doesn't do anything but provide a value can be created with `Task::ready(value)`.
## Elements
The `Render` trait is used to render some state into an element tree that is laid out using flexbox layout. An `Entity<T>` where `T` implements `Render` is sometimes called a "view".
Example:
```
struct TextWithBorder(SharedString);
impl Render for TextWithBorder {
fn render(&mut self, _window: &mut Window, _cx: &mut Context<Self>) -> impl IntoElement {
div().border_1().child(self.0.clone())
}
}
```
Since `impl IntoElement for SharedString` exists, it can be used as an argument to `child`. `SharedString` is used to avoid copying strings, and is either an `&'static str` or `Arc<str>`.
UI components that are constructed just to be turned into elements can instead implement the `RenderOnce` trait, which is similar to `Render`, but its `render` method takes ownership of `self` and receives `&mut App` instead of `&mut Context<Self>`. Types that implement this trait can use `#[derive(IntoElement)]` to use them directly as children.
The style methods on elements are similar to those used by Tailwind CSS.
If some attributes or children of an element tree are conditional, `.when(condition, |this| ...)` can be used to run the closure only when `condition` is true. Similarly, `.when_some(option, |this, value| ...)` runs the closure when the `Option` has a value.
## Input events
Input event handlers can be registered on an element via methods like `.on_click(|event, window, cx: &mut App| ...)`.
Often event handlers will want to update the entity that's in the current `Context<T>`. The `cx.listener` method provides this - its use looks like `.on_click(cx.listener(|this: &mut T, event, window, cx: &mut Context<T>| ...)`.
## Actions
Actions are dispatched via user keyboard interaction or in code via `window.dispatch_action(SomeAction.boxed_clone(), cx)` or `focus_handle.dispatch_action(&SomeAction, window, cx)`.
Actions with no data are defined with the `actions!(some_namespace, [SomeAction, AnotherAction])` macro call. Otherwise the `Action` derive macro is used. Doc comments on actions are displayed to the user.
Action handlers can be registered on an element via the event handler `.on_action(|action, window, cx| ...)`. Like other event handlers, this is often used with `cx.listener`.
## Notify
When a view's state has changed in a way that may affect its rendering, it should call `cx.notify()`. This will cause the view to be rerendered. It will also cause any observe callbacks registered for the entity with `cx.observe` to be called.
## Entity events
While updating an entity (`cx: Context<T>`), it can emit an event using `cx.emit(event)`. Entities register which events they can emit by declaring `impl EventEmitter<EventType> for EntityType {}`.
Other entities can then register a callback to handle these events by doing `cx.subscribe(other_entity, |this, other_entity, event, cx| ...)`. This will return a `Subscription` which deregisters the callback when dropped. Typically `cx.subscribe` happens when creating a new entity and the subscriptions are stored in a `_subscriptions: Vec<Subscription>` field.
# Pull request hygiene
When an agent opens or updates a pull request, it must:
- Use a clear, correctly capitalized, imperative PR title (for example, `fix crash in project panel`).
- Avoid conventional commit prefixes in PR titles (`fix:`, `feat:`, `docs:`, etc.).
- Avoid trailing punctuation in PR titles.
- Optionally prefix the title with a crate name when one crate is the clear scope (for example, `workspace: add history view`).
- Include a `Release Notes:` section as the final section in the PR body.
- Use one bullet under `Release Notes:`:
- `- Added ...`, `- Fixed ...`, or `- Improved ...` for user-facing changes, or
- `- N/A` for docs-only and other non-user-facing changes.
- Format release notes exactly with a blank line after the heading, for example:
```
Release Notes:
- N/A
```
-33
View File
@@ -1,33 +0,0 @@
# Changelog
## Unreleased
### Breaking changes
### Added
### Changed
### Fixed
### Removed
### Deprecated
## v0.1.0-alpha - 2026/09/14
Initial alpha release.
### Added
- Create and unlock a passphrase-protected Nostr identity
- Browse and search NIP-34 repositories with All, Popular and Recent filters
- Scan local Git repositories and detect their NIP-34 and GRASP bindings
- Create, publish, clone and open repositories
- Repository view with files, commit history, branches and tags
- Colour-coded commit diffs
- Issues and pull requests with discussions
- Send patches and push branches
- Inbox for repository activity
- Settings for appearance, theme, GRASP servers and repository scan paths
- Release and packaging infrastructure
Generated
+72 -82
View File
@@ -913,9 +913,9 @@ dependencies = [
[[package]] [[package]]
name = "bytemuck_derive" name = "bytemuck_derive"
version = "1.12.1" version = "1.12.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6a1f896587b6f2c069c73d2f0913e2d590c3990285cd2f0b6aa02b786b4c679c" checksum = "fc0e56a716f1e132ff6bf4bdac1c944a3fcdc1cae65f70a4a2a1ac3b401d2d1f"
dependencies = [ dependencies = [
"proc-macro2", "proc-macro2",
"quote", "quote",
@@ -1222,7 +1222,7 @@ dependencies = [
[[package]] [[package]]
name = "collections" name = "collections"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"gpui_util", "gpui_util",
"indexmap", "indexmap",
@@ -1511,9 +1511,9 @@ dependencies = [
[[package]] [[package]]
name = "crc32fast" name = "crc32fast"
version = "1.5.2" version = "1.5.1"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "01a7799fd6b852db0e61728dde9a204c423b44d689dbd432522543614b490e78" checksum = "8498c871161e1742aaa9d52551b2d6ebdd4c3d45a3be423e3728f33b955be550"
dependencies = [ dependencies = [
"cfg-if", "cfg-if",
] ]
@@ -1694,7 +1694,7 @@ dependencies = [
[[package]] [[package]]
name = "derive_refineable" name = "derive_refineable"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"proc-macro2", "proc-macro2",
"quote", "quote",
@@ -1865,7 +1865,7 @@ dependencies = [
"cc", "cc",
"memchr", "memchr",
"rustc_version", "rustc_version",
"toml 1.1.6+spec-1.1.0", "toml 1.1.5+spec-1.1.0",
"vswhom", "vswhom",
"winreg", "winreg",
] ]
@@ -3539,7 +3539,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui" name = "gpui"
version = "0.2.2" version = "0.2.2"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"accesskit", "accesskit",
"anyhow", "anyhow",
@@ -3747,7 +3747,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_apple" name = "gpui_apple"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"block", "block",
@@ -3764,14 +3764,13 @@ dependencies = [
"log", "log",
"metal", "metal",
"objc", "objc",
"objc2 0.6.4",
"parking_lot", "parking_lot",
] ]
[[package]] [[package]]
name = "gpui_linux" name = "gpui_linux"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"accesskit", "accesskit",
"accesskit_unix", "accesskit_unix",
@@ -3817,7 +3816,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_macos" name = "gpui_macos"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"accesskit", "accesskit",
"accesskit_macos", "accesskit_macos",
@@ -3849,7 +3848,6 @@ dependencies = [
"objc2 0.6.4", "objc2 0.6.4",
"objc2-app-kit 0.3.2", "objc2-app-kit 0.3.2",
"objc2-foundation 0.3.2", "objc2-foundation 0.3.2",
"objc2-screen-capture-kit",
"objc2-user-notifications", "objc2-user-notifications",
"parking_lot", "parking_lot",
"pathfinder_geometry", "pathfinder_geometry",
@@ -3864,7 +3862,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_macros" name = "gpui_macros"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"heck 0.5.0", "heck 0.5.0",
"proc-macro2", "proc-macro2",
@@ -3875,7 +3873,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_platform" name = "gpui_platform"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"console_error_panic_hook", "console_error_panic_hook",
"gpui", "gpui",
@@ -3888,7 +3886,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_shared_string" name = "gpui_shared_string"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"schemars", "schemars",
"serde", "serde",
@@ -3898,7 +3896,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_util" name = "gpui_util"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"log", "log",
@@ -3908,7 +3906,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_web" name = "gpui_web"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"console_error_panic_hook", "console_error_panic_hook",
@@ -3921,10 +3919,6 @@ dependencies = [
"parking_lot", "parking_lot",
"raw-window-handle", "raw-window-handle",
"scheduler", "scheduler",
"smallvec",
"unicode-properties",
"unicode-script",
"unicode-segmentation",
"uuid", "uuid",
"wasm-bindgen", "wasm-bindgen",
"wasm-bindgen-futures", "wasm-bindgen-futures",
@@ -3936,7 +3930,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_wgpu" name = "gpui_wgpu"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"bytemuck", "bytemuck",
@@ -3962,7 +3956,7 @@ dependencies = [
[[package]] [[package]]
name = "gpui_windows" name = "gpui_windows"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"accesskit", "accesskit",
"accesskit_windows", "accesskit_windows",
@@ -3989,9 +3983,9 @@ dependencies = [
[[package]] [[package]]
name = "granit-parser" name = "granit-parser"
version = "1.2.1" version = "1.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "48aa83cc6ac4dc610adf5501a5392b4bcc543b2c1f24eaf77469a96e31ec9abe" checksum = "65ec0d45986cd51c847c75c5b69a00852c4fc84d0e5e79f041173f73437d0cdf"
dependencies = [ dependencies = [
"arraydeque", "arraydeque",
"smallvec", "smallvec",
@@ -4266,7 +4260,7 @@ dependencies = [
[[package]] [[package]]
name = "http_client" name = "http_client"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"async-compression", "async-compression",
@@ -4286,7 +4280,7 @@ dependencies = [
[[package]] [[package]]
name = "http_client_tls" name = "http_client_tls"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"log", "log",
"rustls", "rustls",
@@ -4729,9 +4723,9 @@ checksum = "8f42a60cbdf9a97f5d2305f08a87dc4e09308d1276d28c869c684d7777685682"
[[package]] [[package]]
name = "jiff" name = "jiff"
version = "0.2.37" version = "0.2.35"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0ab1baf72f08796de0260609515130699b890ac25f30e610ad894bc5856cafdb" checksum = "668b7183bd07af9a4885f5c35b0cc5c83c4607a913c16b7e17291832910d2dcc"
dependencies = [ dependencies = [
"defmt", "defmt",
"jiff-core", "jiff-core",
@@ -4746,19 +4740,18 @@ dependencies = [
[[package]] [[package]]
name = "jiff-core" name = "jiff-core"
version = "0.1.1" version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "5e52fe76043ccecc9005d2305ebaadf7d7fc0cc89ca6baa10a94d6bc68c7128c" checksum = "7feca88439efe53da3754500c1851dedf3cb36c524dd5cf8225cc0794de95d09"
dependencies = [ dependencies = [
"defmt", "defmt",
"log",
] ]
[[package]] [[package]]
name = "jiff-static" name = "jiff-static"
version = "0.2.37" version = "0.2.35"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "378268a1116ad67ae6228701118ac9f491d78fda38a40a1f1a9e1348de6f7212" checksum = "3a69dcb3a21cfb32ce1cd056169337ca284af0766dd766e7878819b251a49204"
dependencies = [ dependencies = [
"jiff-core", "jiff-core",
"proc-macro2", "proc-macro2",
@@ -4987,9 +4980,9 @@ checksum = "b6d2cec3eae94f9f509c767b45932f1ada8350c4bdb85af2fcab4a3c14807981"
[[package]] [[package]]
name = "libredox" name = "libredox"
version = "0.1.24" version = "0.1.23"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "6480ccc157a1389bb2e4891b24751b0f798ba640d22386f23143fbcc89da195a" checksum = "8d8f1ea3f21fd3405dcaf6c9b5c1630af9afc422d9073ea39c5f6d6c772e08ed"
dependencies = [ dependencies = [
"libc", "libc",
] ]
@@ -5077,9 +5070,9 @@ checksum = "ff9840bcc50b71349309900da0ce7279aa336ae71d73250b07998932c7d97c25"
[[package]] [[package]]
name = "lru-slab" name = "lru-slab"
version = "0.1.3" version = "0.1.2"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4050469837a6ff301cd14c1f8f24f88549e6d548f24f64e2148eb0f72cebc51f" checksum = "112b39cec0b298b6c1999fee3e31427f74f676e4cb9879ed1a121b43661a4154"
[[package]] [[package]]
name = "lsp-types" name = "lsp-types"
@@ -5243,7 +5236,7 @@ dependencies = [
[[package]] [[package]]
name = "media" name = "media"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"bindgen", "bindgen",
@@ -5495,7 +5488,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr" name = "nostr"
version = "0.45.4" version = "0.45.4"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"aes", "aes",
"base64 0.22.1", "base64 0.22.1",
@@ -5521,7 +5514,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr-connect" name = "nostr-connect"
version = "0.45.1" version = "0.45.1"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"async-utility", "async-utility",
"futures-core", "futures-core",
@@ -5535,7 +5528,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr-database" name = "nostr-database"
version = "0.45.1" version = "0.45.1"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"nostr", "nostr",
"opaquerr", "opaquerr",
@@ -5544,7 +5537,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr-gossip" name = "nostr-gossip"
version = "0.45.0" version = "0.45.0"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"nostr", "nostr",
"opaquerr", "opaquerr",
@@ -5553,7 +5546,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr-gossip-memory" name = "nostr-gossip-memory"
version = "0.45.0" version = "0.45.0"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"indexmap", "indexmap",
"lru", "lru",
@@ -5565,7 +5558,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr-lmdb" name = "nostr-lmdb"
version = "0.45.2" version = "0.45.2"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"async-utility", "async-utility",
"flatbuffers", "flatbuffers",
@@ -5580,7 +5573,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr-memory" name = "nostr-memory"
version = "0.45.1" version = "0.45.1"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"btreecap", "btreecap",
"nostr", "nostr",
@@ -5591,7 +5584,7 @@ dependencies = [
[[package]] [[package]]
name = "nostr-sdk" name = "nostr-sdk"
version = "0.45.2" version = "0.45.2"
source = "git+https://github.com/rust-nostr/nostr#b230cecf9dbb38e0228e6fff4544ed9d261326fc" source = "git+https://github.com/rust-nostr/nostr#5c669a498e5f8dd1ec5713b11fdb92bcd858ad73"
dependencies = [ dependencies = [
"async-utility", "async-utility",
"async-wsocket", "async-wsocket",
@@ -6078,18 +6071,6 @@ dependencies = [
"objc2-metal 0.3.2", "objc2-metal 0.3.2",
] ]
[[package]]
name = "objc2-screen-capture-kit"
version = "0.3.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "74b7c5390f477482f001bc354d6571a70db7e4f8d5288e860c45521fbce11394"
dependencies = [
"block2 0.6.2",
"objc2 0.6.4",
"objc2-core-graphics",
"objc2-foundation 0.3.2",
]
[[package]] [[package]]
name = "objc2-user-notifications" name = "objc2-user-notifications"
version = "0.3.2" version = "0.3.2"
@@ -6330,7 +6311,7 @@ checksum = "9b4f627cb1b25917193a259e49bdad08f671f8d9708acfd5fe0a8c1455d87220"
[[package]] [[package]]
name = "perf" name = "perf"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"collections", "collections",
"serde", "serde",
@@ -6637,7 +6618,7 @@ version = "3.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f" checksum = "e67ba7e9b2b56446f1d419b1d807906278ffa1a658a8a5d8a39dcb1f5a78614f"
dependencies = [ dependencies = [
"toml_edit 0.25.15+spec-1.1.0", "toml_edit 0.25.13+spec-1.1.0",
] ]
[[package]] [[package]]
@@ -7118,7 +7099,7 @@ dependencies = [
[[package]] [[package]]
name = "refineable" name = "refineable"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"derive_refineable", "derive_refineable",
] ]
@@ -7201,7 +7182,7 @@ dependencies = [
[[package]] [[package]]
name = "reqwest_client" name = "reqwest_client"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"bytes", "bytes",
@@ -7579,7 +7560,7 @@ dependencies = [
[[package]] [[package]]
name = "scheduler" name = "scheduler"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"async-task", "async-task",
"backtrace", "backtrace",
@@ -8139,9 +8120,9 @@ dependencies = [
[[package]] [[package]]
name = "smallvec" name = "smallvec"
version = "1.16.1" version = "1.16.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ba467056f1b547ed52077911161fc86985becbc60e8e1857c8a144dab0def891" checksum = "b9be42f50aa861c555654aa3a37f52f4b1074bacf4e48fe0ef7fa584e80f1f0f"
[[package]] [[package]]
name = "smol" name = "smol"
@@ -8295,7 +8276,7 @@ checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292"
[[package]] [[package]]
name = "sum_tree" name = "sum_tree"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"heapless 0.9.3", "heapless 0.9.3",
"log", "log",
@@ -8741,9 +8722,18 @@ dependencies = [
[[package]] [[package]]
name = "tinyvec" name = "tinyvec"
version = "1.13.3" version = "1.13.2"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fd3ca314f692efd6c868f8408f53fe444634a845f96c028b97d35f6a1f79f0ee" checksum = "4cf0ded5c4e56918d8f8a339e1bb67d038d3bc6d144ac407904015ba2e4cde9b"
dependencies = [
"tinyvec_macros",
]
[[package]]
name = "tinyvec_macros"
version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"
[[package]] [[package]]
name = "tokio" name = "tokio"
@@ -8858,9 +8848,9 @@ dependencies = [
[[package]] [[package]]
name = "toml" name = "toml"
version = "1.1.6+spec-1.1.0" version = "1.1.5+spec-1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "920602543f0911ab71da12c50d59701da54c196d1a2bf5cb4b75667f137a406a" checksum = "12c0ba9680044b4ce98d391a62094047eada0d64860b80166c39f4a6b5640785"
dependencies = [ dependencies = [
"indexmap", "indexmap",
"serde_core", "serde_core",
@@ -8905,9 +8895,9 @@ dependencies = [
[[package]] [[package]]
name = "toml_edit" name = "toml_edit"
version = "0.25.15+spec-1.1.0" version = "0.25.13+spec-1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1340ea94a5856333492c9064b02c778b191dd2c853778d9609debdcdfea3a614" checksum = "6975367e4d2ef766d86af01ffad14b622fecc8d4357a998fbc4deb6e9bacaf9b"
dependencies = [ dependencies = [
"indexmap", "indexmap",
"toml_datetime 1.1.1+spec-1.1.0", "toml_datetime 1.1.1+spec-1.1.0",
@@ -9095,9 +9085,9 @@ dependencies = [
[[package]] [[package]]
name = "tree-sitter-cmake" name = "tree-sitter-cmake"
version = "0.7.5" version = "0.7.4"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d22893fac54133fdb93497efc45713d53a96d93b035288c7a8ab0c2af77c0ddd" checksum = "164e0c4f4236ec5ceff14824a5528615cf462e100467e49826442ff57d327061"
dependencies = [ dependencies = [
"cc", "cc",
"tree-sitter-language", "tree-sitter-language",
@@ -9532,9 +9522,9 @@ dependencies = [
[[package]] [[package]]
name = "unicode-properties" name = "unicode-properties"
version = "0.1.3" version = "0.1.4"
source = "registry+https://github.com/rust-lang/crates.io-index" source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e70f2a8b45122e719eb623c01822704c4e0907e7e426a05927e1a1cfff5b75d0" checksum = "7df058c713841ad818f1dc5d3fd88063241cc61f49f5fbea4b951e8cf5a8d71d"
[[package]] [[package]]
name = "unicode-script" name = "unicode-script"
@@ -9670,7 +9660,7 @@ checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"
[[package]] [[package]]
name = "util_macros" name = "util_macros"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"perf", "perf",
"quote", "quote",
@@ -11437,7 +11427,7 @@ checksum = "34b31d188d9d685a4f9c7b46d6e36631b07058d2cfe190267adce54dc230bf12"
[[package]] [[package]]
name = "zlog" name = "zlog"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"anyhow", "anyhow",
"chrono", "chrono",
@@ -11454,7 +11444,7 @@ checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"
[[package]] [[package]]
name = "ztracing" name = "ztracing"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
dependencies = [ dependencies = [
"tracing", "tracing",
"tracing-subscriber", "tracing-subscriber",
@@ -11465,7 +11455,7 @@ dependencies = [
[[package]] [[package]]
name = "ztracing_macro" name = "ztracing_macro"
version = "0.1.0" version = "0.1.0"
source = "git+https://github.com/zed-industries/zed#7960b2a7c9568e90fbe0727332149e5b2a5fd57a" source = "git+https://github.com/zed-industries/zed#6ad3c7f278e513875e0bbde5ee935f6c9a342b9c"
[[package]] [[package]]
name = "zune-core" name = "zune-core"
+1 -35
View File
@@ -3,7 +3,7 @@ use std::path::{Path, PathBuf};
use std::sync::Arc; use std::sync::Arc;
use anyhow::Error; use anyhow::Error;
use gpui::{App, AppContext, Context, Entity, Global, SharedString, Task}; use gpui::{App, AppContext, Context, Entity, Global, Task};
use signed_core::{Announcement, RepoAddr, repo_addr}; use signed_core::{Announcement, RepoAddr, repo_addr};
use signed_git::{LocalRepo, Nip34Binding, find_git_repos}; use signed_git::{LocalRepo, Nip34Binding, find_git_repos};
@@ -126,16 +126,6 @@ pub struct ResolvedLocalRepo {
pub announcement: Option<Announcement>, pub announcement: Option<Announcement>,
} }
impl ResolvedLocalRepo {
/// The repository's directory name, or `Untitled` when the path has none.
pub fn name(&self) -> SharedString {
self.path
.file_name()
.map(|name| SharedString::from(name.to_string_lossy().into_owned()))
.unwrap_or_else(|| SharedString::from("Untitled"))
}
}
/// Resolve the scanned repositories against the known announcements. /// Resolve the scanned repositories against the known announcements.
pub fn resolve_local_repos( pub fn resolve_local_repos(
repos: &[LocalRepo], repos: &[LocalRepo],
@@ -263,28 +253,4 @@ mod tests {
assert!(resolved[0].nip34.is_none()); assert!(resolved[0].nip34.is_none());
assert!(resolved[0].announcement.is_none()); assert!(resolved[0].announcement.is_none());
} }
#[test]
fn the_name_is_the_directory_name() {
let repo = LocalRepo {
path: PathBuf::from("/tmp/my-repo"),
nip34: None,
};
let resolved = resolve_local_repos(&[repo], &[], &[]);
assert_eq!(resolved[0].name(), SharedString::from("my-repo"));
}
#[test]
fn a_path_without_a_directory_name_is_untitled() {
let repo = LocalRepo {
path: PathBuf::from("/"),
nip34: None,
};
let resolved = resolve_local_repos(&[repo], &[], &[]);
assert_eq!(resolved[0].name(), SharedString::from("Untitled"));
}
} }
+16 -27
View File
@@ -1,7 +1,7 @@
use gpui::prelude::*; use gpui::prelude::*;
use gpui::{App, Pixels, StyleRefinement, Window, div, px}; use gpui::{App, Pixels, StyleRefinement, Window, div, px};
use gpui_base::StyledExt; use gpui_base::StyledExt;
use gpui_component::{ActiveTheme, Colorize, Sizable, Size}; use gpui_component::{ActiveTheme, Colorize};
/// Number of rows and columns in the pixel grid. /// Number of rows and columns in the pixel grid.
const GRID_SIZE: usize = 8; const GRID_SIZE: usize = 8;
@@ -10,36 +10,34 @@ const FILL_PROBABILITY: f32 = 0.42;
/// Probability that a filled cell uses the accent shade instead of the main color. /// Probability that a filled cell uses the accent shade instead of the main color.
const ACCENT_PROBABILITY: f32 = 0.25; const ACCENT_PROBABILITY: f32 = 0.25;
/// Minimum number of filled left-half cells. /// Minimum number of filled left-half cells.
/// A sparse roll still yields a recognizable shape.
/// Each left-half cell is mirrored to a right-half one.
const MIN_FILLED: usize = 5; const MIN_FILLED: usize = 5;
/// Side length of the avatar in pixels, no setter.
const AVATAR_SIZE: Pixels = px(16.);
/// A deterministic, offline pixel-art avatar. /// A deterministic, offline pixel-art avatar.
/// An 8×8 grid with horizontal mirror symmetry.
/// Seeded from a stable string such as the repository id and owner public key.
/// The same seed always renders the same avatar.
#[derive(IntoElement)] #[derive(IntoElement)]
pub struct PixelAvatar { pub struct PixelAvatar {
seed: u64, seed: u64,
size: Size,
style: StyleRefinement, style: StyleRefinement,
} }
impl PixelAvatar { impl PixelAvatar {
/// Create an avatar seeded from `seed`. /// Create an avatar seeded from `seed`.
///
/// The seed should be a stable string unique to the entity the avatar represents. /// The seed should be a stable string unique to the entity the avatar represents.
pub fn new(seed: impl AsRef<str>) -> Self { pub fn new(seed: impl AsRef<str>) -> Self {
Self { Self {
seed: fnv1a(seed.as_ref().as_bytes()), seed: fnv1a(seed.as_ref().as_bytes()),
size: Size::XSmall,
style: StyleRefinement::default(), style: StyleRefinement::default(),
} }
} }
} }
impl Sizable for PixelAvatar {
fn with_size(mut self, size: impl Into<Size>) -> Self {
self.size = size.into();
self
}
}
impl Styled for PixelAvatar { impl Styled for PixelAvatar {
fn style(&mut self) -> &mut StyleRefinement { fn style(&mut self) -> &mut StyleRefinement {
&mut self.style &mut self.style
@@ -50,17 +48,16 @@ impl RenderOnce for PixelAvatar {
fn render(self, _window: &mut Window, cx: &mut App) -> impl IntoElement { fn render(self, _window: &mut Window, cx: &mut App) -> impl IntoElement {
let theme = cx.theme(); let theme = cx.theme();
let pattern = pattern(self.seed); let pattern = pattern(self.seed);
let mut cells = Vec::new();
let hue = self.seed as f32 / u64::MAX as f32; let hue = self.seed as f32 / u64::MAX as f32;
let main = theme.blue.hue(hue); let main = theme.blue.hue(hue);
let shade = if theme.is_dark() { let shade = if theme.is_dark() {
main.lightness((main.l * 1.6).min(0.95)) main.lightness((main.l * 1.6).min(0.95))
} else { } else {
main.lightness((main.l * 0.45).max(0.18)) main.lightness((main.l * 0.45).max(0.18))
}; };
let mut cells = Vec::new();
for row in 0..GRID_SIZE { for row in 0..GRID_SIZE {
for col in 0..GRID_SIZE { for col in 0..GRID_SIZE {
let value = pattern[row * GRID_SIZE + col]; let value = pattern[row * GRID_SIZE + col];
@@ -83,7 +80,7 @@ impl RenderOnce for PixelAvatar {
.grid() .grid()
.grid_cols(GRID_SIZE as u16) .grid_cols(GRID_SIZE as u16)
.grid_rows(GRID_SIZE as u16) .grid_rows(GRID_SIZE as u16)
.size(side_length(self.size)) .size(AVATAR_SIZE)
.flex_shrink_0() .flex_shrink_0()
.overflow_hidden() .overflow_hidden()
.bg(main.opacity(0.16)) .bg(main.opacity(0.16))
@@ -91,16 +88,9 @@ impl RenderOnce for PixelAvatar {
} }
} }
fn side_length(size: Size) -> Pixels { /// Generate the 8×8 cell pattern for `seed`.
match size { /// Cells are `0` for empty, `1` for main color and `2` for accent shade.
Size::XSmall => px(16.), /// The right half mirrors the left half.
Size::Small => px(24.),
Size::Medium => px(48.),
Size::Large => px(80.),
Size::Size(size) => size,
}
}
fn pattern(seed: u64) -> [u8; GRID_SIZE * GRID_SIZE] { fn pattern(seed: u64) -> [u8; GRID_SIZE * GRID_SIZE] {
let mut rng = PixelRng::new(seed); let mut rng = PixelRng::new(seed);
let mut pattern = [0u8; GRID_SIZE * GRID_SIZE]; let mut pattern = [0u8; GRID_SIZE * GRID_SIZE];
@@ -116,19 +106,18 @@ fn pattern(seed: u64) -> [u8; GRID_SIZE * GRID_SIZE] {
} }
} }
// Sparse rolls can come out nearly empty.
// Top the pattern up to the minimum fill, scanning from a seeded starting cell.
if filled < MIN_FILLED { if filled < MIN_FILLED {
let half = GRID_SIZE * GRID_SIZE / 2; let half = GRID_SIZE * GRID_SIZE / 2;
let start = (rng.next() % half as u64) as usize; let start = (rng.next() % half as u64) as usize;
for offset in 0..half { for offset in 0..half {
if filled >= MIN_FILLED { if filled >= MIN_FILLED {
break; break;
} }
let ix = (start + offset) % half; let ix = (start + offset) % half;
let row = ix / (GRID_SIZE / 2); let row = ix / (GRID_SIZE / 2);
let col = ix % (GRID_SIZE / 2); let col = ix % (GRID_SIZE / 2);
if pattern[row * GRID_SIZE + col] == 0 { if pattern[row * GRID_SIZE + col] == 0 {
set_cell(&mut pattern, row, col, 1); set_cell(&mut pattern, row, col, 1);
filled += 1; filled += 1;
+23 -26
View File
@@ -2017,33 +2017,30 @@ pub(super) fn repo_display_name(store: &RepoStore) -> SharedString {
/// The owner and identifier a local repository is already bound to. /// The owner and identifier a local repository is already bound to.
fn bound_repo_label(binding: &Nip34Binding, cx: &App) -> AnyElement { fn bound_repo_label(binding: &Nip34Binding, cx: &App) -> AnyElement {
let store = ProfileStore::global(cx); let owner = binding
let profile = binding.owner.map(|pk| store.read(cx).get(&pk)); .owner
.and_then(|owner| owner.to_bech32().ok())
.map(|npub| middle_truncate(&npub, 12, 8))
.unwrap_or_else(|| "a NIP-34 coordinate".to_owned());
h_flex() let mut label = v_flex().flex_shrink_0().items_end().gap_1().child(
.flex_shrink_0() div()
.gap_2() .text_xs()
.text_sm() .text_color(cx.theme().muted_foreground)
.child("Initialized by") .child(SharedString::from(format!("Bound to {owner}"))),
.text_color(cx.theme().muted_foreground) );
.when_some(profile, |this, profile| {
this.child( if let Some(identifier) = binding.identifier.as_deref() {
h_flex() label = label.child(
.gap_1() div()
.text_color(cx.theme().foreground) .text_xs()
.child(UserAvatar::new(profile.name()).picture(profile.picture())) .font_semibold()
.child(profile.name()), .text_color(cx.theme().muted_foreground)
) .child(SharedString::from(identifier.to_owned())),
}) );
.when_some(binding.identifier.as_deref(), |this, ident| { }
this.child(
div() label.into_any_element()
.text_xs()
.font_semibold()
.child(SharedString::from(format!("/{ident}"))),
)
})
.into_any_element()
} }
impl BasePanel for RepoDetailView { impl BasePanel for RepoDetailView {
+34 -57
View File
@@ -10,8 +10,9 @@ use dock::{
}; };
use gpui::prelude::*; use gpui::prelude::*;
use gpui::{ use gpui::{
AnyElement, App, Context, Div, Entity, EventEmitter, FocusHandle, Focusable, ObjectFit, Render, AnyElement, App, Context, Div, Entity, EventEmitter, FocusHandle, Focusable, Hsla, ObjectFit,
SharedString, Subscription, WeakEntity, Window, div, img, px, relative, uniform_list, white, Render, SharedString, Subscription, WeakEntity, Window, div, img, px, relative, uniform_list,
white,
}; };
use gpui_base::Button as BaseButton; use gpui_base::Button as BaseButton;
use gpui_component::button::{Button, ButtonVariants}; use gpui_component::button::{Button, ButtonVariants};
@@ -36,8 +37,8 @@ mod settings_dialog;
use self::onboarding_dialog::OnboardingState; use self::onboarding_dialog::OnboardingState;
/// The platform that bound a repository, `"nak"` or `"ngit"`. /// The tool that bound a repository, `"nak"` or `"ngit"`.
fn local_platform(binding: &Nip34Binding) -> Option<&'static str> { fn local_tool(binding: &Nip34Binding) -> Option<&'static str> {
let signals = &binding.signals; let signals = &binding.signals;
if signals.nip34_json || signals.nip34_grasp_remote || signals.nip34_state_refs { if signals.nip34_json || signals.nip34_grasp_remote || signals.nip34_state_refs {
@@ -484,43 +485,34 @@ impl SidebarPanel {
entry: &ResolvedLocalRepo, entry: &ResolvedLocalRepo,
cx: &mut Context<Self>, cx: &mut Context<Self>,
) -> impl IntoElement { ) -> impl IntoElement {
let name = entry.name(); let name = entry
let avatar = local_avatar(entry, cx); .path
.file_name()
.map(|name| name.to_string_lossy().into_owned())
.unwrap_or("Untitled".into());
let avatar = PixelAvatar::new(entry.path.to_string_lossy());
let suffix: AnyElement = match entry.nip34.as_ref().map(|binding| binding.kind) {
Some(Nip34Kind::Initialized) => {
let label = match entry.nip34.as_ref().and_then(local_tool) {
Some(tool) => format!("NIP-34 · {tool}"),
None => "NIP-34".to_owned(),
};
local_badge(&label, cx.theme().muted_foreground)
}
Some(Nip34Kind::Cloned) => local_badge("NIP-34 clone", cx.theme().muted_foreground),
Some(Nip34Kind::ToolingOnly) => {
local_badge("Nostr tooling", cx.theme().muted_foreground)
}
None => Icon::new(IconName::TriangleAlert)
.small()
.text_color(cx.theme().warning)
.into_any_element(),
};
let id = format!("local-repo:{}", entry.path.display()); let id = format!("local-repo:{}", entry.path.display());
let entry = entry.clone(); let entry = entry.clone();
let suffix: AnyElement = match entry.nip34.as_ref() {
Some(binding) => {
let (label, tooltip) = match binding.kind {
Nip34Kind::Initialized => {
let platform = local_platform(binding).unwrap_or("Grasp");
let tooltip = match platform {
"nak" => "Initialized with nak",
"ngit" => "Initialized with ngit",
_ => "Initialized for NIP-34",
};
(platform, tooltip)
}
Nip34Kind::Cloned => ("Cloned", "Cloned buts not initialized"),
Nip34Kind::ToolingOnly => ("Tooling", "Grasp tooling only"),
};
Button::new(id.clone())
.xsmall()
.child(div().text_size(px(10.)).child(label))
.tooltip(tooltip)
.secondary()
.into_any_element()
}
None => Button::new(id.clone())
.xsmall()
.icon(IconName::TriangleAlert)
.tooltip("Not published yet")
.ghost()
.into_any_element(),
};
NavItem::new(id, name, avatar) NavItem::new(id, name, avatar)
.suffix(suffix) .suffix(suffix)
.on_click(cx.listener(move |this, _ev, window, cx| { .on_click(cx.listener(move |this, _ev, window, cx| {
@@ -652,27 +644,12 @@ pub(super) fn server_host(relay: &RelayUrl) -> SharedString {
.unwrap_or_else(|| SharedString::from(relay.to_string())) .unwrap_or_else(|| SharedString::from(relay.to_string()))
} }
/// The repository's pixel avatar, with the bound owner's avatar at its bottom right. fn local_badge(label: &str, color: Hsla) -> AnyElement {
fn local_avatar(entry: &ResolvedLocalRepo, cx: &App) -> AnyElement {
let avatar = PixelAvatar::new(entry.path.to_string_lossy());
let Some(owner) = entry.nip34.as_ref().and_then(|binding| binding.owner) else {
return avatar.into_any_element();
};
let store = ProfileStore::global(cx);
let profile = store.read(cx).get(&owner);
div() div()
.relative() .flex_shrink_0()
.child(avatar) .text_xs()
.child( .text_color(color)
div().absolute().bottom_neg_0p5().right_neg_0p5().child( .child(SharedString::from(label.to_owned()))
UserAvatar::new(profile.name())
.picture(profile.picture())
.size(px(14.)),
),
)
.into_any_element() .into_any_element()
} }
+1 -1
View File
@@ -12,7 +12,7 @@ path = "src/main.rs"
name = "Signed" name = "Signed"
product-name = "Signed" product-name = "Signed"
description = "Nostr Git client for browsing repositories and collaborating" description = "Nostr Git client for browsing repositories and collaborating"
identifier = "info.reya.signed" identifier = "su.reya.signed"
category = "DeveloperTool" category = "DeveloperTool"
version = "0.1.0-alpha" version = "0.1.0-alpha"
out-dir = "../dist" out-dir = "../dist"
Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

After

Width:  |  Height:  |  Size: 86 KiB

+2 -2
View File
@@ -17,7 +17,7 @@ contact: https://reya.su
parts: parts:
signed: signed:
plugin: dump plugin: dump
source: target/release/signed-linux-$TARBALL_ARCH_SUFFIX.tar.gz source: target/release/signed-linux-$ARCH_SUFFIX.tar.gz
organize: organize:
# These renames seem to not be necessary, but it's tidier. # These renames seem to not be necessary, but it's tidier.
@@ -54,4 +54,4 @@ parts:
apps: apps:
signed: signed:
command: usr/bin/signed command: usr/bin/signed
common-id: info.reya.signed common-id: su.reya.signed
+1 -1
View File
@@ -78,7 +78,7 @@ fn main() {
cx, cx,
); );
cx.set_app_identity("info.reya.signed", "Signed"); cx.set_app_identity("su.reya.signed", "Signed");
let bounds = Bounds::centered(None, size(px(1120.0), px(750.0)), cx); let bounds = Bounds::centered(None, size(px(1120.0), px(750.0)), cx);
let opts = WindowOptions { let opts = WindowOptions {
+2 -2
View File
@@ -2,8 +2,8 @@
# These are generated by script/prepare-flathub # These are generated by script/prepare-flathub
vendor/ vendor/
vendor.tar.gz vendor.tar.gz
info.reya.signed.yml su.reya.signed.yml
info.reya.signed.metainfo.xml su.reya.signed.metainfo.xml
release-info.xml release-info.xml
cargo-config.toml cargo-config.toml
build/ build/
+16 -16
View File
@@ -19,14 +19,14 @@ Run the preparation script from the repo root:
This will: This will:
1. Vendor all Rust dependencies (crates.io + git) 1. Vendor all Rust dependencies (crates.io + git)
2. Generate the metainfo.xml with proper release info 2. Generate the metainfo.xml with proper release info
3. Create `info.reya.signed.yml` - the Flatpak manifest for Flathub 3. Create `su.reya.signed.yml` - the Flatpak manifest for Flathub
## Files Generated ## Files Generated
| File | Purpose | | File | Purpose |
|------|---------| |------|---------|
| `info.reya.signed.yml` | Main Flatpak manifest (submit this to Flathub) | | `su.reya.signed.yml` | Main Flatpak manifest (submit this to Flathub) |
| `info.reya.signed.metainfo.xml` | AppStream metadata with release info | | `su.reya.signed.metainfo.xml` | AppStream metadata with release info |
| `vendor.tar.gz` | Vendored Rust dependencies | | `vendor.tar.gz` | Vendored Rust dependencies |
| `cargo-config.toml` | Cargo configuration for offline builds | | `cargo-config.toml` | Cargo configuration for offline builds |
| `release-info.xml` | Release info snippet for metainfo | | `release-info.xml` | Release info snippet for metainfo |
@@ -39,13 +39,13 @@ Before submitting to Flathub, test the build:
cd flathub cd flathub
# Build and install locally # Build and install locally
flatpak-builder --user --install --force-clean build info.reya.signed.yml flatpak-builder --user --install --force-clean build su.reya.signed.yml
# Test the app # Test the app
flatpak run info.reya.signed flatpak run su.reya.signed
# Run the Flathub linter (must pass!) # Run the Flathub linter (must pass!)
flatpak run --command=flatpak-builder-lint org.flatpak.Builder manifest info.reya.signed.yml flatpak run --command=flatpak-builder-lint org.flatpak.Builder manifest su.reya.signed.yml
flatpak run --command=flatpak-builder-lint org.flatpak.Builder repo repo flatpak run --command=flatpak-builder-lint org.flatpak.Builder repo repo
``` ```
@@ -69,15 +69,15 @@ git clone --branch=new-pr git@github.com:YOUR_USERNAME/flathub.git
cd flathub cd flathub
# Create a new branch # Create a new branch
git checkout -b info.reya.signed git checkout -b su.reya.signed
# Copy ONLY the manifest file from your project # Copy ONLY the manifest file from your project
cp /path/to/signed/flathub/info.reya.signed.yml . cp /path/to/signed/flathub/su.reya.signed.yml .
# Commit and push # Commit and push
git add info.reya.signed.yml git add su.reya.signed.yml
git commit -m "Add info.reya.signed" git commit -m "Add su.reya.signed"
git push origin info.reya.signed git push origin su.reya.signed
``` ```
### 3. Open Pull Request ### 3. Open Pull Request
@@ -92,9 +92,9 @@ git push origin info.reya.signed
1. Flathub's automated CI will build your app 1. Flathub's automated CI will build your app
2. A maintainer will review your submission 2. A maintainer will review your submission
3. Once approved, a new repo `flathub/info.reya.signed` will be created 3. Once approved, a new repo `flathub/su.reya.signed` will be created
4. You'll get write access to maintain the app 4. You'll get write access to maintain the app
5. Future updates: Push new commits to `flathub/info.reya.signed` 5. Future updates: Push new commits to `flathub/su.reya.signed`
## Updating the App ## Updating the App
@@ -104,9 +104,9 @@ To release a new version:
2. Tag the new release: `git tag -a v0.1.0 -m "Release v0.1.0"` 2. Tag the new release: `git tag -a v0.1.0 -m "Release v0.1.0"`
3. Push the tag: `git push origin v0.1.0` 3. Push the tag: `git push origin v0.1.0`
4. Run `./script/prepare-flathub` to regenerate 4. Run `./script/prepare-flathub` to regenerate
5. Clone the flathub repo: `git clone https://github.com/flathub/info.reya.signed.git` 5. Clone the flathub repo: `git clone https://github.com/flathub/su.reya.signed.git`
6. Update the manifest with new commit/tag and hashes 6. Update the manifest with new commit/tag and hashes
7. Submit PR to `flathub/info.reya.signed` 7. Submit PR to `flathub/su.reya.signed`
## Troubleshooting ## Troubleshooting
@@ -115,7 +115,7 @@ To release a new version:
- Ensure `vendor.tar.gz` is properly extracted before building - Ensure `vendor.tar.gz` is properly extracted before building
### Linter complains about metainfo ### Linter complains about metainfo
- Ensure `info.reya.signed.metainfo.xml` has at least one `<release>` entry - Ensure `su.reya.signed.metainfo.xml` has at least one `<release>` entry
- Add accessible screenshot URLs if required - Add accessible screenshot URLs if required
### Missing dependencies ### Missing dependencies
+3 -6
View File
@@ -11,12 +11,9 @@ ARCH=$(uname -m)
# Snap uses its own architecture names, which must match the file name and # Snap uses its own architecture names, which must match the file name and
# the architecture asserted inside the .snap. `x86_64`/`aarch64` here would # the architecture asserted inside the .snap. `x86_64`/`aarch64` here would
# produce a file like signed_1.0.0_x86_64.snap that snapd cannot match. # produce a file like signed_1.0.0_x86_64.snap that snapd cannot match.
#
# The source tarball is named by `script/bundle-linux` after `uname -m`, so it
# keeps the x86_64/aarch64 spelling rather than the snap-native one.
case "$ARCH" in case "$ARCH" in
x86_64|amd64) ARCH_SUFFIX="amd64"; TARBALL_ARCH_SUFFIX="x86_64" ;; x86_64|amd64) ARCH_SUFFIX="amd64" ;;
aarch64|arm64) ARCH_SUFFIX="arm64"; TARBALL_ARCH_SUFFIX="aarch64" ;; aarch64|arm64) ARCH_SUFFIX="arm64" ;;
*) echo "Unsupported architecture: $ARCH"; exit 1 ;; *) echo "Unsupported architecture: $ARCH"; exit 1 ;;
esac esac
@@ -30,7 +27,7 @@ envsubst < "desktop/resources/signed.desktop.in" > "snap/gui/signed.desktop"
cp "desktop/resources/icon.png" "snap/gui/signed.png" cp "desktop/resources/icon.png" "snap/gui/signed.png"
# Generate snapcraft.yaml with version and architecture # Generate snapcraft.yaml with version and architecture
RELEASE_VERSION="$1" TARBALL_ARCH_SUFFIX="$TARBALL_ARCH_SUFFIX" envsubst < desktop/resources/snap/snapcraft.yaml.in > snap/snapcraft.yaml RELEASE_VERSION="$1" ARCH_SUFFIX="$ARCH_SUFFIX" envsubst < desktop/resources/snap/snapcraft.yaml.in > snap/snapcraft.yaml
# Clean previous builds # Clean previous builds
snapcraft clean snapcraft clean
+1 -1
View File
@@ -16,7 +16,7 @@ archive_match="signed(-[a-zA-Z0-9]+)?-linux-${ARCH_SUFFIX}\.tar\.gz"
archive=$(ls "target/release" | grep -E ${archive_match}) archive=$(ls "target/release" | grep -E ${archive_match})
export ARCHIVE="$archive" export ARCHIVE="$archive"
export APP_ID="info.reya.signed" export APP_ID="su.reya.signed"
export APP_NAME="Signed" export APP_NAME="Signed"
export BRANDING_LIGHT="#C6FF4D" export BRANDING_LIGHT="#C6FF4D"
export BRANDING_DARK="#C6FF4D" export BRANDING_DARK="#C6FF4D"
+10 -10
View File
@@ -4,7 +4,7 @@
# This script: # This script:
# 1. Vendors all Rust dependencies (crates.io + git) # 1. Vendors all Rust dependencies (crates.io + git)
# 2. Generates release info for metainfo.xml # 2. Generates release info for metainfo.xml
# 3. Creates the Flathub manifest (info.reya.signed.yml) # 3. Creates the Flathub manifest (su.reya.signed.yml)
# #
# Usage: ./script/prepare-flathub [--release-date YYYY-MM-DD] # Usage: ./script/prepare-flathub [--release-date YYYY-MM-DD]
@@ -12,7 +12,7 @@ set -euo pipefail
cd "$(dirname "$0")/.." cd "$(dirname "$0")/.."
# Configuration # Configuration
APP_ID="info.reya.signed" APP_ID="su.reya.signed"
APP_NAME="Signed" APP_NAME="Signed"
REPO_URL="https://git.reya.su/reya/signed" REPO_URL="https://git.reya.su/reya/signed"
BRANDING_LIGHT="#C6FF4D" BRANDING_LIGHT="#C6FF4D"
@@ -106,7 +106,7 @@ COMMIT=$(git rev-parse HEAD)
# Generate the YAML manifest # Generate the YAML manifest
cat > flathub/${APP_ID}.yml << 'MANIFEST_EOF' cat > flathub/${APP_ID}.yml << 'MANIFEST_EOF'
id: info.reya.signed id: su.reya.signed
runtime: org.freedesktop.Platform runtime: org.freedesktop.Platform
runtime-version: "24.08" runtime-version: "24.08"
sdk: org.freedesktop.Sdk sdk: org.freedesktop.Sdk
@@ -153,22 +153,22 @@ modules:
- install -Dm755 target/release/signed /app/bin/signed - install -Dm755 target/release/signed /app/bin/signed
# Install icons # Install icons
- install -Dm644 desktop/resources/icon.png /app/share/icons/hicolor/512x512/apps/info.reya.signed.png - install -Dm644 desktop/resources/icon.png /app/share/icons/hicolor/512x512/apps/su.reya.signed.png
- install -Dm644 desktop/resources/icon@2x.png /app/share/icons/hicolor/1024x1024/apps/info.reya.signed.png - install -Dm644 desktop/resources/icon@2x.png /app/share/icons/hicolor/1024x1024/apps/su.reya.signed.png
# Install desktop file # Install desktop file
- | - |
export APP_ID="info.reya.signed" export APP_ID="su.reya.signed"
export APP_ICON="info.reya.signed" export APP_ICON="su.reya.signed"
export APP_NAME="Signed" export APP_NAME="Signed"
export APP_CLI="signed" export APP_CLI="signed"
export APP_ARGS="%U" export APP_ARGS="%U"
export DO_STARTUP_NOTIFY="true" export DO_STARTUP_NOTIFY="true"
envsubst < desktop/resources/signed.desktop.in > signed.desktop envsubst < desktop/resources/signed.desktop.in > signed.desktop
install -Dm644 signed.desktop /app/share/applications/info.reya.signed.desktop install -Dm644 signed.desktop /app/share/applications/su.reya.signed.desktop
# Install metainfo (use pre-generated one with release info) # Install metainfo (use pre-generated one with release info)
- install -Dm644 info.reya.signed.metainfo.xml /app/share/metainfo/info.reya.signed.metainfo.xml - install -Dm644 su.reya.signed.metainfo.xml /app/share/metainfo/su.reya.signed.metainfo.xml
sources: sources:
# Main source code - specific commit # Main source code - specific commit
@@ -184,7 +184,7 @@ modules:
# Pre-generated metainfo with release info # Pre-generated metainfo with release info
- type: file - type: file
path: info.reya.signed.metainfo.xml path: su.reya.signed.metainfo.xml
sha256: "@METAINFO_SHA256@" sha256: "@METAINFO_SHA256@"
# Cargo config for vendoring # Cargo config for vendoring
+51 -63
View File
@@ -54,78 +54,66 @@ echo "Updating versions..."
update_version "$WORKSPACE_CARGO" update_version "$WORKSPACE_CARGO"
update_version "$CRATE_CARGO" update_version "$CRATE_CARGO"
# Check git status before committing
echo "Checking git status..."
if git status --porcelain | grep -q .; then
echo "Current uncommitted changes:"
git status --short
# Ask user if they want to commit all changes or just version files
echo ""
echo "Do you want to:"
echo "1) Commit all current changes (including the version updates)"
echo "2) Commit only the version file changes"
echo "3) Abort the release"
read -p "Enter choice (1/2/3): " choice
case $choice in
1)
echo "Committing all changes..."
git add .
;;
2)
echo "Committing only version file changes..."
git add "$WORKSPACE_CARGO" "$CRATE_CARGO"
;;
3)
echo "Release aborted by user"
exit 0
;;
*)
echo "Invalid choice. Release aborted."
exit 1
;;
esac
else
# Only version files were modified, add them specifically
echo "Only version files were modified, adding them for commit..."
git add "$WORKSPACE_CARGO" "$CRATE_CARGO"
fi
# Commit the changes
COMMIT_MSG="chore: release version $NEW_VERSION" COMMIT_MSG="chore: release version $NEW_VERSION"
# When the requested version is already set there is nothing to bump or commit, if git commit -m "$COMMIT_MSG"; then
# so the current commit is tagged as-is. echo "✓ Committed version changes"
if git diff --quiet -- "$WORKSPACE_CARGO" "$CRATE_CARGO"; then
echo "Version is already $NEW_VERSION, tagging the current commit"
else else
# Check git status before committing echo "Error: Failed to commit version changes"
echo "Checking git status..." exit 1
# The version files are always modified at this point, so only ask about other changes. fi
if [ -n "$(git status --porcelain -- . ":(exclude,top)$WORKSPACE_CARGO" ":(exclude,top)$CRATE_CARGO")" ]; then
echo "Current uncommitted changes:"
git status --short
# Ask user if they want to commit all changes or just version files # Push version changes to origin
echo "" echo "Pushing version changes to origin..."
echo "Do you want to:" if git push origin master; then
echo "1) Commit all current changes (including the version updates)" echo "✓ Successfully pushed version changes to origin"
echo "2) Commit only the version file changes" else
echo "3) Abort the release" echo "Error: Failed to push version changes to origin"
read -p "Enter choice (1/2/3): " choice exit 1
case $choice in
1)
echo "Committing all changes..."
git add .
;;
2)
echo "Committing only version file changes..."
git add "$WORKSPACE_CARGO" "$CRATE_CARGO"
;;
3)
echo "Release aborted by user"
exit 0
;;
*)
echo "Invalid choice. Release aborted."
exit 1
;;
esac
else
# Only version files were modified, add them specifically
echo "Only version files were modified, adding them for commit..."
git add "$WORKSPACE_CARGO" "$CRATE_CARGO"
fi
# Commit the changes
if git commit -m "$COMMIT_MSG"; then
echo "✓ Committed version changes"
else
echo "Error: Failed to commit version changes"
exit 1
fi
# Push version changes to origin
echo "Pushing version changes to origin..."
if git push origin master; then
echo "✓ Successfully pushed version changes to origin"
else
echo "Error: Failed to push version changes to origin"
exit 1
fi
fi fi
# Create git tag # Create git tag
TAG_NAME="v$NEW_VERSION" TAG_NAME="v$NEW_VERSION"
if git rev-parse -q --verify "refs/tags/$TAG_NAME" >/dev/null; then
echo "Error: tag $TAG_NAME already exists"
exit 1
fi
if git tag -a "$TAG_NAME" -m "$COMMIT_MSG"; then if git tag -a "$TAG_NAME" -m "$COMMIT_MSG"; then
echo "✓ Created git tag: $TAG_NAME" echo "✓ Created git tag: $TAG_NAME"
else else