Zed - rust based IDE

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

https://zed.dev/linux

2 Likes

There’s an upstream issue tracking this. support for snap or flatpak flathub · Issue #14145 · zed-industries/zed · GitHub

I imagine this is a straightforward one to snap, but would need to be classic.

2 Likes

OMW, I am working on Zed.

EDIT:

@popey I didn’t see the your comment in the issue. Sorry for that. If you need any help, this is my current manifest.

name: zed
base: core24
version: '0.143.6'
summary: Code at the speed of thought
description: |
  Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter. It's also open source.

grade: stable
confinement: classic

parts:
  zed:
    plugin: rust
    source: https://github.com/zed-industries/zed.git
    source-tag: 'v$SNAPCRAFT_PROJECT_VERSION'
    source-depth: 1
    build-environment:
      - CC: clang
    build-packages:
      - clang
      - cmake
      - libasound2-dev
      - libssl-dev
      - libvulkan-dev
      - libxcb1-dev
      - libxkbcommon-dev
      - libxkbcommon-x11-dev
      - libzstd-dev
      - mold
    stage-packages:
      - libasound2t64
      - libssl3t64
      - libvulkan1
      - libxcb1
      - libxkbcommon0
      - libxkbcommon-x11-0
      - libzstd1
      - sqlite3
    build-attributes:
      - enable-patchelf

apps:
  zed:
    command: bin/zed

don’t block on me, dive in :slight_smile:

2 Likes

I’ve been also trying to snap Zed Editor. And would like to contribute if possible.

By the way, seed like zed is already an registered name on Snap store. I’ve tried to submit request to handover. and this is the message i got from the reviewer.

Hello, Three-letter and shorter snap names are too generic and don’t provide a good idea of what the snap actually is or does. For that reason, we prefer and suggest you select a more descriptive name for your snap (zed-editor or other). Keep in mind that even if the snap has a larger name, a command called “zed” can still be provided by the snap using the “alias” functionality, see [1]. Let me know. Uf you pick a new name, you can simply register the new name.

  1. https://snapcraft.io/docs/commands-and-aliases

Regards

All new snaps have to go through a review. It’s not that they’re all already registered, just that there is an additional human gate in the way, to help prevent malware in the store.

zed-editor seems fine to me.

1 Like

Noted, thanks for the explanation :slight_smile:

Hi. I just wanted to share this in case it helps.

name: zed
summary: The editor for what's next
description: |
  Zed is a next-generation code editor designed for
  high-performance collaboration with humans and AI.
icon: share/icons/hicolor/1024x1024/apps/zed.png
base: core24
adopt-info: zed

website: https://zed.dev/

grade: devel
confinement: classic
compression: lzo

platforms:
  amd64:
  arm64:

apps:
  zed:
    command: bin/zed
    desktop: share/applications/zed.desktop

parts:
  zed:
    plugin: dump
    source:
      - on arm64: https://zed.dev/api/releases/stable/latest/zed-linux-aarch64.tar.gz
      - on amd64: https://zed.dev/api/releases/stable/latest/zed-linux-x86_64.tar.gz
    build-attributes:
      - disable-patchelf
    organize:
      zed.app/: ./
    override-pull: |
      craftctl default
      craftctl set version=$("$CRAFT_PART_SRC"/bin/zed --version | awk '{ print $2 }')
    override-stage: |
      sed -i -e 's,Icon=zed,Icon=${SNAP}/share/icons/hicolor/1024x1024/apps/zed.png,' "$CRAFT_PART_INSTALL"/share/applications/zed.desktop
      craftctl default

I’ve tested this locally on my arm64 system and it works great out of the box.

I have already snapped it… Just I am looking into improvements. I’ll create a PR by tomorrow or after UbuCon Asia is over.

1 Like

I think it’s better to build this from source.

I think this should be an upstream decision. The advantage of using the binary is that it gets wider testing than a source build.

2 Likes

Yeah, but I guess they prefer building from source? Because they have this,

The auto update will kick up if it’s not set while building.

I have created the PR, let’s see what happens

3 Likes