home: refactor common files
Signed-off-by: Amneesh Singh <natto@weirdnatto.in>
This commit is contained in:
38
home/common/emacs/default.nix
Normal file
38
home/common/emacs/default.nix
Normal file
@@ -0,0 +1,38 @@
|
||||
{ config, pkgs, inputs, lib, ... }:
|
||||
let
|
||||
emacs = pkgs.emacs-git-pgtk;
|
||||
configFile = ./config/emacs/config.org;
|
||||
enable = true;
|
||||
in
|
||||
{
|
||||
nixpkgs.overlays = [ inputs.emacs-overlay.overlays.default ];
|
||||
|
||||
home = {
|
||||
shellAliases = rec {
|
||||
e = "emacs";
|
||||
enw = e + " -nw";
|
||||
ec = "emacsclient";
|
||||
ecc = ec + " -c";
|
||||
ecnw = ec + " -nw";
|
||||
};
|
||||
};
|
||||
programs.emacs = {
|
||||
inherit enable;
|
||||
package = pkgs.emacsWithPackagesFromUsePackage {
|
||||
config = configFile;
|
||||
package = emacs;
|
||||
alwaysEnsure = true;
|
||||
alwaysTangle = true;
|
||||
defaultInitFile = true;
|
||||
extraEmacsPackages = epkgs: with epkgs; [
|
||||
use-package
|
||||
(tree-sitter-langs.withPlugins (_: tree-sitter-langs.plugins))
|
||||
];
|
||||
};
|
||||
};
|
||||
services.emacs = {
|
||||
inherit enable;
|
||||
defaultEditor = true;
|
||||
};
|
||||
systemd.user.services.emacs.Service.Environment = "COLORTERM=truecolor";
|
||||
}
|
20
home/common/fonts/default.nix
Normal file
20
home/common/fonts/default.nix
Normal file
@@ -0,0 +1,20 @@
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
fira-code
|
||||
fira-mono
|
||||
monoid
|
||||
font-awesome
|
||||
material-icons
|
||||
material-design-icons
|
||||
lohit-fonts.devanagari
|
||||
lohit-fonts.gurmukhi
|
||||
office-code-pro
|
||||
eb-garamond
|
||||
noto-fonts-cjk-sans
|
||||
takao
|
||||
liberation_ttf
|
||||
];
|
||||
|
||||
fonts.fontconfig.enable = true;
|
||||
}
|
Reference in New Issue
Block a user