build helix from main

This commit is contained in:
zoe 2023-03-26 15:37:29 +02:00
parent d004d4b161
commit dcce72e300
6 changed files with 62 additions and 73 deletions

View File

@ -17,9 +17,9 @@
nix.settings = {
substituters = [
"https://hyprland.cachix.org"
"https://helix.cachix.org"
];
trusted-public-keys = [ "hyprland.cachix.org-1:a7pgxzMz7+chwVL3/pzj6jIBMioiJM7ypFP8PwtkuGc=" ];
trusted-public-keys = [ "helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs=" ];
};
nix.settings.experimental-features = [ "nix-command" "flakes" ];

View File

@ -6,22 +6,17 @@
supercolor.url = "github:zoe-bat/supercolor";
kaokao.url = "github:zoe-bat/kaokao";
i3layouts-rofi.url = "github:zoe-bat/i3layouts-rofi";
hx.url = "github:helix-editor/helix";
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs =
{ self
, nixpkgs
# , hyprland
, home-manager
, supercolor
, i3layouts-rofi
, nixpkgs-unstable
, kaokao
outputs = { self, nixpkgs
# , hyprland
, home-manager, supercolor, i3layouts-rofi, nixpkgs-unstable, kaokao, hx
}@inputs:
let
let
system = "x86_64-linux";
overlay-unstable = final: prev: {
unstable = import nixpkgs-unstable {
@ -29,8 +24,7 @@
config.allowUnfree = true;
};
};
in
{
in {
nixosConfigurations.bat = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
modules = [

View File

@ -1,52 +1,47 @@
{ pkgs, ... }: {
enable = true;
package = pkgs.unstable.helix;
settings = {
theme = "catppuccin_frappe";
keys = {
normal = {
w = ":w";
q = ":q";
{ pkgs, hx, ... }: {
home-manager.users.zoe.programs.helix = {
enable = true;
package = hx.packages.${pkgs.system}.default;
settings = {
theme = "catppuccin_frappe";
keys = { normal = { }; };
editor = {
auto-completion = true;
auto-format = true;
};
};
editor = {
auto-completion = true;
auto-format = true;
};
languages = [
{
name = "html";
language-server = { command = "html-languageserver"; };
formatter = {
command = "prettier";
args = [ "--parser" "html" ];
};
}
{
name = "scss";
language-server = { command = "vscode-css-language-server"; };
formatter = {
command = "prettier";
args = [ "--parser" "scss" ];
};
}
{
name = "css";
language-server = {
command = "vscode-css-language-server";
args = [ "--stdio" ];
};
formatter = {
command = "prettier";
args = [ "--parser" "scss" ];
};
}
{
name = "nix";
formatter = { command = "nixfmt"; };
}
];
};
languages = [
{
name = "html";
language-server = { command = "html-languageserver"; };
formatter = {
command = "prettier";
args = [ "--parser" "html" ];
};
}
{
name = "scss";
language-server = {
command = "vscode-css-language-server";
};
formatter = {
command = "prettier";
args = [ "--parser" "scss" ];
};
}
{
name = "css";
language-server = {
command = "vscode-css-language-server";
args = ["--stdio"];
};
formatter = {
command = "prettier";
args = [ "--parser" "scss" ];
};
}
{
name = "nix";
formatter = { command = "nixfmt"; };
}
];
}

View File

@ -1,7 +1,6 @@
{ pkgs, config, ... }:
{ pkgs, config, hx, ... }:
let
nvimCustom = import ./nvim/settings.nix;
helixCustom = import ./helix/settings.nix;
in
{
imports = [
@ -12,6 +11,7 @@ in
./rofi/settings.nix
./i3/i3status-rust.nix
./dunst/settings.nix
./helix/settings.nix
# ./polybar/config.nix
# ./hyprland/settings.nix
# ./waybar/settings.nix
@ -20,7 +20,6 @@ in
home-manager.users.zoe = {
home.stateVersion = "22.11";
programs.neovim = nvimCustom pkgs;
programs.helix = helixCustom pkgs;
programs.git = {
enable = true;
@ -32,10 +31,9 @@ in
programs.mpv.config = {
enable = true;
ytdl-format = "bestaudio*[height<=720][fps<=24]";
ytdl-path = "yt-dlp";
ytdl-format = "bestvideo[height<=?720]+bestaudio/best";
save-position-on-quit = true;
scripts = with pkgs.mpvScripts; [ mpris sponsorblock ];
scripts = with pkgs.mpvScripts; [ mpris sponsorblock uosc ];
};
programs.yt-dlp = {
enable = true;

View File

@ -102,13 +102,13 @@ in
};
brightness = {
Escape = "mode default";
k = "exec /etc/nixos/i3/brightness.py 100+";
j = "exec /etc/nixos/i3/brightness.py 100-";
k = "exec /etc/nixos/i3/brightness.py 10+";
j = "exec /etc/nixos/i3/brightness.py 10-";
};
media = {
Escape = "mode default";
j = "exec --no-startup-id python3 /etc/nixos/i3/volume.py 5%-";
k = "exec --no-startup-id python3 /etc/nixos/i3/volume.py 5%+";
j = "exec --no-startup-id python3 /etc/nixos/i3/volume.py 1%-";
k = "exec --no-startup-id python3 /etc/nixos/i3/volume.py 1%+";
m = "exec --no-startup-id amixer set Master toggle";
n = "exec --no-startup-id amixer set Capture toggle";
p = "exec --no-startup-id playerctld shift";

View File

@ -56,8 +56,9 @@ in {
# video
syncplay
unstable.mpv
mpv
unstable.yt-dlp
unstable.youtube-dl
obs-studio
ffmpeg
kdenlive
@ -101,6 +102,7 @@ in {
bat
fd
fzf
tmux
# window manager
rofimoji