From 0daed2e5aa19a1a4742b487f08f739c7660bfb45 Mon Sep 17 00:00:00 2001 From: greg-compass Date: Mon, 10 Apr 2023 13:12:30 -0500 Subject: [PATCH 01/18] Add Compass compile command --- home/xonsh.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/home/xonsh.nix b/home/xonsh.nix index 85e0148..51d875c 100644 --- a/home/xonsh.nix +++ b/home/xonsh.nix @@ -39,6 +39,7 @@ crun = "compass workspace run"; ctest = "compass workspace test"; cylint = "./scripts/run_yaml_lint.py"; + cpip = "compass workspace run src/python3/uc/tools:run_pip_compile"; cleanup = "nix-collect-garbage -d && nix store optimise"; d = "vox deactivate"; From 8ff5c3ea3d097cc437b096f7c26b08581c517743 Mon Sep 17 00:00:00 2001 From: greg-compass Date: Mon, 12 Jun 2023 10:28:37 -0500 Subject: [PATCH 02/18] Do not install pip.conf on this machine --- home/home.nix | 9 --------- 1 file changed, 9 deletions(-) diff --git a/home/home.nix b/home/home.nix index 04ccc2d..5a05736 100644 --- a/home/home.nix +++ b/home/home.nix @@ -31,15 +31,6 @@ ]); }; - home.file.".pip/pip.conf".text = (lib.strings.concatStringsSep "\n" [ - "[global]" - "retries = 1" - "index-url = https://pypi.python.org/simple" - "extra-index-url =" - " https://pypi.ivrtechnology.com/simple/" - " https://pypidev.ivrtechnology.com/simple/" - ]); - home.stateVersion = "23.05"; home.packages = with pkgs; [ bitwarden-cli From 45832980fdb7a409d79a7e74a21252532993029c Mon Sep 17 00:00:00 2001 From: greg-compass Date: Mon, 12 Jun 2023 11:09:10 -0500 Subject: [PATCH 03/18] Append /usr/local/bin/ to PATH --- home/xonsh_header.xsh | 1 + 1 file changed, 1 insertion(+) diff --git a/home/xonsh_header.xsh b/home/xonsh_header.xsh index 1c332a3..cb378ff 100644 --- a/home/xonsh_header.xsh +++ b/home/xonsh_header.xsh @@ -25,3 +25,4 @@ if platform == "darwin": $PATH.append(Path("/opt/homebrew/bin/")) $PATH.append(Path("/run/current-system/sw/bin")) $PATH.append(Path("/nix/var/nix/profiles/default/bin")) + $PATH.append(Path("/usr/local/bin")) From 9544525f4de6c0497ea0b48d3d3b0ee42c328f46 Mon Sep 17 00:00:00 2001 From: greg-compass Date: Thu, 22 Jun 2023 12:02:44 -0500 Subject: [PATCH 04/18] Update xonsh --- overlays/default.nix | 4 +- overlays/xonsh.nix | 94 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 97 insertions(+), 1 deletion(-) create mode 100644 overlays/xonsh.nix diff --git a/overlays/default.nix b/overlays/default.nix index e1c9ca1..63221d5 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -65,7 +65,9 @@ in rec { pkgs = final.pkgs; }; - xonsh = prev.xonsh.overridePythonAttrs (old: rec{ + xonsh = (prev.callPackage ./xonsh.nix { + #inherit (final) lib coreutils python3Packages git; + }).overridePythonAttrs (old: rec{ python3 = final.gregpy; propagatedBuildInputs = with final.gregpy.pkgs; old.propagatedBuildInputs ++ [ xonsh-apipenv diff --git a/overlays/xonsh.nix b/overlays/xonsh.nix new file mode 100644 index 0000000..d8dce91 --- /dev/null +++ b/overlays/xonsh.nix @@ -0,0 +1,94 @@ +{ lib +, fetchFromGitHub +, python3Packages +, glibcLocales +, coreutils +, git +}: + +python3Packages.buildPythonApplication rec { + pname = "xonsh"; + version = "0.14.0"; + + # fetch from github because the pypi package ships incomplete tests + src = fetchFromGitHub { + owner = "xonsh"; + repo = "xonsh"; + rev = "refs/tags/${version}"; + sha256 = "sha256-ZrPKKa/vl06QAjGr16ZzKF/DAByFHr6ze2WVOCa+wf8="; + }; + + LC_ALL = "en_US.UTF-8"; + + postPatch = '' + sed -ie "s|/bin/ls|${coreutils}/bin/ls|" tests/test_execer.py + sed -ie "s|SHELL=xonsh|SHELL=$out/bin/xonsh|" tests/test_integrations.py + + sed -ie 's|/usr/bin/env|${coreutils}/bin/env|' tests/test_integrations.py + sed -ie 's|/usr/bin/env|${coreutils}/bin/env|' scripts/xon.sh + find scripts -name 'xonsh*' -exec sed -i -e "s|env -S|env|" {} \; + find -name "*.xsh" | xargs sed -ie 's|/usr/bin/env|${coreutils}/bin/env|' + patchShebangs . + + substituteInPlace scripts/xon.sh \ + --replace 'python' "${python3Packages.python}/bin/python" + + ''; + + makeWrapperArgs = [ + "--prefix PYTHONPATH : ${placeholder "out"}/lib/${python3Packages.python.libPrefix}/site-packages" + ]; + + postInstall = '' + wrapProgram $out/bin/xonsh \ + $makeWrapperArgs + ''; + + disabledTests = [ + # fails on sandbox + "test_colorize_file" + "test_loading_correctly" + "test_no_command_path_completion" + "test_bsd_man_page_completions" + "test_xonsh_activator" + # fails on non-interactive shells + "test_capture_always" + "test_casting" + "test_command_pipeline_capture" + "test_dirty_working_directory" + "test_man_completion" + "test_vc_get_branch" + "test_bash_and_is_alias_is_only_functional_alias" + ]; + + disabledTestPaths = [ + # fails on sandbox + "tests/completers/test_command_completers.py" + "tests/test_ptk_highlight.py" + "tests/test_ptk_shell.py" + # fails on non-interactive shells + "tests/prompt/test_gitstatus.py" + "tests/completers/test_bash_completer.py" + ]; + + preCheck = '' + HOME=$TMPDIR + ''; + + nativeCheckInputs = [ glibcLocales git ] ++ + (with python3Packages; [ pyte pytestCheckHook pytest-mock pytest-subprocess ]); + + propagatedBuildInputs = with python3Packages; [ ply prompt-toolkit pygments ]; + + meta = with lib; { + description = "A Python-ish, BASHwards-compatible shell"; + homepage = "https://xon.sh/"; + changelog = "https://github.com/xonsh/xonsh/raw/${version}/CHANGELOG.rst"; + license = licenses.bsd3; + maintainers = with maintainers; [ vrthra ]; + }; + + passthru = { + shellPath = "/bin/xonsh"; + }; +} From 9369ed69a2b44a33653f87198508c1d0e1cc95ec Mon Sep 17 00:00:00 2001 From: greg-compass Date: Thu, 22 Jun 2023 12:54:08 -0500 Subject: [PATCH 05/18] Add xontrib-vox --- overlays/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/overlays/default.nix b/overlays/default.nix index 63221d5..1d3c84d 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -51,6 +51,7 @@ in rec { iteration-utilities = cp ./iteration-utilities.nix {}; jinja2-ansible-filters = cp ./jinja2-ansible-filters.nix {}; pyyaml-include = cp ./pyyaml-include.nix {}; + xonsh-vox = cp ./xonsh-vox.nix {}; }) ]; From 96e7ccfb67224334efd856f5822674fcde1306db Mon Sep 17 00:00:00 2001 From: greg-compass Date: Fri, 30 Jun 2023 23:41:46 -0500 Subject: [PATCH 06/18] Update xontrib-vox --- home/gui/default.nix | 6 +++++- overlays/xonsh-vox.nix | 2 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/home/gui/default.nix b/home/gui/default.nix index 1b803b8..d11a55d 100644 --- a/home/gui/default.nix +++ b/home/gui/default.nix @@ -15,7 +15,6 @@ in home.packages = with pkgs; [ cdrtools ffmpeg - gnucash handbrake libtheora makemkv @@ -45,5 +44,10 @@ in bitwarden onlyoffice-bin zoom-us + ]) ++ + + ( excludes ["aarch64-darwin" "x86_64-darwin"] + [ + gnucash ]); } diff --git a/overlays/xonsh-vox.nix b/overlays/xonsh-vox.nix index 6a458fe..4b7802e 100644 --- a/overlays/xonsh-vox.nix +++ b/overlays/xonsh-vox.nix @@ -22,6 +22,8 @@ buildPythonPackage rec { maintainers = []; }; + patchPhase = "sed -i -e 's/^dependencies.*$/dependencies = []/' pyproject.toml"; + doCheck = false; nativeBuildInputs = [ From 107468172ff374ac40fd31bda6d0f64614ac17bd Mon Sep 17 00:00:00 2001 From: greg-compass Date: Mon, 14 Aug 2023 09:52:44 -0500 Subject: [PATCH 07/18] Move to homebrew on Mac --- darwin/default.nix | 2 +- darwin/work/default.nix | 22 +++++++++++++--------- home/home.nix | 2 +- 3 files changed, 15 insertions(+), 11 deletions(-) diff --git a/darwin/default.nix b/darwin/default.nix index 2124885..2bd39f1 100644 --- a/darwin/default.nix +++ b/darwin/default.nix @@ -23,7 +23,7 @@ let extraSpecialArgs = { inherit inputs; gnome = false; - gui = true; + gui = false; home = "/Users/gregory.hellings"; }; }; diff --git a/darwin/work/default.nix b/darwin/work/default.nix index 7992605..33a8276 100644 --- a/darwin/work/default.nix +++ b/darwin/work/default.nix @@ -1,13 +1,17 @@ { pkgs, ... }: { - #greg.pypackages = with pkgs; [ - # dateutil - # ipython - # pyyaml - # responses - # ruamel-yaml - # typing-extensions - # virtualenv - #]; + homebrew = { + enable = true; + brews = [ + "packer" + ]; + casks = [ + "gnucash" + "onlyoffice" + "postman" + "vagrant" + "vmware-fusion" + ]; + }; } diff --git a/home/home.nix b/home/home.nix index 5a05736..301be15 100644 --- a/home/home.nix +++ b/home/home.nix @@ -36,7 +36,6 @@ bitwarden-cli brew diffutils - dmidecode findutils gimp git @@ -47,6 +46,7 @@ inetutils jq nano + nix-prefetch nmap openssl setup-ssh From 854e60d450753b32e97c536e5648f627852bba29 Mon Sep 17 00:00:00 2001 From: greg-compass Date: Thu, 17 Aug 2023 13:54:50 -0500 Subject: [PATCH 08/18] Remove vmware-fusion --- darwin/work/default.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/darwin/work/default.nix b/darwin/work/default.nix index 33a8276..6cf2e8d 100644 --- a/darwin/work/default.nix +++ b/darwin/work/default.nix @@ -11,7 +11,6 @@ "onlyoffice" "postman" "vagrant" - "vmware-fusion" ]; }; } From ba6a4e3694fb330dac6712730fd639410e4e557c Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Fri, 18 Aug 2023 13:16:23 -0500 Subject: [PATCH 09/18] Updating editor --- darwin/work/default.nix | 1 + flake.lock | 6 +++--- home/vim.nix | 39 +-------------------------------------- home/xonsh.nix | 2 +- 4 files changed, 6 insertions(+), 42 deletions(-) diff --git a/darwin/work/default.nix b/darwin/work/default.nix index 6cf2e8d..7b5442c 100644 --- a/darwin/work/default.nix +++ b/darwin/work/default.nix @@ -13,4 +13,5 @@ "vagrant" ]; }; + environment.loginShell = "${pkgs.xonsh}/bin/xonsh"; } diff --git a/flake.lock b/flake.lock index e43165c..6142626 100644 --- a/flake.lock +++ b/flake.lock @@ -49,11 +49,11 @@ ] }, "locked": { - "lastModified": 1689516967, - "narHash": "sha256-sFAa33wkQHanmij/uhfGduIDK8z4dJAita/rK6u9pvE=", + "lastModified": 1692248770, + "narHash": "sha256-tZeFpETKQGbgnaSIO1AGWD27IyTcBm4D+A9d7ulQ4NM=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "61662a63bfe1726588c1da6b412df86d8ca94d63", + "rev": "511177ffe8226c78c9cf6a92a7b5f2df3684956b", "type": "github" }, "original": { diff --git a/home/vim.nix b/home/vim.nix index 1546038..4d4c685 100644 --- a/home/vim.nix +++ b/home/vim.nix @@ -27,43 +27,6 @@ in pyright ]; - #programs.neovim = { - # enable = true; - # viAlias = true; - # vimAlias = true; - # vimdiffAlias = true; - # plugins = with pkgs.vimPlugins; [ - # ansible-vim - # bufexplorer -# -# #cmp-nvim-lsp -# #cmp-vsnip -# #nvim-lspconfig -# nvim-cmp -# -# jedi-vim -# -# context-vim -# direnv-vim -# fzf-vim -# nerdtree -# nvim-notify -# vim-airline -# vim-gitgutter -# vim-flake8 -# vim-fugitive -# vim-indent-guides -# vim-packer -# vim-rooter -# vim-xonsh -# gruvbox -# ]; -# extraLuaConfig = builtins.readFile ./init.lua; -# coc = { -# # Currently waiting on resolution of https://github.com/NixOS/nixpkgs/issues/236560 -# enable = false; -# }; -# }; programs.nixneovim = { enable = true; colorscheme = "gruvbox"; @@ -135,7 +98,7 @@ in nerdtree nvim-cmp - jedi-vim + #jedi-vim context-vim direnv-vim diff --git a/home/xonsh.nix b/home/xonsh.nix index 51d875c..029a3da 100644 --- a/home/xonsh.nix +++ b/home/xonsh.nix @@ -37,7 +37,7 @@ cci = "./scripts/circleci-checks.py"; cgh = "$GH_CONFIG_DIR=\"${config.home.homeDirectory}/.config/gh/compass\" gh"; crun = "compass workspace run"; - ctest = "compass workspace test"; + ctest = "compass workspace test --extra-cmd-args=\"--test_output=errors\""; cylint = "./scripts/run_yaml_lint.py"; cpip = "compass workspace run src/python3/uc/tools:run_pip_compile"; From 50223fb8f75070031d9a470b0ef9724cc8f65198 Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Wed, 23 Aug 2023 14:03:13 -0500 Subject: [PATCH 10/18] Add vscodium configuration --- darwin/default.nix | 1 + home/gui/default.nix | 28 ++++++++-------------------- home/home.nix | 5 +++-- home/mac.nix | 18 ++++++++++++++++++ 4 files changed, 30 insertions(+), 22 deletions(-) create mode 100644 home/mac.nix diff --git a/darwin/default.nix b/darwin/default.nix index 2bd39f1..e89f214 100644 --- a/darwin/default.nix +++ b/darwin/default.nix @@ -25,6 +25,7 @@ let gnome = false; gui = false; home = "/Users/gregory.hellings"; + mac = true; }; }; users.users."gregory.hellings".home = "/Users/gregory.hellings"; diff --git a/home/gui/default.nix b/home/gui/default.nix index d11a55d..9f8ece8 100644 --- a/home/gui/default.nix +++ b/home/gui/default.nix @@ -12,7 +12,9 @@ in ./firefox.nix ]; - home.packages = with pkgs; [ + # These packages are Linux only + home.packages = with pkgs; ( excludes ["x86_64-darwin" "aarch64-darwin"] + [ cdrtools ffmpeg handbrake @@ -20,34 +22,20 @@ in makemkv vlc x265 - ] ++ + ]) ++ - # Items that cannot be outside of x86_64-linux at all + # x86_64-linux only ( excludes ["x86_64-darwin" "aarch64-darwin" "aarch64-linux"] [ + bitwarden endeavour + gnucash jellyfin-media-player libreoffice logseq nextcloud-client - ]) ++ - - # Items that just cannot be outside of x86_64 at all - ( excludes ["aarch64-darwin" "aarch64-linux"] - [ - synology-drive-client - ]) ++ - - # Items that are not supported on ARM/Linux - ( excludes ["aarch64-linux"] - [ - bitwarden onlyoffice-bin + synology-drive-client zoom-us - ]) ++ - - ( excludes ["aarch64-darwin" "x86_64-darwin"] - [ - gnucash ]); } diff --git a/home/home.nix b/home/home.nix index 301be15..978c8ea 100644 --- a/home/home.nix +++ b/home/home.nix @@ -1,5 +1,5 @@ { pkgs, lib, gui, gnome, - inputs, + inputs, mac, ...}: { @@ -14,7 +14,8 @@ ./templates.nix ./vim.nix ./xonsh.nix - ] ++ ( if gui then [ ./gui ] else []); + ] ++ ( if gui then [ ./gui ] else []) + ++ ( if mac then [ ./mac.nix ] else []); greg.gnome = gnome; diff --git a/home/mac.nix b/home/mac.nix new file mode 100644 index 0000000..f724bdd --- /dev/null +++ b/home/mac.nix @@ -0,0 +1,18 @@ +{ pkgs, ... }: + +{ + # Programs for everyone? + programs.vscode = { + enable = true; + package = pkgs.vscodium; + extensions = with pkgs.vscode-extensions; [ + golang.go + ms-python.python + ms-pyright.pyright + vscjava.vscode-java-test + vscjava.vscode-java-dependency + vscjava.vscode-java-debug + vscodevim.vim + ]; + }; +} From 23d4ffc12be8b0952ceac4248691243a593a7a46 Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Wed, 23 Aug 2023 14:49:01 -0500 Subject: [PATCH 11/18] Try to fix issues in Darwin optimise --- modules-all/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/modules-all/default.nix b/modules-all/default.nix index ecbdcad..ed7821e 100644 --- a/modules-all/default.nix +++ b/modules-all/default.nix @@ -1,4 +1,4 @@ -{ pkgs, ... }: +{ pkgs, lib, ... }: { # Enable flakes @@ -18,12 +18,14 @@ gc = { automatic = true; - dates = "weekly"; + interval = { + Hour = 24; + }; options = "--delete-older-than 30d"; }; settings = { - auto-optimise-store = true; + auto-optimise-store = (if lib.strings.hasSuffix "darwin" pkgs.system then false else true); experimental-features = "nix-command flakes"; keep-outputs = true; keep-derivations = true; From 730cefd17579d0913c07c11c64514c287f680a0b Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Wed, 23 Aug 2023 14:49:34 -0500 Subject: [PATCH 12/18] Remove Mac-only overlays --- overlays/default.nix | 6 ------ overlays/mac/bitwarden.nix | 32 -------------------------------- overlays/mac/gnucash.nix | 32 -------------------------------- overlays/mac/handbrake.nix | 32 -------------------------------- overlays/mac/onlyoffice-bin.nix | 32 -------------------------------- overlays/mac/vlc.nix | 32 -------------------------------- 6 files changed, 166 deletions(-) delete mode 100644 overlays/mac/bitwarden.nix delete mode 100644 overlays/mac/gnucash.nix delete mode 100644 overlays/mac/handbrake.nix delete mode 100644 overlays/mac/onlyoffice-bin.nix delete mode 100644 overlays/mac/vlc.nix diff --git a/overlays/default.nix b/overlays/default.nix index 0906666..4dbf372 100644 --- a/overlays/default.nix +++ b/overlays/default.nix @@ -75,10 +75,4 @@ in rec { xontrib-vox ]; }); - - #bitwarden = macOver ./mac/bitwarden.nix "bitwarden"; - #gnucash = macOver ./mac/gnucash.nix "gnucash"; - #handbrake = macOver ./mac/handbrake.nix "handbrake"; - #onlyoffice-bin = macOver ./mac/onlyoffice-bin.nix "onlyoffice-bin"; - #vlc = macOver ./mac/vlc.nix "vlc"; } diff --git a/overlays/mac/bitwarden.nix b/overlays/mac/bitwarden.nix deleted file mode 100644 index 6c9277c..0000000 --- a/overlays/mac/bitwarden.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ stdenv, fetchurl, - undmg, -}: - -stdenv.mkDerivation rec { - version = "2022.10.1"; - pname = "Bitwarden"; - - buildInputs = [ - undmg - ]; - sourceRoot = "."; - phases = [ - "unpackPhase" - "installPhase" - ]; - installPhase = '' - mkdir -p "$out/Applications" - cp -r Bitwarden*.app "$out/Applications" - ''; - - src = fetchurl { - name = "Bitwarden-${version}.dmg"; - url = "https://github.com/bitwarden/clients/releases/download/desktop-v${version}/Bitwarden-${version}-universal.dmg"; - sha256 = "sha256-6O8xaGBaG4d6l9QRtGM5wj9OCMFy87dH8N1MfEBBjck="; - }; - - meta = { - description = "Bitwarden, an open source password management tool"; - homepage = "https://bitwarden.com"; - }; -} diff --git a/overlays/mac/gnucash.nix b/overlays/mac/gnucash.nix deleted file mode 100644 index ea4c398..0000000 --- a/overlays/mac/gnucash.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ stdenv, fetchurl, - undmg, -}: - -stdenv.mkDerivation rec { - version = "4.12"; - pname = "GnuCash"; - - buildInputs = [ - undmg - ]; - sourceRoot = "."; - phases = [ - "unpackPhase" - "installPhase" - ]; - installPhase = '' - mkdir -p "$out/Applications" - cp -r Gnucash*.app "$out/Applications" - ''; - - src = fetchurl { - name = "${pname}-${version}.dmg"; - url = "https://sourceforge.net/projects/gnucash/files/gnucash%20(stable)/${version}/Gnucash-Intel-${version}-1.dmg"; - sha256 = "sha256-GXsGOk+F/QdcD19ZmZmor0upCFHa7iy3Hs4CLbiby1M="; - }; - - meta = { - description = "GnuCash is free accounting software for your local machine"; - homepage = "https://www.gnucash.org"; - }; -} diff --git a/overlays/mac/handbrake.nix b/overlays/mac/handbrake.nix deleted file mode 100644 index 4ce96b1..0000000 --- a/overlays/mac/handbrake.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ stdenv, fetchurl, - undmg, -}: - -stdenv.mkDerivation rec { - version = "1.5.1"; - pname = "HandBrake"; - - buildInputs = [ - undmg - ]; - sourceRoot = "."; - phases = [ - "unpackPhase" - "installPhase" - ]; - installPhase = '' - mkdir -p "$out/Applications" - cp -r ${pname}*.app "$out/Applications" - ''; - - src = fetchurl { - name = "${pname}-${version}.dmg"; - url = "https://github.com/HandBrake/HandBrake/releases/download/${version}/${pname}-${version}.dmg"; - sha256 = "sha256-dnyxYxTjhpxCz/eNuSvK16f6qGHHD5exMm/jaGxith8="; - }; - - meta = { - description = "HandBrake is an open source video transcoder"; - homepage = "https://handbrake.fr/"; - }; -} diff --git a/overlays/mac/onlyoffice-bin.nix b/overlays/mac/onlyoffice-bin.nix deleted file mode 100644 index c9918bf..0000000 --- a/overlays/mac/onlyoffice-bin.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ stdenv, fetchurl, - undmg, -}: - -stdenv.mkDerivation rec { - version = "7.2.1"; - pname = "onlyoffice"; - - buildInputs = [ - undmg - ]; - sourceRoot = "."; - phases = [ - "unpackPhase" - "installPhase" - ]; - installPhase = '' - mkdir -p "$out/Applications" - cp -r *.app "$out/Applications" - ''; - - src = fetchurl { - name = "${pname}-${version}.dmg"; - url = "https://github.com/ONLYOFFICE/DesktopEditors/releases/download/v${version}/ONLYOFFICE-x86_64.dmg"; - sha256 = "sha256-dsuTaZ+IqsDE/j78ht0Md5NoqQ090cJ4u5LClu3tSp0="; - }; - - meta = { - description = "OnlyOffice provides a suite of Office-like document editors for the desktop and web."; - homepage = "https://www.onlyoffice.com/"; - }; -} diff --git a/overlays/mac/vlc.nix b/overlays/mac/vlc.nix deleted file mode 100644 index ad9b25c..0000000 --- a/overlays/mac/vlc.nix +++ /dev/null @@ -1,32 +0,0 @@ -{ stdenv, fetchurl, - undmg, -}: - -stdenv.mkDerivation rec { - version = "3.0.17.3"; - pname = "vlc"; - - buildInputs = [ - undmg - ]; - sourceRoot = "."; - phases = [ - "unpackPhase" - "installPhase" - ]; - installPhase = '' - mkdir -p "$out/Applications" - cp -r *.app "$out/Applications" - ''; - - src = fetchurl { - name = "${pname}-${version}.dmg"; - url = "https://get.videolan.org/vlc/${version}/macosx/${pname}-${version}-intel64.dmg"; - sha256 = "sha256-zKJn8sUa5WjgLztNimrbqHsr3l8BGiuHxZXBAtifEdg="; - }; - - meta = { - description = "VLC is a very versatile video player."; - homepage = "https://www.videolan.org/"; - }; -} From 97c9b4e2d7c47c9ac931c9d05bd12ac8d33433af Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Wed, 23 Aug 2023 14:58:10 -0500 Subject: [PATCH 13/18] Make vscodium more accessible --- home/gui/default.nix | 15 --------------- home/hosts/work/default.nix | 4 ++++ home/vscodium.nix | 18 ++++++++++++++++++ 3 files changed, 22 insertions(+), 15 deletions(-) create mode 100644 home/vscodium.nix diff --git a/home/gui/default.nix b/home/gui/default.nix index 835fed8..227de86 100644 --- a/home/gui/default.nix +++ b/home/gui/default.nix @@ -12,21 +12,6 @@ in ./firefox.nix ]; - # An alternative editor to vim, when I need it for some things - programs.vscode = { - enable = true; - package = pkgs.vscodium; - extensions = with pkgs.vscode-extensions; [ - golang.go - ms-python.python - ms-pyright.pyright - vscjava.vscode-java-test - vscjava.vscode-java-dependency - vscjava.vscode-java-debug - vscodevim.vim - ]; - }; - # These packages are Linux only home.packages = with pkgs; ( excludes ["x86_64-darwin" "aarch64-darwin"] [ diff --git a/home/hosts/work/default.nix b/home/hosts/work/default.nix index 7c60c06..0ba0b6e 100644 --- a/home/hosts/work/default.nix +++ b/home/hosts/work/default.nix @@ -1,6 +1,10 @@ { pkgs, ... }: { + imports = [ + ../../vscodium.nix + ]; + home.packages = with pkgs; [ brew ]; diff --git a/home/vscodium.nix b/home/vscodium.nix new file mode 100644 index 0000000..82b5943 --- /dev/null +++ b/home/vscodium.nix @@ -0,0 +1,18 @@ +{ pkgs, ... }: + +{ + # An alternative editor to vim, when I need it for some things + programs.vscode = { + enable = true; + package = pkgs.vscodium; + extensions = with pkgs.vscode-extensions; [ + golang.go + ms-python.python + ms-pyright.pyright + vscjava.vscode-java-test + vscjava.vscode-java-dependency + vscjava.vscode-java-debug + vscodevim.vim + ]; + }; +} From a17dc1f48397ad455c6348c9d02abba0c2b0d10b Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Wed, 23 Aug 2023 14:58:38 -0500 Subject: [PATCH 14/18] Add vscodium on Jude --- home/hosts/jude/default.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/home/hosts/jude/default.nix b/home/hosts/jude/default.nix index 25e1a0f..1a7fa80 100644 --- a/home/hosts/jude/default.nix +++ b/home/hosts/jude/default.nix @@ -1,6 +1,10 @@ { pkgs, ... }: { + imports = [ + ../../vscodium.nix + ]; + home.packages = with pkgs; [ gimp gnucash From 5f55a95842883e3b15134723d23f20d128beb0c8 Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Wed, 23 Aug 2023 15:02:12 -0500 Subject: [PATCH 15/18] Fix nix cleanup interval dates --- modules-all/default.nix | 5 ++--- modules-darwin/default.nix | 1 + modules-linux/default.nix | 2 ++ 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/modules-all/default.nix b/modules-all/default.nix index ed7821e..3871f4c 100644 --- a/modules-all/default.nix +++ b/modules-all/default.nix @@ -18,9 +18,8 @@ gc = { automatic = true; - interval = { - Hour = 24; - }; + # Scheduling of them is different in nixos vs nix-darwin, so check for + # the extra details there options = "--delete-older-than 30d"; }; diff --git a/modules-darwin/default.nix b/modules-darwin/default.nix index 81c4be2..7979b86 100644 --- a/modules-darwin/default.nix +++ b/modules-darwin/default.nix @@ -7,4 +7,5 @@ bash.enable = true; }; services.nix-daemon.enable = true; + nix.gc.interval.Hour = 24; } diff --git a/modules-linux/default.nix b/modules-linux/default.nix index 041e0d4..e3b05b8 100644 --- a/modules-linux/default.nix +++ b/modules-linux/default.nix @@ -17,6 +17,8 @@ system.stateVersion = "22.05"; + nix.gc.dates = "weekly"; + # I am a fan of network manager, myself networking = { search = [ From 0b6f288953dfa4d444dec081dd313d498aff1f8c Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Thu, 24 Aug 2023 00:47:10 -0500 Subject: [PATCH 16/18] Add lshw to general tools --- modules-all/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/modules-all/default.nix b/modules-all/default.nix index 3871f4c..46b9f93 100644 --- a/modules-all/default.nix +++ b/modules-all/default.nix @@ -60,6 +60,7 @@ hms # My own home manager switcher htop killall + lshw nano pciutils pwgen From a2cc6d69d91320429bd56cfa4d592927a7bc9327 Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Thu, 24 Aug 2023 10:50:56 -0500 Subject: [PATCH 17/18] Add needed go tools for codium --- home/vscodium.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/home/vscodium.nix b/home/vscodium.nix index 82b5943..b660cbb 100644 --- a/home/vscodium.nix +++ b/home/vscodium.nix @@ -1,6 +1,10 @@ { pkgs, ... }: { + home.packages = with pkgs; [ + gopls + ]; + # An alternative editor to vim, when I need it for some things programs.vscode = { enable = true; From 2512a045c1a14c26f901392ad211a428110e1676 Mon Sep 17 00:00:00 2001 From: Greg Hellings Date: Thu, 24 Aug 2023 23:05:53 -0500 Subject: [PATCH 18/18] Improve codium --- home/home.nix | 1 - home/hosts/jude/default.nix | 11 ----------- home/vscodium.nix | 1 - hosts/jude/default.nix | 23 +++++++++++++++++------ 4 files changed, 17 insertions(+), 19 deletions(-) diff --git a/home/home.nix b/home/home.nix index 1b1d098..010381c 100644 --- a/home/home.nix +++ b/home/home.nix @@ -58,6 +58,5 @@ ] ++ ( if pkgs.system == "x86_64-linux" || pkgs.system == "aarch64-linux" then # Linux-only packages here [ - busybox ] else []); } diff --git a/home/hosts/jude/default.nix b/home/hosts/jude/default.nix index 1a7fa80..c0cd0ad 100644 --- a/home/hosts/jude/default.nix +++ b/home/hosts/jude/default.nix @@ -4,15 +4,4 @@ imports = [ ../../vscodium.nix ]; - - home.packages = with pkgs; [ - gimp - gnucash - ffmpeg - handbrake - libtheora - makemkv - synology-drive-client - vagrant - ]; } diff --git a/home/vscodium.nix b/home/vscodium.nix index b660cbb..a828006 100644 --- a/home/vscodium.nix +++ b/home/vscodium.nix @@ -12,7 +12,6 @@ extensions = with pkgs.vscode-extensions; [ golang.go ms-python.python - ms-pyright.pyright vscjava.vscode-java-test vscjava.vscode-java-dependency vscjava.vscode-java-debug diff --git a/hosts/jude/default.nix b/hosts/jude/default.nix index 35ee182..681ca1f 100644 --- a/hosts/jude/default.nix +++ b/hosts/jude/default.nix @@ -8,7 +8,11 @@ ./printing.nix ./virt.nix ]; - programs.steam.enable = true; + programs = { + steam.enable = true; + nix-ld.enable = true; + }; + networking.hostName = "jude"; networking.enableIPv6 = false; #systemd.oomd.enable = false; @@ -17,19 +21,26 @@ greg.kde.enable = false; environment.systemPackages = with pkgs; [ + busybox + gimp + gnucash + flock + ffmpeg + handbrake + libtheora + makemkv + oathToolkit + synology-drive-client + vagrant + # Video/Audio data composition framework tools like "gst-inspect", "gst-launch" ... gst_all_1.gstreamer - # Common plugins like "filesrc" to combine within e.g. gst-launch gst_all_1.gst-plugins-base - # Specialized plugins separated by quality gst_all_1.gst-plugins-good gst_all_1.gst-plugins-bad gst_all_1.gst-plugins-ugly - # Plugins to reuse ffmpeg to play almost every video format gst_all_1.gst-libav - # Support the Video Audio (Hardware) Acceleration API gst_all_1.gst-vaapi - oathToolkit ]; fileSystems = { "/boot" = {