Nix flake for Logseq nightly packages.
It packages the Logseq Desktop nightly artifacts built by this repository's workflow and builds the Logseq CLI from upstream's shadow-cljs source. The current manifest is data/logseq-nightly.json.
Supported systems:
x86_64-linuxaarch64-linuxaarch64-darwin
| Output | Binary | Notes |
|---|---|---|
logseq |
logseq |
Desktop app |
logseq-cli |
logseq-cli |
CLI for Logseq DB graphs |
default |
both | Symlink join of desktop and CLI packages |
| overlay | n/a | Exposes the same packages under pkgs.logseq-nightly |
nix run --accept-flake-config github:Bad3r/nix-logseq-git-flake#logseq
nix run --accept-flake-config github:Bad3r/nix-logseq-git-flake#logseq-cli -- --helpThe flake advertises its Cachix cache through nixConfig, so
--accept-flake-config enables:
extra-substituters = [ "https://nix-logseq-git-flake.cachix.org" ];
extra-trusted-public-keys = [
"nix-logseq-git-flake.cachix.org-1:DSBNW07PSRyCvS926tpIWahb53OIydwwZhsP6LhJNZo="
];Add the input:
{
inputs.logseq-nightly = {
url = "github:Bad3r/nix-logseq-git-flake";
inputs.nixpkgs.follows = "nixpkgs";
};
}Use the packages directly from a module where inputs and pkgs are in scope:
environment.systemPackages = [
inputs.logseq-nightly.packages.${pkgs.stdenv.hostPlatform.system}.logseq
inputs.logseq-nightly.packages.${pkgs.stdenv.hostPlatform.system}.logseq-cli
];Or use the overlay:
nixpkgs.overlays = [ inputs.logseq-nightly.overlays.default ];
environment.systemPackages = [
pkgs.logseq-nightly.logseq
pkgs.logseq-nightly.logseq-cli
];Upstream's CLI self-identifies as logseq; this flake installs the wrapper as
logseq-cli so it can coexist with the desktop launcher.
logseq-cli --help
logseq-cli doctor
logseq-cli example <command>doctor is a smoke check for the shadow-cljs CLI runtime and bundled
db-worker-node.js. The db-worker requires keytar, whose native binding is
built from source with node-gyp (and libsecret on Linux); the
logseq-cli-help check boots the worker so a missing binding fails the build.
Current command groups include:
- Graph inspect and edit:
list,show,search,query,upsert,remove. - Graph management:
graph,graph backup,server,doctor. - Sync and auth:
sync,login,logout. - Utilities:
agent,completion,debug,example,skill.
Global options include -g/--graph, -o/--output, --root-dir, --config,
--timeout-ms, --profile, -v/--verbose, and --version.
data/logseq-nightly.json is generated data and is the source of truth for:
- per-system desktop artifact URLs and SRI hashes
- upstream Logseq revision and version
- CLI source, pnpm dependency, and Clojure dependency hashes
scripts/update-nightly.sh rewrites the manifest during the nightly release
flow. Manifest schema changes must update both that producer and
lib/loadManifest.nix.
Useful local checks:
nix build .#logseq
nix build .#logseq-cli
nix build .#checks.x86_64-linux.logseq-runtime-assets
nix build .#checks.x86_64-linux.logseq-cli-help
nix flake check --accept-flake-config --no-build --offline
nix fmtThe Darwin desktop package is validated by the validate-aarch64-darwin
workflow job, which builds the package on macOS, verifies the app signature, and
runs a bounded launch probe.