Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,39 @@ Connect to remote machines via SSH/SFTP to work with remote codebases. Emdash su
- AppImage (x64): https://github.com/generalaction/emdash/releases/latest/download/emdash-x86_64.AppImage
- Debian package (x64): https://github.com/generalaction/emdash/releases/latest/download/emdash-amd64.deb

### NixOS / Nix Flake

This repository exposes a Nix flake with `packages.<system>.emdash`. You can run it directly:

```bash
nix run github:generalaction/emdash
```

To install it as part of a NixOS or home-manager configuration, add the flake input and use the package:

```nix
# flake.nix
{
inputs.emdash.url = "github:generalaction/emdash";

# ... in your outputs:
# packages = [ inputs.emdash.packages.${system}.default ];
}
```

> **Note:** The `pnpmDeps` hash is pinned against the flake's own nixpkgs. If you
> override `emdash.inputs.nixpkgs.follows` to a different nixpkgs, the pnpm version
> may differ and produce a hash mismatch. In that case, run `nix build` once — Nix
> will print the correct hash in the error — then apply it:
>
> ```nix
> inputs.emdash.packages.${pkgs.system}.default.overrideAttrs (old: {
> pnpmDeps = old.pnpmDeps.overrideAttrs {
> outputHash = "<hash from error>";
> };
> });
> ```

### Release Overview

**[Latest Releases (macOS • Windows • Linux)](https://github.com/generalaction/emdash/releases/latest)**
Expand Down
23 changes: 11 additions & 12 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
outputs = { self, nixpkgs, flake-utils, ... }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
pkgs = import nixpkgs { localSystem = system; };
lib = pkgs.lib;
packageJson = builtins.fromJSON (builtins.readFile ./package.json);
pnpmPackageManager = packageJson.packageManager or "";
Expand Down Expand Up @@ -84,10 +84,10 @@
pkgs.automake
pkgs.coreutils
]
++ lib.optionals pkgs.stdenv.isDarwin [
++ lib.optionals pkgs.stdenv.hostPlatform.isDarwin [
pkgs.libiconv
]
++ lib.optionals pkgs.stdenv.isLinux [
++ lib.optionals pkgs.stdenv.hostPlatform.isLinux [
pkgs.libsecret
pkgs.sqlite
pkgs.zlib
Expand All @@ -96,7 +96,7 @@
];
cleanSrc = lib.cleanSource ./.;
emdashPackage =
if pkgs.stdenv.isLinux then
if pkgs.stdenv.hostPlatform.isLinux then
pkgs.stdenv.mkDerivation rec {
pname = "emdash";
version = packageJson.version;
Expand Down Expand Up @@ -144,16 +144,15 @@
pkgs.libdrm
pkgs.pango
pkgs.cairo
pkgs.xorg.libX11
pkgs.xorg.libXcomposite
pkgs.xorg.libXdamage
pkgs.xorg.libXext
pkgs.xorg.libXfixes
pkgs.xorg.libXrandr
pkgs.xorg.libxcb
pkgs.libx11
pkgs.libxcomposite
pkgs.libxdamage
pkgs.libxext
pkgs.libxfixes
pkgs.libxrandr
pkgs.libxcb
pkgs.libxkbcommon
pkgs.expat
pkgs.mesa.drivers
];
env = {
HOME = "$TMPDIR/emdash-home";
Expand Down
Loading