From 0db5318ffe22255524743dfee95d45a61939dc5d Mon Sep 17 00:00:00 2001 From: Andrea Ciceri Date: Sun, 5 Jun 2022 16:11:01 +0200 Subject: [PATCH] Things - `git-auto-commit-mode` for Emacs - different ZSH prompt for Emacs TRAMP mode - CI test --- .github/workflows/check.yml | 4 ++++ pkgs/emacs/default.nix | 4 +++- users/profiles/zsh/default.nix | 3 +++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 0b8c664..3968502 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -10,6 +10,9 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2.3.4 + - run: | + DEBIAN_FRONTEND=noninteractive + sudo apt-get update -q -y && sudo apt-get install -q -y qemu-system-aarch64 qemu-efi binfmt-support qemu-user-static - uses: cachix/install-nix-action@v17 with: extra_nix_config: > @@ -37,5 +40,6 @@ jobs: - run: echo "hello" # nix -Lv flake check - run: cat flake.nix - run: nix -Lv build ".#nixosConfigurations.pc.config.system.build.toplevel" + - run: nix -Lv build ".#nixosConfigurations.pbp.config.system.build.toplevel" --option system aarch64-linux - run: nix -Lv build ".#nixosConfigurations.hs.config.system.build.toplevel" - run: nix -Lv develop -c echo OK diff --git a/pkgs/emacs/default.nix b/pkgs/emacs/default.nix index 46c211f..b82f8cd 100644 --- a/pkgs/emacs/default.nix +++ b/pkgs/emacs/default.nix @@ -1,6 +1,7 @@ { pkgs, ... }: let - myEmacs = pkgs.emacsPgtkNativeComp; + # TODO: when `emcasPgtkNativeComp` will build on aarch64 re-use it + myEmacs = with pkgs; if stdenv.hostPlatform.isAarch64 then emacs else emacsPgtkNativeComp; emacsWithPackages = (pkgs.emacsPackagesFor myEmacs).emacsWithPackages; in emacsWithPackages ( @@ -23,6 +24,7 @@ emacsWithPackages ( evil-collection evil-tree-edit fira-code-mode + git-auto-commit-mode go-translate good-scroll haskell-mode diff --git a/users/profiles/zsh/default.nix b/users/profiles/zsh/default.nix index 382229d..5b04313 100644 --- a/users/profiles/zsh/default.nix +++ b/users/profiles/zsh/default.nix @@ -60,6 +60,9 @@ if pkgs.stdenv.hostPlatform.isDarwin then "if test -e /etc/static/bashrc; then source /etc/static/bashrc > /dev/null 2>&1; fi" else ""; + envExtra = '' + [ $TERM = "dumb" ] && unsetopt zle && PS1='$ ' # for Emacs TRAMP mode + ''; }; programs.command-not-found.enable = true;