Commit Graph
728 Commits
Author SHA1 Message Date
Marshall Bowers f6b5ea4277 Rename SharedUrl to SharedUri (#7084)
This PR renames `SharedUrl` to `SharedUri` to better reflect its intent.

I'm still not entirely happy with this naming, as the file paths that we
can store in here are not _really_ URIs, as they are lacking a protocol.

I want to explore changing `SharedUri` / `SharedUrl` back to alway
storing a URL and treat local filepaths differently, as it seems we're
conflating two different concerns under the same umbrella, at the
moment.

Release Notes:

- N/A
2024-01-30 09:54:23 -05:00
Bennet Bo Fenner 7b53c4db5c gpui: Support loading image from filesystem (#6978)
This PR implements support for loading and displaying images from a
local file using gpui's `img` element.

API Changes:
- Changed `SharedUrl` to `SharedUrl::File`, `SharedUrl::Network`

Usage:
```rust
// load from network
img(SharedUrl::network(...)) // previously img(SharedUrl(...)

// load from filesystem
img(SharedUrl::file(...))
```

This will be useful when implementing markdown image support, because we
need to be able to render images from the filesystem (relative/absolute
path), e.g. when implementing markdown preview #5064.

I also added an example `image` to the gpui crate, let me know if this
is useful. Showcase:
<img width="872" alt="image"
src="https://github.com/zed-industries/zed/assets/53836821/b4310a26-db81-44fa-9a7b-61e7d0ad4349">

**Note**: The example is fetching images from [Lorem
Picsum](https://picsum.photos) ([Github
Repo](https://github.com/DMarby/picsum-photos)), which is a free
resource for fetching images in a specific size. Please let me know if
you're okay with using this in the example.
2024-01-29 21:56:51 -08:00
Marshall Bowers dbd0a760e6 Clean up Cargo.toml files (#7044)
This PR cleans up some inconsistencies in the `Cargo.toml` files that
were driving me crazy.

Release Notes:

- N/A
2024-01-29 23:47:20 -05:00
Piotr Osiewicz 4ef5a925ad Licenses: change license fields in Cargo.toml to AGPL-3.0-or-later. (#5535)
Release Notes:
- N/A
2024-01-27 13:51:16 +01:00
Christian Clauss f58114b0a1 Fix typos discovered by codespell 2024-01-25 18:32:32 +01:00
Conrad Irwin 4498a5d50a Try to send typed errors back and forth
TEMP

TEMP

First pass of structured errors

Improved error handling for channel joining failures
2024-01-24 20:32:39 -07:00
Antonio Scandurra c1397046d8 Move interaction with keychain off the main thread 2024-01-24 14:53:05 +01:00
Piotr Osiewicz 5cb6fc5776 chore: Change AGPL-licensed crates to GPL (except for collab) (#4231)
- [x] Fill in GPL license text.
- [x] live_kit_client depends on live_kit_server as non-dev dependency,
even though it seems to only be used for tests. Is that an issue?

Release Notes:
- N/A
2024-01-24 00:26:58 +01:00
Conrad Irwin fbf9ac622f less secret (#4221)
- Remove ZED_SECRET_CLIENT_TOKEN
- Remove ZED_CLIENT_SECRET_TOKEN

Neither of these were ever actually a secret.

Release Notes:

- N/A
2024-01-23 10:43:15 -07:00
Conrad Irwin c9c4b2c4bc Remove ZED_SECRET_CLIENT_TOKEN 2024-01-23 10:34:00 -07:00
Piotr Osiewicz 1e1b434acc Remove license-file from Cargo.toml as it is apparently redundant (#4218)
Release Notes:

- N/A
2024-01-23 17:40:30 +01:00
Piotr OsiewiczandDavid 3fe512e1aa chore: Add crate licenses. (#4158)
- GPUI and all dependencies: Apache 2
- Everything else: AGPL

Here's a script that I've generated for it:
https://gist.github.com/osiewicz/6afdd6626e517da24a2092807e6f0b6e

Release Notes:
- N/A

---------

Co-authored-by: David <david@zed.dev>
2024-01-23 16:56:22 +01:00
Conrad Irwin 90795aa2de Fix a circular reference between Client and UserStore
Before this change once the UserStore had been created, the Client would
never be dropped.
2024-01-22 23:05:58 -07:00
Piotr Osiewicz a8f1c15a1e chore: Fix clippy::needless_borrow up to an editor 2024-01-21 15:03:24 +01:00
Joseph T. Lyons 60065c80db Add some initial testing to telemetry 2024-01-20 23:23:52 -05:00
Conrad Irwin 68402f737f Show cursors for remote participants (#4082)
This PR enables cursors for remote participants.

They are shown for 2 seconds when you focus a buffer, and then on hover.

Release Notes:

- Added usernames next to remote cursors
2024-01-18 20:58:09 -07:00
Conrad Irwin 9ed647ef72 Fine tune 2024-01-18 15:59:13 -07:00
Conrad Irwin 8ea05dc816 Send crash reports to Slack automatically (#4111)
This uploads apples crash reports to our servers when telemetry is
enabled.

Rather than jumping via the website, it uploads to collab directly. (I'd
like
to update the panic handler to do this too to make it possible to work
on that end-to-end without zed.dev running).

Release Notes:

- Added reporting of crashes when telemetry is enabled
2024-01-18 15:30:39 -07:00
Conrad Irwin 93b7de7363 Merge branch 'main' into cursors 2024-01-18 14:03:27 -07:00
Joseph T. Lyons a41f549339 Use try_global() 2024-01-18 01:33:30 -05:00
Conrad Irwin 86a5002ec3 Simplify service discovery in development 2024-01-17 23:06:03 -07:00
Conrad Irwin b8f29f1541 Upload panics via zed.dev instead 2024-01-17 22:55:15 -07:00
Conrad Irwin c4b153d088 Send crash reports to Slack automatically 2024-01-17 19:51:33 -07:00
Conrad Irwin 61e7739ca0 Show cursors for remote participants 2024-01-16 21:54:49 -07:00
Joseph T. Lyons 98826d0da4 Rename variable 2024-01-16 18:35:50 -05:00
Joseph T. Lyons c05ff85935 Remove dbg!()s 2024-01-16 18:33:43 -05:00
Joseph T. Lyons 126028a62d Do not reset timer for each reported event 2024-01-16 18:31:00 -05:00
Joseph T. Lyons 7a265e9121 Add command palette action events 2024-01-15 20:22:47 -05:00
Joseph T. Lyons 93ffacdf9f Remove button event function 2024-01-15 16:28:28 -05:00
Joseph T. Lyons 49c244bfb2 Removed button event 2024-01-15 16:26:56 -05:00
Joseph T. Lyons fa0ba2cca2 Add more open events
project search
diagnostics
welcome page
2024-01-15 16:26:04 -05:00
Mikayla 610455254b Don't open files unescessary in dev builds 2024-01-12 22:47:07 -08:00
Mikayla 3c34f6282d Restore temp file initialization in telemetry code 2024-01-12 21:37:09 -08:00
Max Brunsfeld 2e428719d4 Fix failure to write to keychain because of dropping a future 2024-01-11 16:22:34 -08:00
Joseph T. Lyons b6f58f07e6 Return a single Option from EventCoalescer 2024-01-11 12:27:59 -05:00
Joseph T. Lyons 9d094249c4 Only return environment when period ends 2024-01-11 11:30:22 -05:00
Joseph T. Lyons 4a26e632f6 Fix bug with improperly reported environment
When logging the edit environment, we were logging the newest environment being sent into the EventCoalescer on the latest activity log, when we should've been logging the environment that was associated with the ended period within the EventCoalescer.
2024-01-11 11:24:55 -05:00
Joseph T. Lyons 9ed59ba8c3 Increase debug mode queue size 2024-01-11 01:12:49 -05:00
Joseph T. Lyons 8aa67fbe3d Never send an an empty set of events 2024-01-11 01:12:30 -05:00
Joseph T. Lyons 78913b5f7c Add reminder for the future 2024-01-10 21:02:34 -05:00
Joseph T. Lyons bf796791a1 Rename field in telemetry struct 2024-01-10 17:41:02 -05:00
Joseph T. Lyons 082a81f0a8 WIP 2024-01-10 17:04:26 -05:00
Joseph T. Lyons 37caf3e06c Merge branch 'main' into instrument-keyboard-events 2024-01-10 16:03:01 -05:00
Joseph T. Lyons cef3f92861 WIP 2024-01-10 02:05:42 -05:00
Marshall Bowers 6c1b134e2f gpui: Add SharedUrl type (#3975)
This PR adds a `SharedUrl` type to GPUI.

It's just like a `SharedString`, but for denoting that the contained
value is a URL.

Mainlined from @nathansobo's GPUI blog post:
https://github.com/zed-industries/zed/pull/3968/files#diff-7ee75937e2daf7dd53f71b17698d8bd6d46993d06928d411781b9bd739b5f231R9-R12

Release Notes:

- N/A
2024-01-09 10:55:49 -05:00
Piotr OsiewiczandMarshall Bowers f90b05b716 Display setting documentation in settings.json (#3936)
Let this screenshot of settings.json speak for itself: 

![image](https://github.com/zed-industries/zed/assets/24362066/fca60383-1788-43f9-803b-00f083394c8a)

Release Notes:
- Added code completion & on-hover documentation to Zed's settings.json
file.

---------

Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
2024-01-08 19:30:18 +01:00
Piotr Osiewicz d9270b0abe gpui: Further docs refinement & moved some reexports into 'private' module (#3935)
This commit mostly fixes invalid URLs in docstrings. It also
encapsulates crates we reexport (serde stuff + linkme) into a public
module named "private" in order to reduce the API surfaced through docs.
Moreover, I fixed up a bunch of crates that were pulling serde_json in
through gpui explicitly instead of using Cargo manifest.

Release Notes:
- N/A
2024-01-07 14:14:21 +01:00
Joseph T. Lyons d55c3f88f9 Remove "clickhouse" from telemetry code
The client sends events to our end point, and the endpoint is what determines what analytics database is used to store the data. The client should be generic and not mention the name of the service being proxied to through our server.
2024-01-06 23:27:23 -05:00
Joseph T. Lyons 3431c14e32 Remove immediate flush mode
Allow flush method to be called publicly. This is a better, simpler solution, that allows for better control over flushing.
2024-01-06 20:27:30 -05:00
Joseph T. Lyons 73368099ed Fix tests 2024-01-06 16:10:40 -05:00