mirror of
https://github.com/caperren/nixos-configs.git
synced 2025-11-09 04:01:15 +00:00
Normalize shell aliases
This commit is contained in:
@@ -1,8 +1,13 @@
|
|||||||
# Edit this configuration file to define what should be installed on your system.
|
# Edit this configuration file to define what should be installed on your system.
|
||||||
# Help is available in the configuration.nix(5) man page and in the NixOS manual
|
# Help is available in the configuration.nix(5) man page and in the NixOS manual
|
||||||
# (accessible by running ‘nixos-help’).
|
# (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, lib, pkgs, ... }:
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
@@ -33,7 +38,7 @@
|
|||||||
options v4l2loopback exclusive_caps=1 card_label="Virtual Camera"
|
options v4l2loopback exclusive_caps=1 card_label="Virtual Camera"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
#
|
#
|
||||||
nix.settings.download-buffer-size = 524288000;
|
nix.settings.download-buffer-size = 524288000;
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
@@ -100,8 +105,6 @@
|
|||||||
openFirewall = true;
|
openFirewall = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
hardware.xone.enable = true;
|
|
||||||
|
|
||||||
# Enable sound with pipewire.
|
# Enable sound with pipewire.
|
||||||
services.pulseaudio.enable = false;
|
services.pulseaudio.enable = false;
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
@@ -137,21 +140,20 @@
|
|||||||
# thunderbird
|
# thunderbird
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
# users.users.crestline = {
|
# users.users.crestline = {
|
||||||
# isNormalUser = true;
|
# isNormalUser = true;
|
||||||
# description = "Crestline";
|
# description = "Crestline";
|
||||||
# extraGroups = [
|
# extraGroups = [
|
||||||
# "networkmanager"
|
# "networkmanager"
|
||||||
# "wheel"
|
# "wheel"
|
||||||
# "input"
|
# "input"
|
||||||
# "dialout"
|
# "dialout"
|
||||||
# ];
|
# ];
|
||||||
# packages = with pkgs; [
|
# packages = with pkgs; [
|
||||||
# # thunderbird
|
# # thunderbird
|
||||||
# ];
|
# ];
|
||||||
|
|
||||||
# };
|
|
||||||
|
|
||||||
|
# };
|
||||||
|
|
||||||
#services.displayManager.autoLogin = {
|
#services.displayManager.autoLogin = {
|
||||||
# enable = true;
|
# enable = true;
|
||||||
@@ -261,7 +263,7 @@
|
|||||||
kanshi
|
kanshi
|
||||||
#wsmancli
|
#wsmancli
|
||||||
#realvnc-vnc-viewer
|
#realvnc-vnc-viewer
|
||||||
ncdu
|
ncdu
|
||||||
hyprlock
|
hyprlock
|
||||||
openrgb-with-all-plugins
|
openrgb-with-all-plugins
|
||||||
swayidle
|
swayidle
|
||||||
@@ -278,38 +280,38 @@
|
|||||||
highPriority = true;
|
highPriority = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
services.hardware.openrgb.enable = true;
|
services.hardware.openrgb.enable = true;
|
||||||
|
|
||||||
services.meshcentral.enable = true;
|
services.meshcentral.enable = true;
|
||||||
programs.ydotool.enable = true;
|
programs.ydotool.enable = true;
|
||||||
programs.adb.enable = true;
|
programs.adb.enable = true;
|
||||||
|
|
||||||
hardware.logitech.wireless.enable = true;
|
hardware.logitech.wireless.enable = true;
|
||||||
hardware.logitech.wireless.enableGraphical = true;
|
hardware.logitech.wireless.enableGraphical = true;
|
||||||
|
|
||||||
services.sunshine = {
|
services.sunshine = {
|
||||||
enable = true;
|
enable = true;
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
capSysAdmin = true;
|
capSysAdmin = true;
|
||||||
openFirewall = true;
|
openFirewall = true;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.bash.shellAliases = {
|
programs.bash.shellAliases = {
|
||||||
nixrebuild = "cd /etc/nixos && sudo nixos-rebuild switch --flake .#default";
|
nixrebuild = "pushd /etc/nixos && { trap 'popd' EXIT; sudo nixos-rebuild switch --flake .#$(hostname); }";
|
||||||
nixupdate = "cd /etc/nixos && sudo nix flake update && sudo nixos-rebuild switch --flake .#default";
|
nixupdate = "cd /etc/nixos && sudo nix flake update && sudo nixos-rebuild switch --flake .#$(hostname)";
|
||||||
nixedit = "sudo nano /etc/nixos/hosts/cap-nr200p/configuration.nix";
|
nixedit = "sudo nano /etc/nixos/hosts/$(hostname)/configuration.nix";
|
||||||
scrwebcam = "sudo pkill scrcpy ; sudo modprobe -r v4l2loopback ; sudo modprobe v4l2loopback && nohup scrcpy --camera-facing=back --video-source=camera --v4l2-sink=/dev/video0 --no-window --no-audio-playback 2>&1 1>/dev/null";
|
|
||||||
};
|
scrwebcam = "sudo pkill scrcpy ; sudo modprobe -r v4l2loopback ; sudo modprobe v4l2loopback && nohup scrcpy --camera-facing=back --video-source=camera --v4l2-sink=/dev/video0 --no-window --no-audio-playback 2>&1 1>/dev/null";
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
virtualisation.waydroid.enable = true;
|
virtualisation.waydroid.enable = true;
|
||||||
hardware.steam-hardware.enable = true;
|
hardware.steam-hardware.enable = true;
|
||||||
|
|
||||||
virtualisation.podman = {
|
virtualisation.podman = {
|
||||||
enable = true;
|
enable = true;
|
||||||
dockerCompat = true;
|
dockerCompat = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
services.udev.extraRules = ''
|
services.udev.extraRules = ''
|
||||||
# ST-LINK V2
|
# ST-LINK V2
|
||||||
@@ -362,7 +364,6 @@
|
|||||||
hardware.bluetooth.powerOnBoot = true; # powers up the default Bluetooth controller on boot
|
hardware.bluetooth.powerOnBoot = true; # powers up the default Bluetooth controller on boot
|
||||||
services.blueman.enable = true;
|
services.blueman.enable = true;
|
||||||
|
|
||||||
|
|
||||||
hardware.rtl-sdr.enable = true;
|
hardware.rtl-sdr.enable = true;
|
||||||
|
|
||||||
security.sudo = {
|
security.sudo = {
|
||||||
@@ -396,8 +397,6 @@
|
|||||||
capSysNice = true;
|
capSysNice = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Some programs need SUID wrappers, can be configured further or are
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
# started in user sessions.
|
# started in user sessions.
|
||||||
# programs.mtr.enable = true;
|
# programs.mtr.enable = true;
|
||||||
|
|||||||
@@ -263,16 +263,9 @@
|
|||||||
# services.automatic-timezoned.enable = true;
|
# services.automatic-timezoned.enable = true;
|
||||||
|
|
||||||
programs.bash.shellAliases = {
|
programs.bash.shellAliases = {
|
||||||
nixrebuild = "pushd /etc/nixos && { trap 'popd' EXIT; sudo nixos-rebuild switch --flake .#default; }";
|
nixrebuild = "pushd /etc/nixos && { trap 'popd' EXIT; sudo nixos-rebuild switch --flake .#$(hostname); }";
|
||||||
nixupdate = "cd /etc/nixos && sudo nix flake update && sudo nixos-rebuild switch --flake .#default";
|
nixupdate = "cd /etc/nixos && sudo nix flake update && sudo nixos-rebuild switch --flake .#$(hostname)";
|
||||||
nixedit = "sudo nano /etc/nixos/hosts/cap-slim7/configuration.nix";
|
nixedit = "sudo nano /etc/nixos/hosts/$(hostname)/configuration.nix";
|
||||||
|
|
||||||
conservebatt = "sudo bash -c 'echo 1 > /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode && cat /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode'";
|
|
||||||
noconservebatt = "sudo bash -c 'echo 0 > /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode && cat /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode'";
|
|
||||||
|
|
||||||
yesway = "nohup waybar >/dev/null 2>&1 &";
|
|
||||||
noway = "pkill waybar";
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#programs.appimage = {
|
#programs.appimage = {
|
||||||
|
|||||||
Reference in New Issue
Block a user